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.

TMS320F28388D: TMS320F28388D sample code for basic evaluation of CAN: A loopback test and PTP (CAN-A CAN-B) link test

Part Number: TMS320F28388D
Other Parts Discussed in Thread: C2000WARE

Dear TI Team

as a part of initial evaluation of F28388D microcontroller we would like to perform some tests related to CAN support. What would be the most convenient way to demonstrate its full functionality:

CAN-A loopback test, PTP (CAN-A CAN-B) link test or there are some other tests already available? It would be highly appreciated if someone could share a sample code for these tests (to speed up the evaluation process).

Is there a possibility to employ internal hardware supported encryption for CAN traffic, or that feature only supports ethernet interface?

Thanks in advance

Best regards

Nenad Težak

P.S. Control cards for TMS320F28388D microcontrollers in combination with corresponding experimenter kits docking station are used

  • Hi,

    I suggest to start looking from the CAN application note: App note .

    Regarding the encryption, there is an AES engine that is available in F2838D which can be used for encrypting the data that can be sent over CAN. I am also forwarding your query to one of our experts for their comments as well

    Regards,
    Praveen

  • Hi Praveen,

    thank you for suggested quick-start reference related to CAN subsystem/interface (https://www.ti.com/lit/an/sprace5a/sprace5a.pdf). 

    However, I do not know if I activate "This resolved my issue", will AES engine related part of my query also be closed (without getting any comments on that subject? In that case I would prefer to maintain the status flag of this query "open" until AES related answers are elaborated by TI experts familiar with this feature (AES engine) of the F28388D microcontroller.

    Best regards

    Nenad Težak

  • Nenad,

              You used the phrase “full functionality” for CAN. The ControlCARD+Docking station eco-system does not have CAN transceivers. Sure, you can run the loopback test. However, for you get the “true feel” of the CAN bus, you need to run some tests that involve external communication. You have two options:

    1. Use https://www.ti.com/tool/TCAN332EVM
    2. Implement the circuit shown that lets you operate the bus without transceivers.

    The TRM chapter explains the CAN protocol implementation in the MCU. i.e. it explains the functions of the various registers/bits. However, it does not explain the protocol itself. For protocol information, refer to these excellent videos:

    https://training.ti.com/automotive-can-overview

    https://training.ti.com/ti-precision-labs-canlinsbc-can-and-can-fd-protocol?context=1139747-1138099-1139707-1138111

    https://training.ti.com/ti-precision-labs-canlinsbc-can-and-can-fd-overview?context=1139747-1138099-1139707-1138109

    https://training.ti.com/ti-precision-labs-canlinsbc-can-physical-layer?context=1139747-1138099-1139707-1138110  

    Is there a possibility to employ internal hardware supported encryption for CAN traffic,

    Yes.

  • Dear Hareesh,

    thank you for all of your suggestions and useful links related to the CAN subsystem of the F28388D MCU (with CAN-FD support).

    I am aware of the fact that ECS solutions for almost all industrial/automotive/railway and any similar applications, require capability to connect much more communication nodes to the CAN bus (while typical CAN-bus lengths are significantly longer), as well as high-impedance isolated CAN interface.

    However, trying to keep the focus of my post related to CAN tests on basic (two-node) laboratory configuration,
    I omitted the fact that in the end newly designed F28388D based prototype module will support isolated CAN communication. Additionally, we use HW/SW test tools for interfacing/connecting PC to the CAN and other communication bases (Kvaser, Selectron etc.).  

    Besides, I would like your confirmation if suggested TCAN33x CAN transceiver chip can be utilized as a pin compatible replacement (with CAN-FD support, featuring enhanced ESD discharge resistance and many other performance improvements as well) for TI SN65HVD23x.

    Furthermore, regarding declared hardware supported AES encryption for CAN traffic: it would be appreciated if you could provide an example demonstrating combination of internal hardware supported AES encryption subsystem and CAN interface.

    Best regards

    Nenad Težak

  • I would like your confirmation if suggested TCAN33x CAN transceiver chip can be utilized as a pin compatible replacement (with CAN-FD support, featuring enhanced ESD discharge resistance and many other performance improvements as well) for TI SN65HVD23x.

    For this question, it would be best to open a new post with an appropriate title. It would then be answered by someone in the Transceiver group.

    Furthermore, regarding declared hardware supported AES encryption for CAN traffic: it would be appreciated if you could provide an example demonstrating combination of internal hardware supported AES encryption subsystem and CAN interface.

    I regret we don’t have such a ready-made example. However, I got the following inputs from an AES expert: 

    "The AES peripheral is on the CM core. If this needs to be used by the CAN software on  C28 (CPU1), we need to have a software layer in CM core which can process AES requests  from C28 and respond back to the C28 software. 

    There are examples on how to use different modes AES peripheral on CM core (with and without DMA), These examples are part of C2000ware (C:\ti\c2000\C2000Ware_3_04_00_00\driverlib\f2838x\examples\cm\aes). There is no example showcasing usage of AES from a software running on C28 core."