Main Content

LIN Unpack

Unpack signals from data frame by using configuration in LIN description file

Since R2021b

  • LIN Unpack block

Libraries:
Simulink Real-Time / LIN

Description

The LIN Unpack block unpacks the data frame by using the configuration in the LIN description file (LDF) and outputs signal data. You can use the unpacked local interconnect network (LIN) bus data as signal data in the model. The LIN Unpack block supports LDF version 2.2 and previous.

Ports

Input

expand all

When the message_updated value is 1 (logical true), there is a message coming in from the LIN bus. This block outputs the unpacked signals. When the message_updated value is 0 (logical false), there is no message updated on the LIN bus, and this block outputs the default value for each signal defined in the LDF file.

Receives LIN data to unpack.

Output

expand all

Sends unpacked data. The number of the output ports is allocated based on the number of signals in the selected frame. When a frame is selected, the port name is assigned to each port.

Parameters

expand all

Provides the file path of the LDF. If you do not set this parameter, you cannot use the block.

Programmatic Use

Block Parameter: LDFFileName

Selects the LIN frame from selections available in LDF. If you do not select an LDF, the block uses None.

Programmatic Use

Block Parameter: selectedFrameName

Selects LIN frame ID from selections available in LDF. If you do not select an LDF, the block uses 1.

Programmatic Use

Block Parameter: frameId

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2021b