Receiving cyclical RTR CAN Frame with ID 1FFFFFFFh when using more than one MPC5643

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Receiving cyclical RTR CAN Frame with ID 1FFFFFFFh when using more than one MPC5643

1,598 Views
julian_p
Contributor I

Hi everybody,

I am using the Motor Control Toolbox for the mpc5643L. In my CAN Network are 2 TRK-USB-MPC5643L and the PCAN-USB Interface. Sending my message with the ID 001h works perfectly fine.

In the Background the RTR-Frame with the ID 1FFFFFFFh is running cyclical with 0.7. The cyclical appearence of this RTR-Frame appears only when I use more than one TRK-USB-MPC5643L in my CAN-Network.

How can I suppress the sending of this frame?

What is the usage of this Frame?

Thank you very much for any advise or Help

Julian

0 Kudos
4 Replies

766 Views
fabacasuso
Contributor I

Hello,

I am facing the same problem. Did you finally find the solution?

Best regards

0 Kudos

1,368 Views
dumitru-daniel_
NXP Employee
NXP Employee

Hi Julian, 

Can you tell us more about your application configuration when using 2 or more devices like:

- both devices are sending messages at regular intervals or just when you press some buttons ?

- is there any chance that both devices to try to transmit the msg in the same time ?

- are you using different IDs for the messages ?

- can you link this 0.7 cycle time with any ISR from your applications ?

Best regards,

Daniel

0 Kudos

1,368 Views
julian_p
Contributor I
Hi Daniel,
thanks for your fast Reply!
Case 1
A CAN Network consisting of one TRK-USB-MPC5643L sending one CAN Message with the ID 1 to PCAN by pressing a button. When initializing (turning on) this network, once a CAN RTR Frame is on the bus with the ID 1FFFFFFF.
The sending and receiving of MY message works fine.
Case 2
A CAN Network consisting of two TRK-USB-MPC5643L and PCAN. One of them is sending the message with ID 1 (like case 1) by pressing a button. The other one is receiving this message and turning on a light. PCAN for Monitoring the Messages. When initializing this network, the same CAN RTR Frame from case 1 is running in a cycle of 0.7 or 0.8.
The Network works fine: The light is triggered by the first node of the CAN network with the message with ID 1.
For both cases I am using the "CAN Transmit" block and "CAN Receive Trigger" from the MC Toolbox
I never defined this appearing Remote Frame nor do I send it conscously.
It somehow appears by itself. I assume that this Frame is defined somewhere else?! I Can't find any more Information about to this RTR.
more Information in the Simulink screenshots. I hope everything is readable.
Config of nodes.png
Thanks for helping
Julian
0 Kudos

1,368 Views
dumitru-daniel_
NXP Employee
NXP Employee

Hi Julian, 

The RTR is defined in the Chip reference manual http://www.nxp.com/assets/documents/data/en/reference-manuals/MPC5643LRM.pdf 

The basic idea behind the Remote Frame is that the Destination Node can send/trigger this remote frame based on its received buffer message to cause the Source Node to automatically transmit its message.

This is helpful for reducing the CPU time to process the CAN messages, allowing the CAN controller to store pre-formatted msg in one of its mailbox and sent out it immediately on Remote Frame request.

I do not have hardware similar with yours - but i would start to investigate from the Simulink generated code for each of the sending and receiving models.

Couple of hints:

- For the transmitter check the  flexcan_564xl_buffer_transmit(). As far as i can see the RTR is set to 0 (CAN_0.BUF[BufferNo].CS.B.RTR = 0;)

- Check if anywhere in the generated code the RTR is set to 1.

"Remote frame is a special kind of frame. The user can program an MB to be a Request Remote Frame by
writing the MB as Transmit with the RTR bit set to ‘1’. After the Remote Request frame is transmitted
successfully, the MB becomes a Receive Message Buffer, with the same ID as before."

I would also try a live debug session to attach with a debugging tool like CW for MCU 10.7 in order to check what are the values of the CAN and Message Buffers during runtime.

One more thing - are you using a terminal 120ohm resistor for your CAN network ?

Best regards,

Daniel

0 Kudos