-
Notifications
You must be signed in to change notification settings - Fork 140
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
Is there documentation or example on how to use the C++11 generated libraries? #392
Comments
So to be more specific. I want to deserialize the stream into messages of their own type, but return a |
@aarondewindt The only examples and docs we have are for C and Python. @julianoes Can you advise? |
What about MAVROS? Does that help? |
@julianoes i think plugins code didn't help here, because mavlink transcoding is hidden by the api. @aarondewindt C++11 uses C library to finalize serialization and message parsing. To serialize mavlink::Message you need to:
To parse you should call mavlink::mavlink_frame_char_buffer() and then use MsgMap with resulting mavlink_message_t to be able to Message::deserialize(). |
@vooon sorry, you're right. I did not read the question correctly 🤦♂️. |
@vooon Thaaanks, that help quite a bit. I figured I had to use the C library and |
A simple example or advice we can add to the docs would be great. |
I have an incoming and outgoing stream of bytes which I need to serialize and deserialize to/from
mavlink::Message
objects. How do I do this? I can't find the documentation for the C++11 libraries or some example. So does anyone know of some example code doing this?The text was updated successfully, but these errors were encountered: