# MAVLink message structure

**URL:** <https://discuss.px4.io/t/mavlink-message-structure/16707>\
**Category:** MAVLink\
**Created:** [May 13, 2020, 7:30am UTC](https://discuss.px4.io/t/mavlink-message-structure/16707 "2020-05-13T07:30:41Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![minhhieutran0407](https://discuss.px4.io/letter_avatar_proxy/v4/letter/m/fbc32d/32.png) [@minhhieutran0407](https://discuss.px4.io/u/minhhieutran0407)\
**Post date:** [May 13, 2020, 7:30am UTC](https://discuss.px4.io/t/mavlink-message-structure/16707/1 "2020-05-13T07:30:41Z")

</div>

Hello. I want to know the structure of the MAVLink message when I send a request to Drone, example takeoff and land. Where I can find document about it? Thank you!

---

<div class="post-metadata">

**Author:** ![JulianOes](https://discuss.px4.io/user_avatar/discuss.px4.io/julianoes/32/30_2.png) [@JulianOes](https://discuss.px4.io/u/JulianOes)\
**Post date:** [May 13, 2020, 8:02am UTC](https://discuss.px4.io/t/mavlink-message-structure/16707/2 "2020-05-13T08:02:04Z")

</div>

What exactly are you trying to achieve? I’m not entirely sure how to answer you, there would be a lot to explain.

Have you browsed through [https://mavlink.io/en/](https://mavlink.io/en/) ?

---

<div class="post-metadata">

**Author:** ![minhhieutran0407](https://discuss.px4.io/letter_avatar_proxy/v4/letter/m/fbc32d/32.png) [@minhhieutran0407](https://discuss.px4.io/u/minhhieutran0407)\
**Post date:** [May 13, 2020, 10:25am UTC](https://discuss.px4.io/t/mavlink-message-structure/16707/3 "2020-05-13T10:25:11Z")

</div>

Sorry, my English skills are not good. I want to see MAVLink messages when I send a command to Drone, such as takeoff and landing. I am also looking at [https://mavlink.io/en/](https://mavlink.io/en/), but I would like to learn more documents for a more specific look.

---

<div class="post-metadata">

**Author:** ![JulianOes](https://discuss.px4.io/user_avatar/discuss.px4.io/julianoes/32/30_2.png) [@JulianOes](https://discuss.px4.io/u/JulianOes)\
**Post date:** [May 13, 2020, 11:19am UTC](https://discuss.px4.io/t/mavlink-message-structure/16707/4 "2020-05-13T11:19:34Z")

</div>

The command sent to takeoff is: [https://github.com/mavlink/mavlink/blob/ddc09ce654f0923f3780a7422e14aa0d643f8a80/message\_definitions/v1.0/common.xml#L1350-L1359](https://github.com/mavlink/mavlink/blob/ddc09ce654f0923f3780a7422e14aa0d643f8a80/message_definitions/v1.0/common.xml#L1350-L1359)

It’s a MAVLink COMMAND\_INT or COMMAND\_LONG: [https://github.com/mavlink/mavlink/blob/ddc09ce654f0923f3780a7422e14aa0d643f8a80/message\_definitions/v1.0/common.xml#L4993-L5022](https://github.com/mavlink/mavlink/blob/ddc09ce654f0923f3780a7422e14aa0d643f8a80/message_definitions/v1.0/common.xml#L4993-L5022)

And as an example how the bytes are put on the buffer, check:

> <https://github.com/mavlink/c_library_v2/blob/de33a4b53592a0530a5ddadec841210b62670929/common/mavlink_msg_command_int.h#L95-L136>

And an example how this is used, e.g. in MAVSDK:

> <https://github.com/mavlink/MAVSDK/blob/62fa8925d1d7e98b0dd4f167b9a319e84d16c152/src/plugins/action/action_impl.cpp#L269-L279>

---

<div class="post-metadata">

**Author:** ![minhhieutran0407](https://discuss.px4.io/letter_avatar_proxy/v4/letter/m/fbc32d/32.png) [@minhhieutran0407](https://discuss.px4.io/u/minhhieutran0407)\
**Post date:** [May 13, 2020, 12:17pm UTC](https://discuss.px4.io/t/mavlink-message-structure/16707/5 "2020-05-13T12:17:36Z")

</div>

Thank you very much! It will help me a lot in the process of learning about MAVLink protocol.
