Skip to main content
Explorer II
April 24, 2024
Question

STM32F412 CAN Transmits unexpected data

  • April 24, 2024
  • 1 reply
  • 1236 views

When I trigger a transmit of a test CAN message on CAN bus 2 the CAN module transmits unexpected data when I look at CAN bus with a logic analyzer. PCAN does receive the unexpected message and it does acknowledge the massage.

TxTestMsgCode.jpg

Here is what I see on the CAN Bus.

UnexpectedDataTX.jpg

PCAN Receive:

 

 

PCAN_RX_Unexpected message.jpg

 

 

    This topic has been closed for replies.

    1 reply

    Graduate II
    April 24, 2024

    Set your variables to global. Once your leave the SendCAN_Message function, the variables are destroyed.