|
Auterion App SDK
Auterion SDK is a library that can be used by AuterionOS apps to communicate with the system.
|
Drive to a position given as latitude and longitude. More...
#include <auterion_sdk/control/surface_vehicle/global_frame_position_control.hpp>
Classes | |
| class | Config |
| Mode-wide defaults for GlobalFramePositionSetpoint. More... | |
Public Member Functions | |
| GlobalFramePositionSetpoint (const Eigen::Vector2d &position_lat_lon_deg) | |
| GlobalFramePositionSetpoint & | withPosition (const Eigen::Vector2d &position_lat_lon_deg) |
| Sets the target latitude and longitude [deg]. | |
| GlobalFramePositionSetpoint & | withPosition (const Eigen::Vector3d &position_lat_lon_alt) |
| Sets the target from latitude [deg], longitude [deg] and altitude [m]. The altitude is ignored, so you can pass auterion::GlobalPosition::toEigenVector() directly. | |
| GlobalFramePositionSetpoint & | withStartPosition (const Eigen::Vector2d &start_position_lat_lon_deg) |
| Sets the start of the line that the vehicle follows to the target, as latitude and longitude [deg]. | |
| Eigen::Vector2d | getPosition () const |
| std::optional< Eigen::Vector2d > | getStartPosition () const |
Public Member Functions inherited from auterion::surface_vehicle::detail::PositionSetpointSpeedsBase< GlobalFramePositionSetpoint > | |
| GlobalFramePositionSetpoint & | withCruisingSpeed (float cruising_speed_m_s) |
| Sets the speed to drive at on the way to the target [m/s]. | |
| GlobalFramePositionSetpoint & | withArrivalSpeed (float arrival_speed_m_s) |
| Sets the speed the vehicle has when it reaches the target [m/s]. | |
| std::optional< float > | getCruisingSpeed () const |
| std::optional< float > | getArrivalSpeed () const |
Drive to a position given as latitude and longitude.
Same behavior as LocalFramePositionSetpoint, with the target (and optional start) given in global coordinates. The SDK converts them to the local frame using the reference point of the vehicle's local position estimate, and follows changes of that reference point.
Frames and units:
Defaults: the same as LocalFramePositionSetpoint. If the vehicle has no local position reference yet, no setpoint is sent and an error is logged.
The target position is required. Returning a setpoint without a finite target position from auterion::Mode::onUpdateSetpoint throws std::invalid_argument.
Example:
|
inlineexplicit |
| position_lat_lon_deg | Target latitude and longitude [deg]. |
|
inline |
Sets the start of the line that the vehicle follows to the target, as latitude and longitude [deg].
Use this to follow an exact track, e.g. a survey line, instead of the line from the current position. If not set, the line starts at the vehicle's current position.