CAN Receive
Receive message from CAN network
- Library:
Simulink Support Package for Raspberry Pi Hardware / Communication
Description
The CAN Receive block receives messages from the CAN network. This block uses SocketCAN which is a device-independent driver for implementing the CAN interface supporting all CAN shields.
The CAN Receive block supports Raw data
and
CAN Msg
as output types. To use a CANdb (CAN database)
file or to specify signals manually, use CAN Msg
output type
and the CAN Unpack block. The CAN Unpack block is
available from Vehicle Network Toolbox™. For more information on the CAN Unpack block, see CAN
Unpack.
You can use CAN Receive block to interact with a real or virtual CAN interface. To bring up the CAN interface with Raspberry Pi™, refer to the user guide of your CAN shield. For more information on how to set up a virtual CAN interface, see Setup Virtual CAN Interface.