CAN 2.0 and CAN FD interoperability

Hi,

I’ve read the specifications (a few times) and fail to see how a node should split messages if it doesn’t know if the consumers are using CAN 2.0 and CAN FD.

My understanding is that with CAN 2.0 you can send 7 bytes of data at the time with 1 byte reserved for metadata (tail byte). With CAN FD, the payload gets bumped up to 64 bytes of data, which I’m assuming, in OpenCyphal terms means 63 bytes of data and 1 byte reserved for metadata (tail byte).

Do all nodes on the network need to be using CAN FD for that to work? I just can’t wrap my head around how the CAN FD backwards compatibility with CAN 2.0 could work with that tail byte in place. By that I mean, if the 64 bytes got split into 8 x 8 bytes by the underlying network, then only the last byte would have the tail byte (the first seven wouldn’t). Am I missing something???

Thanks,

Just came across this: CAN 2.0 MCUs won’t work in CAN FD networks

But that brings on a new question: How can a node know if all nodes on the network are CAN FD enabled?

In other words, if I’m understanding this correctly, a CAN FD enabled node should:
1- query all nodes to see if they are CAN FD enabled
2- if YES, send 64 bytes at the time (ie 63 + 1 tail). If NO, send 8 bytes at the time (ie 7 + 1 tail)

Even then, what happens if a new node that is not CAN FD enabled pop into the mix?

I’m starting to get the feeling that this needs to be left to the system integrators and that cyphal libs/apps need to have a CAN FD feature flag… doesn’t seem at all optimal.

Any insight on this would be much appreciated,

Correct.

Some Classic CAN controllers would report CAN FD frames as invalid, others would ignore them silently without incrementing the REC. If your Classic CAN controllers are of the former kind, you shouldn’t use them in a network with CAN FD traffic; otherwise it is fine to mix Classic CAN and CAN FD but the former won’t be able to receive traffic from the latter unless CAN FD nodes are configured to operate in the Classic CAN mode.

It is up to the system integrator to configure the network correctly to ensure all units are able to interoperate.

No such splitting is possible.

Your understanding is correct. The “CAN FD feature flag” is the MTU parameter:

Gotcha, thanks for clarifying, much appreciated.