Documentation for Syslink and CRTP packets between the STM32 and the NRF51 #1551
Replies: 1 comment 1 reply
-
Hi, I can answer in order and then discuss a bit more:
So basically, syslink is a communication protocol that is under CRTP, it is not dealing with the content of the CRTP packets in any way and just carries the packets back and forth from the radio to the stm32. It also implement a brunch of other packets that are useful for the communication of both CPU. We see it as a "private" part of the Crazyflie, in the sense that its API does not leak outside the scope of the the direct communication between nrf51 and stm32, so this explain why the documentation is unfortunately lacking. If you are interested in doing pull requests on the documentation I will very gladly merge it! |
Beta Was this translation helpful? Give feedback.
-
Hi, I am currently trying to develop my own firmware for the STM32 on the Crazyflie 2.1.
I'm having some trouble understanding what the packets look like between the main CPU STM32 and the NRF51 chip:
Which one is it? Syslink or CRTP?
As I understand it, CRTP is a packet with port, channel and a payload (here it would be the Syslink packet). Am I wrong?
The port is 4 bits, channel is 2 bits and payload is 31 bits.
However, these bits can be ordered in many different ways in a buffer:
37 bits: [P3, P2, P1, P0, C1, C0, D30, D29, ..., D1, D0] with P0 to P3 are the bits for the port, C0 and C1 the channel bits, and D the payload.
39 bits: [0, 0, P3, P2, P1, P0, C1, C0, D30, D29, ..., D1, D0] is the same as above but padding 0 to the left so that the port and channel are 8-bit
Padding can also be applied to the payload so that it fits 32 bits
In any case, padding is necessary to send information over UART which sends/receives 8 bits.
There are probably many more points that I missed, as I did not dive deeper in understanding each message.
It would be great if you can provide answers to the above points (and more I hope) in this thread or by updating the documentation.
Regards
Beta Was this translation helpful? Give feedback.
All reactions