-
Notifications
You must be signed in to change notification settings - Fork 16
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
CRSF Packet Sequence Number #5
Comments
the packets are sent one after another at a monotonic rate. if it doesn't appear in time, it was lost and the receiver switches to the next frequency the hopping sequence defines. so there is no reason to have a frame number and (without checking the data) there won't be a packet number in the protocol at the air link level. |
if you want to compensate for timing issues that come with your setup |
But how checking the data might help?
Could you please clarify on what you mean by "this level" please? Meaning on a higher session-application levels? |
Yea, my plan was to have my Tango device being wired to two transmitters, like T1 and T2, which "talk" to R1 and R2 receivers correspondingly, I'm not quite sure about how technically that is possible (and if clocks are being synchronized in that case), but the guy selling me a dron, said it is possible, like T1-R1 will make Path1 over 915MHz and T2-R2 over 450MHz implementing Path 2 from your illustration. I need to implement something similar to Ethernet link aggregation, and I'm pretty opened to any suggestion. But my idea was to have a way to identify each packet and at Flight Controller level have a virtual receiver, that will be listening traffic from both receivers and decide which one to forward to Flight Controller depending on last processed packet sequence number and current packet numbers read from R1 and R2. In any case, even with master/slave architecture and with no clock synchronisation that you described it does not really matter, if I teach the transmitter to assign each packet a sequence number in a way that both Path 1 and Path 2 will be sending packets with equal sequence number, so then I decide from virtual receiver which packet to process depending on last processed sequence number and current numbers. Please let me know if anything above makes any sense or if I'm missing something important here? btw, thanks for your replies :) |
on the serial rx/tx protocol (known as the CRSF in all flight controlers etc) you will receive packets like these please note that the serial link and the air link use different protocols, even the stick values being different widths (10 on air vs 11 on serial). |
Yea, I understand that air link != serial link
could you please elaborate on this part please? What does it mean "knowing about both schedules" and "knowing what to expect when"? |
correct and correct. maybe i misunderstood the target picture a bit. could you make/update the drawing it shall receive CRSF packets from two Rx devices (like stock nano receivers) and combine them, so it |
the picture is perfect!
Exactly! |
okay then i was partially stuck at some air level implementation (where my main research was). with two signals, i see a potential problem that arises when one drops out and you just pass the frames from the other link. but for the first start: this is a dumb strategy, but maybe the FC is stable enough and you do not notice switches at all. |
Hey, forgot to mention that I'm playing with Arduino scatches now trying to implement some simple algorithm that will identify connectivity issues. Can I donate some how for all the inputs you made, please? |
sure, if you want to donate (money usually is used for buying electronics / tinkering equipment like i used here) |
if you need support, you can also contact me directly. |
Hey @g3gg0, thank you for sharing this sniffer I've studied a lot from this blog post of yours https://www.g3gg0.de/wordpress/fpv/fpv-analysis-of-tbs-crossfire/
I'm looking for a solution to aggregate several physical links into one, so looking for a way to identify the sequence number of a packet to decide which one to execute considering I have two receivers connected to Flight Controller.
I'm playing with a simple Python parser(which is quite similar to your C# parser) in order to analyse CRSF packet, my goal is to find out how CRSF protocol identifies actuality of a packet, like how it decides that current packet is "old" and it should be dropped.
What I mean, theoretically, it is possible that for example B packet is received first compared to A, while transmitter sent A first and then B.
So how the receiver does know which packet should be "executed" and which is to drop? I guess there should be some sequence number or similar, but how one can parse/know it?
Could you please provide any hint in case you have any knowledge on that?
I'm motivated enough to compensate you the time spent on that, please.
I was looking into bunch of the directions already.
Found this spec - https://www.openrcforums.com/forum/download/file.php?id=17402, but it says nothing about sequence number, only defines packet types and their size + some more information.
From that (and from your material) I learned that I need to analyse 0x16 packet, which is RC channels packed. And I've identified which channel corresponds to the my joystic moves.
Like here it is sent with 14s channel, I see how the value differs, when I change joystic position:
But how one can identify the sequence number of a packet, I afraid it is handled at RX side itself, and I cannot see this information when RX sends instructions to Flight Controller? Is there a way still get this info somehow?
The text was updated successfully, but these errors were encountered: