|
PX4 ROS 2 Interface Library
Library to interface with PX4 from a companion computer using ROS 2
|
Utility to set the vehicle's home position and GPS global origin. More...
#include <px4_ros2/vehicle_state/home_position_setter.hpp>
Public Member Functions | |
| HomePositionSetter (Context &context) | |
| Result | setHomeToCurrentPosition () |
| Set the home position to the current vehicle position. | |
| Result | setHome (double latitude, double longitude, float altitude) |
| Set the home position to a specific global coordinate. | |
| Result | setGpsGlobalOrigin (double latitude, double longitude, float altitude) |
| Set the GPS global origin (EKF reference point). | |
Utility to set the vehicle's home position and GPS global origin.
Sends VEHICLE_CMD_DO_SET_HOME and VEHICLE_CMD_SET_GPS_GLOBAL_ORIGIN commands to PX4 via the vehicle_command topic and waits for an ACK.
| Result px4_ros2::HomePositionSetter::setGpsGlobalOrigin | ( | double | latitude, |
| double | longitude, | ||
| float | altitude | ||
| ) |
Set the GPS global origin (EKF reference point).
| latitude | [deg] |
| longitude | [deg] |
| altitude | [m AMSL] |
| Result px4_ros2::HomePositionSetter::setHome | ( | double | latitude, |
| double | longitude, | ||
| float | altitude | ||
| ) |
Set the home position to a specific global coordinate.
| latitude | [deg] |
| longitude | [deg] |
| altitude | [m AMSL] |
| Result px4_ros2::HomePositionSetter::setHomeToCurrentPosition | ( | ) |
Set the home position to the current vehicle position.