This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/TMS320F28377D: can communication can_external_transmit 28377d

Part Number: TMS320F28377D
Other Parts Discussed in Thread: CONTROLSUITE, SN65HVD233, ISO1050

Tool/software: Code Composer Studio

when  I use the function  can_external_transmit in 28377d ,  This function always goes wrong and interrupts operation.  The GPIO are all properly configured.

The CAN - A module can send messages (only  one  messages ) normally, and then the program interrupts and stops running because the CANB module cannot receive messages. Can you explain to me why?

Can you explain to me the specific function of this function?( can_external_transmit)   。   Thank you very much

  • Hi,

    Can you describe how you connect CAN-A and CAN-B physically?  Do the external CAN pins go through a CAN network (or CAN bus)?

    Thanks,

    Joseph

  • I don't connect CAN-A and CAN-B physically,I think they have connected to each other in the board.
  • Dear Joseph,
    By the way , Can you explain to me the specific function of this function(can_loopback.c) ? Can i use this function(can_loopback.c) to receive messange from the outside or send messange to the outside . How can I modify it?

    his is the location of the function C:\ti\controlSUITE\device_support\F2837xD\v210\F2837xD_examples_Cpu1\can_loopback
    Thanks,
  • Hi,

    In the example you used, the CANRX and CANTX pins from the CAN pins have to be connected to a transceiver to generate a differential signal going out to the CAN bus in order for the test can_external_transmit to work.  If you are just interested to see how CAN communication works without having to use the CAN transceiver and CAN bus, you can use the example can_loopback.

    Regards,

    Joseph

  • Hi,

    The can_loopback test basically transmists data from the CANTX pin to the CANRX pin and checks to see if the transmitted data is equal to the received data. Initial transmitted data is 0 and is incremented each time by 1, which essentially transmits all the combination on ascii characters in the CANTX pin. This is essentially an internal test that checks the basic functionality of the CAN module and pins.

    If you want to receive or send message from the outside, then use the test can_external_transmit.c. You would then need to connect the CANTX and RX pins to a transceiver (e.g. SN65HVD233 or similar product) in order for the CAN module to be connected to the CAN network. This is a basic requirement for CAN as the CAN bus, which connects the CAN to the network relies on differential signals to operate reliably even in a noisy environment. Translating the CANTX and RX signals from the CAN module to differential signal is done by the transceiver. Once you have established connection to the CAN network, only then can you have full communication between nodes. In the example can_external_transmit.c, CAN module A transmits the data while CAN module B receive the data from the same 28377D chip. As long as the modules are connected to the CAN network, you can expand the test such that you can transmit/receive data from other devices with CAN module.

    Let me know if this answers your query or if you have any other questions.

    Regards,
    Joseph
  • You can test the CAN module by CAN_loopback without transceiver. If you have to test the can_external_transmit now, the CAN transceiver should be added, such as ISO1050.
  • Thank you for your reply,I solved my problem。