# Pixhawk Waypoint Mavlink Message

**URL:** <https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211>\
**Category:** Uncategorized\
**Created:** [January 18, 2017, 8:29pm UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211 "2017-01-18T20:29:14Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![thomascheney](https://discuss.px4.io/letter_avatar_proxy/v4/letter/t/2bfe46/32.png) [@thomascheney](https://discuss.px4.io/u/thomascheney)\
**Post date:** [January 18, 2017, 8:29pm UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/1 "2017-01-18T20:29:14Z")

</div>

Is it possible to get a list of the current mission’s waypoints from the Pixhawk via MavLink? I need a way to grab the waypoints, do some processing on them on a external device (using C code), and then send an updated list of waypoints to the Pixhawk. I would very much appreciate some advice on how to go about this. Thanks.

---

<div class="post-metadata">

**Author:** ![dagar](https://discuss.px4.io/user_avatar/discuss.px4.io/dagar/32/22_2.png) [@dagar](https://discuss.px4.io/u/dagar)\
**Post date:** [January 19, 2017, 3:38am UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/2 "2017-01-19T03:38:53Z")

</div>

Yes there is. [http://mavlink.org/messages/common#MISSION\_REQUEST\_LIST](http://mavlink.org/messages/common#MISSION_REQUEST_LIST)

This is out of date, but gives you an idea of how it works. [http://qgroundcontrol.org/mavlink/waypoint\_protocol](http://qgroundcontrol.org/mavlink/waypoint_protocol)  
I’m not aware of a good standalone example implementing mission sync, but here’s how it works on the firmware side.  
[https://github.com/PX4/Firmware/blob/master/src/modules/mavlink/mavlink\_mission.cpp#L422](https://github.com/PX4/Firmware/blob/master/src/modules/mavlink/mavlink_mission.cpp#L422)

You might also consider using Dronekit. [http://dronekit.io/](http://dronekit.io/)  
It’s a high level wrapper around mavlink.

---

<div class="post-metadata">

**Author:** ![Nicolas](https://discuss.px4.io/user_avatar/discuss.px4.io/nicolas/32/4467_2.png) [@Nicolas](https://discuss.px4.io/u/Nicolas)\
**Post date:** [January 19, 2017, 7:11pm UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/3 "2017-01-19T19:11:29Z")

</div>

If ROS is an option for you, I’d recommend doing it with MAVROS. With that it’s as simple as calling a service to get and set a mission.

---

<div class="post-metadata">

**Author:** ![thomascheney](https://discuss.px4.io/letter_avatar_proxy/v4/letter/t/2bfe46/32.png) [@thomascheney](https://discuss.px4.io/u/thomascheney)\
**Post date:** [January 28, 2017, 11:26pm UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/4 "2017-01-28T23:26:21Z")

</div>

Thanks guys, I haven’t had a lot of time to check this out yet, but I will look into what was suggested and let everyone now how it goes.

---

<div class="post-metadata">

**Author:** ![thomascheney](https://discuss.px4.io/letter_avatar_proxy/v4/letter/t/2bfe46/32.png) [@thomascheney](https://discuss.px4.io/u/thomascheney)\
**Post date:** [February 25, 2017, 7:23am UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/5 "2017-02-25T07:23:51Z")

</div>

I’ve been able to successfully get waypoints off of the Pixhawk using a series of mission\_request\_list, then waiting for the count and then sending a mission\_request how every many times the count it I received.

However, I’m still having trouble with sending a list of waypoints to the Pixhawk. If I send a mission\_count message, the Pixhawk responds with mission\_request messages, but it doesn’t seem to get the mission\_item messages I send to it after that. It just keeps sending mission\_request items with sequence 0 as it never gets the first one.

Does anyone have any ideas I can try with this?

---

<div class="post-metadata">

**Author:** ![Dharma\_KC](https://discuss.px4.io/user_avatar/discuss.px4.io/dharma_kc/32/3518_2.png) [@Dharma\_KC](https://discuss.px4.io/u/Dharma_KC)\
**Post date:** [May 17, 2018, 3:13pm UTC](https://discuss.px4.io/t/pixhawk-waypoint-mavlink-message/2211/6 "2018-05-17T15:13:00Z")

</div>

Were you able to do it? Can you post the solution. Thank you.
