New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TSCH CC1312 interop with other platforms #1369
Comments
Can you clarify which other vendor you mean? One of the approaches must be wrong. Standards exist for this reason, and reverse bit ordering means incompatibility with standard. If Contiki-NG Simplelink platform orders the bits incorrectly on CC1312 ships, it should be fixed; otherwise there is little to do. Other problems may exist, as indicated by the CC1312/CC1312 communication problems. Just to make sure, you are using the right frequency band for the boards you have? (e.g. 868 in Europe, 915 in the States) |
I cannot say what other vender it is. I can push in a fix to the propmode.c overrides to fix the bit reversal to match what the standard says, but this will basically cause this other issue I am talking about. Until I find a fix and I am able to have a stable connection between same devices and interop between other vendors I will not suggest the fix. Yes, I am 100% sure that they are in the same band and freq. |
Following a couple of discussions offline: It appears as though we are transmitting the payload part of .4g PHY packets in the wrong bit order. According to the spec, the PHR needs transmitted MS bit first, whereas the payload needs to be LS bit first. This means that we need to present the PHR to the radio using the bit order of the system CPU, but we need to invert the bit order of the payload. This affects:
Based on my current (limited) understanding of this topic, what we need to do is,:
Ping @simonduq for info |
Just adding for reference, this is documented on cc13x2 in the TRM: Section 25.10.5.2.1 IEEE 802.15.4g Packet Format: As far as I was able to evaluate, our PHY header is correct, but all the follows (PHY payload) is bit-inverted: all bytes come in the expected order but have their bits swapped from LSb to MSb. |
Perhaps stating the obvious, but my understanding is that we need to change both the TX as well as the RX path. |
Any update on this? |
I guess that means that we should NOT use the built-in feature that will do bit-reverse on the CC13xx? I did look at some other configurations of the radio - and the Wi-Sun config seems to use that bit-reverse feature. |
I did a few tests with bit reverse via the built-in bit-reverse feature of the CC13xx series - but yes - it will also bit reverse the header bytes, which means that we need to bit reverse only all other bytes. I did try that, and the TI Radiosniffer seems to receive the packets again then - with better "data" in the 802.15.4 header (e.g. correct PANID, etc). |
I have a branch here that improves what is coming into TI RF Sniffer software - correct headers, etc. But I will do more testing to confirm that two CC1352R1 also work with both bit-orders (in, for example RPL-UDP or some other simplistic example). https://github.com/joakimeriksson/contiki-ng/tree/bitrev-cc13xx |
As far as I can tell from testing with the TI stack, as well as the ported bitreverse for ST Nucleo-boards the bitrev-cc13xx is working. We'll continue integration and testing using the bitrev-cc13xx branch
|
While testing interoperability I found that some other vender bit reverse the payload. The CC1312 does not do this at the radio level and was causing problems when trying to communicate between devices.
There is an override that can be added to the radio to do this, and when we do it we can finally sniff the packets as they should be sent.
Problem is that we cannot establish a network connection between platforms.
After applying the override:
CC1312 leaf node no longer joins CC1312 coordinator
Another vendor’s board as leaf node still joins CC1312 coordinator, however, ping from Linux host through slip interface no longer works
When two CC1312 boards try to form a network, the leaf node finds the parent but soon loses it. This repeats indefinitely.
The text was updated successfully, but these errors were encountered: