-
Notifications
You must be signed in to change notification settings - Fork 67
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
Intel Aero RTF PX4 1.8, vast majority of messages appear to have CRC errors #5
Comments
If you could provide some example message IDs which did not pass validation that would be helpful. Also, are you sure that you are running the latest version of this library? We did have a problem with CRC calculation up to version 1.0.3 where it has been resolved. |
I am/was using 1.0.3 via ivy/JCenter. Then I cloned the git repo, and it seems to be up to date. Running "git describe --tags" says it's 1.0.6. As soon as I get to the office (where the Aero is) I'll run it again and get message IDs. Is there anything else I can do/provide to help diagnose this? Many thanks. |
Message IDs received that had a bad CRC, over a one minute run; COUNT ID |
Could you look into the XML CRC of a couple of these messages? for example, the CRC for |
I'm sorry, can you clarify? You mean this? /**
Note, I did not generate/regenerate anything, I just cloned the repo and then copied the source into my project in Eclipse. |
@seanrowens yes I understand, I wanted you to look it up to see if you have the same CRCs as the repository, which you do. If you look into c_library_v2/standard/standard.h#L27 it seems like the messages have the correct XML IDs. (for each subarray in Also, if there's any failure which causes a packet to be dropped, then this library just drops the first byte of that packet and attempts at reading a packet from the next byte. So for example if I have a buffer of 30 bytes and I've read a packet at 0 to 15 that has been dropped, what will happen is that we'll attempt to read a packet from position 1 rather than skipping to position 16. Therefore, depending on how you count lost packets, you might actually be counting lost bytes. At the top of my head, perhaps if you could log some packets which pymavlink reads but this library does not then it will make it easy to reproduce. Anything that you can come up with that could help reproduce this will help :) |
Considering that pymavlink seems to accept everything and dronefleet mavlink doesn't accept anything, that shouldn't be hard. I'll be quite happy to do anything I can to help debug this, time allowing. Come to think of it, I should be able to just use netcat to open a socket to the server and redirect all bytes to a file, would that help? |
This is a capture of bytes off the socket using netcat. |
Whups, didn't mean to close the issue. |
I'm gonna try parsing it |
@seanrowens I found the problem. I'll make a fixed release in an hour or so. |
@seanrowens I've released |
Yay! Thanks! |
I'm trying to talk to an Intel Aero RTF drone, which has been updated to PX4 1.8.0 from;
https://github.com/PX4/Firmware/releases/download/v1.8.0/aerofc-v1_default.px4
When I started a copy of the sample code, I received very very few messages back, something like three or four over the course of minutes. I downloaded the source for mavlink and added some logging in MavlinkConnection.next(), and when I ran that for one minute (over a TCP socket, as was shown in the sample code), MavlinkConnection.next() received 25593 messages, of which 1984 were unsupported by the dialect and 23609 did not pass the CRC test. It received no messages that passed both tests in that minute. I tried configuring the connection as;
I also tried with just the second line, i.e. PX4.
I'm kind of at a loss at this point on how to proceed further. Possibly I've not configured something correctly? Pymavlink seems to work much better over a TCP socket talking to this Aero but I would much prefer to stick to Java.
The text was updated successfully, but these errors were encountered: