Servers by jDrones

Mavlink mission upload timeout error in Copter 4.1.0-dev

Hi there!

I am facing a problem uploading a mission with waypoints to the autopilot. It works great in SITL but not on a real quadcopter (both running v4.1.0-beta1).

In this case, I refer to https://github.com/ArduPilot/pymavlink/pull/503 , a great example by @khancyr. I am also using pymavlink on a RPi.

On the real quadcopter, I believe the problem is in the loop described in the documentation: https://mavlink.io/en/services/mission.html

Here is the code that I am using (send_all_waypoints()): https://github.com/ArduPilot/pymavlink/blob/7c48ca6bc4c89f635e51d099610880eab754468a/examples/mavexample_ardupilot_copter.py#L1148

The python script sends the MISSION_COUNT(n) and receives the MISSION_REQUEST(0). Then the script sends the first Waypoint(item 0) and also receives the MISSION_REQUEST(0). The python script and the autopilot still in this loop until the autopilot raises the timeout mentioned in the documentation (Mission upload timeout). In other words, the first Waypoint is never received by the real quadcopter but works on the SITL.

I guess I am missing something here. Maybe in the quadcopter side. :frowning:

Servers by jDrones