Open vudala opened 2 months ago
@hamishwillee Is MAV_FRAME_LOCAL_NED
a valid message? I couldn't find the reference in the mavlink docs
@hamishwillee Is
MAV_FRAME_LOCAL_NED
a valid message? I couldn't find the reference in the mavlink docs
It is referenced here: https://mavlink.io/kr/messages/common.html#MAV_FRAME_LOCAL_NED
Problem description and how to reproduce
I am trying to plan a mission that uses local NED coordinates as waypoints.
I am creating mission items with MAV_FRAME_LOCAL_NED as MAV_FRAME for the MISSION_ITEM_INT, as defined by the MAVLink protocol: https://mavlink.io/kr/messages/common.html#MISSION_ITEM_INT https://mavlink.io/kr/messages/common.html#MAV_FRAME
Relevant code
Here's the relavant part of the MAVSDK code that I'm using to create the mission:
However when I try to upload the mission, I get an error indicating that I have invalid mission items.
That happens because the mission item parser doesn't treat MAV_FRAME_LOCAL_NED as a supported frame.
Currently it's only possible to add waypoints to the mission using global coordinates, so it would be great to have the support for local coordinates during mission planning.
Solution
Add MAV_FRAME_LOCAL_NED as a supported frame for the mission items. The parser that doesn't recognize this frame as a valid one, is located in modules/mavlink/mavlink_mission.cpp named parse_mavlink_mission_item().
Possible alternatives
Add some other way of planning missions using local coordinates. Like adding MAV_FRAME_LOCAL_ENU or MAV_FRAME_LOCAL_OFFSET_NED as a supported frame.