Another issue from the same .tlog:
Setting HOME during a mission doesn't seem to work. It looks like it does the right thing in Mission Planner but the copter ignores it. You can see it arms at 10% and auto-sets HOME, I do a RTL to that location around 14%, then set HOME to a different location and another RTL at 16%, which again goes back to the original arming location rather than the new HOME (there was another RTL at 14.5% but I'd forgotten to send the new mission to the copter for that one, so the 16% one is the error case).
Is this a firmware or Mission Planner issue?
Setting HOME during a mission is really important for long range missions from A to B where you pass a point of no return and won't have power to RTL home to A again. Another case is launching from a boat, you don't want to RTL back to where the boat was (as it is now an empty and unwelcoming patch of sea), but to set HOME perhaps to a nearby bit of land in case you lose contact.
The Mission Planner home position is never transmitted to the APM except with the Do_Set_Home command from a mission (i never tried it nevertheless, but it seems implemented in the Arducopter code).
Only the home position stored inside the APM is sent to Mission Planner when waypoints are loaded from the APM or when you click the "Home Location" link (right down corner of Mission Planner).
When reading the APM waypoints, Mission Planner ask you if you want to reset Mission Planner home position coordinates to the APM home position ones.
Mission Planner will never send its home position to the APM and there is no command to do that in real time. Mission Planner home position should be considered as a geographic mark to make other waypoints positioning easier, to pan the Map to the right location when you start to fly at a new field, or to get the distance from home on the map, not more.
The APM always use the home position stored at arming or as soon as there is a GPS 3D fix. I think that it's better like this for a safer experience. This guarantee that RTL will work regardless the stored mission.
If Geofence is enabled, then you will not be able to arm before a 3D fix, to guarantee that RTL will use the take off location.
I think that RTL to Mission Planner home position is not implemented inside Arducopter. And even if this was working, RTL mode should have been initiated from Mission Planner directly so that the RTL coordinates could be sent through Mavlink. This will never work from a RC radio initiated RTL, because the APM does not have any idea about where Mission Planner home position is.
In the end :
- you could use guided mode to send the copter to a desired position in realtime from Mission Planner (Fly to here on the Map with the right mouse button) so that if you are on a moving boat you could ask your copter to come back to it.
- you can change the APM home position during a mission using DO_SET_HOME command
(with parameter 1 = 1 to use current position as the home position, or with coordinates to set a free one).
This should allow to solve your long range mission problem, where the RTL target needs to be updated at each no return waypoint.
I think as much as possible we should try and get the mission planner's home position to always be the same as arducopter's home position. We got closer with this when MichaelO implemented the feature so that the mission planner pulls the home position from arducopter after arming.
I think the mission planner actually does write it's home position to arducopter when it writes a mission but this is a bit pointless because it just gets overwritten when arducopter arms.
The LAND command would also be a good one to use in place of RTL if he/she wants to bring the copter down at a different location than home.