mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-05 23:49:00 +08:00
[messages] rename POSITION_TARGET_LOCAL_NED to GUIDED_SETPOINT_NED
This commit is contained in:
+1
-1
@@ -2437,7 +2437,7 @@
|
||||
<field name="ac_id" type="uint8"/>
|
||||
</message>
|
||||
|
||||
<message name="POSITION_TARGET_LOCAL_NED" id="40" link="forwarded">
|
||||
<message name="GUIDED_SETPOINT_NED" id="40" link="forwarded">
|
||||
<description>
|
||||
Set vehicle position or velocity in NED.
|
||||
Frame can be specified with the bits 0-3 in the flags field:
|
||||
|
||||
@@ -187,13 +187,13 @@ void dl_parse_msg(void)
|
||||
break;
|
||||
#endif
|
||||
|
||||
case DL_POSITION_TARGET_LOCAL_NED:
|
||||
if (DL_POSITION_TARGET_LOCAL_NED_ac_id(dl_buffer) != AC_ID) { break; }
|
||||
uint8_t flags = DL_POSITION_TARGET_LOCAL_NED_flags(dl_buffer);
|
||||
float x = DL_POSITION_TARGET_LOCAL_NED_x(dl_buffer);
|
||||
float y = DL_POSITION_TARGET_LOCAL_NED_y(dl_buffer);
|
||||
float z = DL_POSITION_TARGET_LOCAL_NED_z(dl_buffer);
|
||||
float yaw = DL_POSITION_TARGET_LOCAL_NED_yaw(dl_buffer);
|
||||
case DL_GUIDED_SETPOINT_NED:
|
||||
if (DL_GUIDED_SETPOINT_NED_ac_id(dl_buffer) != AC_ID) { break; }
|
||||
uint8_t flags = DL_GUIDED_SETPOINT_NED_flags(dl_buffer);
|
||||
float x = DL_GUIDED_SETPOINT_NED_x(dl_buffer);
|
||||
float y = DL_GUIDED_SETPOINT_NED_y(dl_buffer);
|
||||
float z = DL_GUIDED_SETPOINT_NED_z(dl_buffer);
|
||||
float yaw = DL_GUIDED_SETPOINT_NED_yaw(dl_buffer);
|
||||
switch (flags) {
|
||||
case 0x00:
|
||||
case 0x02:
|
||||
|
||||
@@ -75,7 +75,7 @@ class Guidance(object):
|
||||
"""
|
||||
goto a local NorthEastDown position in meters (if already in GUIDED mode)
|
||||
"""
|
||||
msg = PprzMessage("datalink", "POSITION_TARGET_LOCAL_NED")
|
||||
msg = PprzMessage("datalink", "GUIDED_SETPOINT_NED")
|
||||
msg['ac_id'] = self.ac_id
|
||||
msg['flags'] = 0x00
|
||||
msg['x'] = north
|
||||
@@ -90,7 +90,7 @@ class Guidance(object):
|
||||
"""
|
||||
goto a local NorthEastDown position relative to current position in meters (if already in GUIDED mode)
|
||||
"""
|
||||
msg = PprzMessage("datalink", "POSITION_TARGET_LOCAL_NED")
|
||||
msg = PprzMessage("datalink", "GUIDED_SETPOINT_NED")
|
||||
msg['ac_id'] = self.ac_id
|
||||
msg['flags'] = 0x01
|
||||
msg['x'] = north
|
||||
@@ -104,7 +104,7 @@ class Guidance(object):
|
||||
"""
|
||||
goto to a position relative to current position and heading in meters (if already in GUIDED mode)
|
||||
"""
|
||||
msg = PprzMessage("datalink", "POSITION_TARGET_LOCAL_NED")
|
||||
msg = PprzMessage("datalink", "GUIDED_SETPOINT_NED")
|
||||
msg['ac_id'] = self.ac_id
|
||||
msg['flags'] = 0x03
|
||||
msg['x'] = forward
|
||||
|
||||
Reference in New Issue
Block a user