XC161: CAN Message Object Buffer

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
GoKl_4594211
Employee
Employee
I refer to the XC161 family users' manual. On page 21-19 you state "If several valid message objects with pending transmission request are noticed by the associated CAN node controller, the contents of the message object with the lowest message number is transmitted first."

I want to prepare e.g. a block with four messages for transmission. Can I procede like this (examples for 2 packets with 4 messages per packet; see below)?

Scenario 1:
CAN Message Object Buffer configuration: 8 buffers for 4 messages per FIFO.
I write eight messages into two buffers.
Once the messages objects with pending transmission request are noticed by the associated CAN node controller, the contents of the message object (which consists of four messages) with the lowest message number of the base message object is transmitted first. The remaining three slave message objects are transmitted independantly of their identifiers in the sequence in which they had been written into the FIFO.

Scenario 2:
CAN Message Object Buffer configuration: 32 buffers for 1 message per FIFO.
I write eight messages into eight buffers.
Once the messages objects with pending transmission request are noticed by the associated CAN node controller, the contents of the message object with the lowest message number is transmitted first. There are no slave message objects. Here the buffer doesn't work like a fifo, because for transmission the sequence of all messages is determined by their identifiers and not by the sequence determined by writing the message into the buffer.

Did I get that right?

In short: I want the buffer to behave like a FIFO, but your user manual says, that when reading the buffer, the sequence is determined by message numbers. That is not how a FIFO behaves.
I want FIFO behavior. My objective is that it is our software which determines the sequence of the transmitted message objects just by writing the messages into the FIFO in the sequence in which they are to be transmitted.
Scenario 2 would reshuffle the messages, which I don't want. Would scenario 1 do the job?

Scenario 3 (just for curiosity for block sizes with mod(block size,2)>0):
CAN Message Object Buffer configuration: 1 buffers for 32 messages. The whole buffer is a single FIFO.
I write six(!) messages into the buffer (1 base massage and five slave messages).
Once the messages objects with pending transmission request are noticed by the associated CAN node controller, the contents of the message packet (which consists of six messages) is transmitted. The sequence of the six messages is maintaines. There is no ordering of by message identifier.

Would scenario 3 work too?

Sorry for not trying this out myself. I need an answer in order to decide whether we can use the XC161 for sending CAN messages in a sequence determined by as and not determined by message identifier. If the XC161 can support that, then we consider to use it.
0 Likes
0 Replies