SPRUII0F May 2019 – June 2024 TMS320F28384D , TMS320F28384D-Q1 , TMS320F28384S , TMS320F28384S-Q1 , TMS320F28386D , TMS320F28386D-Q1 , TMS320F28386S , TMS320F28386S-Q1 , TMS320F28388D , TMS320F28388S
FILE: can_ex4_transmit_receive.c
This example shows the basic setup of CAN in order to transmit or receive messages on the CAN bus with a specific Message ID. The CAN Controller is configured according to the selection of the define.
When the TRANSMIT define is selected, the CAN Controller acts as a Transmitter and sends data to the second CAN Controller connected externally.If TRANMSIT is not defined the CAN Controller acts as a Receiver and waits for message to be transmitted by the External CAN Controller.
Before running this example, please run the can_config_c28x example from the c28x folder. It will initialize the clock, configure the GPIOs and allocate CAN A to CM.
CAN modules on the device need to be connected to via CAN transceivers.
Hardware Required
External Connections
Watch Variables Transmit \Configuration