10 #ifndef _UGCS_VSM_MOVE_ACTION_H_
11 #define _UGCS_VSM_MOVE_ACTION_H_
16 #include <ugcs/vsm/optional.h>
17 #include <ugcs/vsm/property.h>
31 TURN_TYPE_STOP_AND_TURN = 0,
32 TURN_TYPE_STRAIGHT = 1,
34 TURN_TYPE_BANK_TURN = 3,
43 acceptance_radius(acceptance_radius),
44 loiter_orbit(loiter_orbit),
47 turn_type(TURN_TYPE_STRAIGHT)
57 double lat = 0, lon = 0, alt = 0;
58 auto pi = p.find(
"latitude");
60 pi->second->Get_value(lat);
62 pi = p.find(
"longitude");
64 pi->second->Get_value(lon);
66 pi = p.find(
"altitude_amsl");
68 pi->second->Get_value(alt);
72 p.at(
"heading")->Get_value(
heading);
75 p.at(
"ground_elevation")->Get_value(
elevation);
77 p.at(
"turn_type")->Get_value(t);
MAVLink protocol messages.
Definition: property.h:250
double elevation
Elevation in meters (i.e.
Definition: move_action.h:114
Move_action type
Real type.
Definition: move_action.h:123
Coordinates tuple for geodetic CS.
Definition: coordinates.h:36
Type
Types of vehicle actions as part of task (mission).
Definition: action.h:30
double heading
Heading in radians.
Definition: move_action.h:109
Generic action.
Definition: action.h:22
Move_action(const Property_list &p)
Construct move action from protobuf command.
Definition: move_action.h:53
Map Action type enum value to specific Action type class.
Definition: action.h:120
Turn_type
Turn type at waypoint.
Definition: move_action.h:30
Move_action(Wgs84_position position, double wait_time, double acceptance_radius, double loiter_orbit, double heading, double elevation)
Construct move action explicitly.
Definition: move_action.h:38
Move vehicle to the specific position (waypoint).
Definition: move_action.h:23
double loiter_orbit
Radius of the point fly-by orbit in meters.
Definition: move_action.h:104
double acceptance_radius
Acceptance radius of the target position in meters.
Definition: move_action.h:97
double wait_time
Wait interval in seconds.
Definition: move_action.h:90
Wgs84_position position
Target global position of the movement.
Definition: move_action.h:84
#define DEFINE_COMMON_CLASS(__class_name,...)
Use this macro to define some common attributes for a class.
Definition: utils.h:25
Coordinates manipulation.