You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MAV_CMD_DO_REPOSITION works as documented (in http://mavlink.org/messages/common) when used as COMMAND_LONG. However, COMMAND_INT has a frame argument, which could apply to this command:
if user specifies MAV_FRAME_GLOBAL_RELATIVE_ALT_INT (6), param7 (altitude) is interpreted as relative to home position
if user specifies MAV_FRAME_GLOBAL_INT (5), param7 (altitude) is interpred as AMSL (same as with the COMMAND_LONG version)
Right now, altitude is always interpreted as AMSL, which can be worked around if one wants to work in terms of relative altitude, but such workaround seems to be quite indirect.
I've worked around it as follows (ROS-specific stuff follows, sorry): I need to reposition to some relative altitude Z. I take relative altitude from /mavros/altitude, subtract it from AMSL altitude from the same /mavros/altitude thus getting the offset between the two (or, alternatively, the AMSL altitude of the home point). Adding the offset to Z, I get its AMSL equivalent.
The text was updated successfully, but these errors were encountered:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
MAV_CMD_DO_REPOSITION works as documented (in http://mavlink.org/messages/common) when used as COMMAND_LONG. However, COMMAND_INT has a
frame
argument, which could apply to this command:Right now, altitude is always interpreted as AMSL, which can be worked around if one wants to work in terms of relative altitude, but such workaround seems to be quite indirect.
I've worked around it as follows (ROS-specific stuff follows, sorry): I need to reposition to some relative altitude Z. I take relative altitude from
/mavros/altitude
, subtract it from AMSL altitude from the same/mavros/altitude
thus getting the offset between the two (or, alternatively, the AMSL altitude of the home point). Adding the offset to Z, I get its AMSL equivalent.The text was updated successfully, but these errors were encountered: