Hi forum,
Following a long and sometimes heated discussing on a parallel thread, I’d like to introduce an additional proposal aimed at improving type safety and easy of use of UAVCANv1 based systems.
The idea is add an extra string-typed register for each publish and subscribe topic. This register would be read-only and contain a “type descriptor string” for the message that is either sent or received by that topic.
An example descriptor string would be "v48b1a2[{u8u8}]{u8u8}{u8u8}u64A16[u8]a50[u8]a1[u64]a222[u8]"
(note this implementation is proof of concept and therefore optimized only for human readability and not for size).
This signature string can be used by a configurator tool to check the compatibility of the messages. Messages would be considered compatible if strings are either identical, or one is a prefix of the other in case of extended messages.
This configurator tool can be either a human-operated program, or an auto-configurator module running on system startup.
My hope is that taken together with the previous ID management proposal, this can get the usability and robustness of v1 to be equal or better than those of v0 .
Very rough POC code that generates the signature from DSDL can be seen here: https://gitlab.com/vadimz1/dsdl-sig-gen/-/blob/main/sig-gen.py