33 #define WP_FLAG_GLOBAL 0
34 #define WP_FLAG_ENU_I 1
35 #define WP_FLAG_ENU_F 2
36 #define WP_FLAG_LLA_I 3
50 #define WaypointX(_wp) waypoint_get_x(_wp)
51 #define WaypointY(_wp) waypoint_get_y(_wp)
52 #define WaypointAlt(_wp) waypoint_get_alt(_wp)
53 #define Height(_h) (_h)
bool waypoint_is_global(uint8_t wp_id)
float waypoint_get_y(uint8_t wp_id)
Get Y/North coordinate of waypoint in meters.
void waypoint_set_lla(uint8_t wp_id, struct LlaCoor_i *lla)
vector in East North Up coordinates Units: meters
void waypoint_position_copy(uint8_t wp_dest, uint8_t wp_src)
void waypoint_set_alt(uint8_t wp_id, float alt)
Set altitude of waypoint in meters (above reference)
const uint8_t nb_waypoint
void waypoint_set_global_flag(uint8_t wp_id)
void waypoint_set_enu(uint8_t wp_id, struct EnuCoor_f *enu)
Set local ENU waypoint coordinates.
vector in Latitude, Longitude and Altitude
void waypoint_globalize(uint8_t wp_id)
update global LLA coordinates from its ENU coordinates
int32_t alt
in millimeters above WGS84 reference ellipsoid
void waypoint_set_alt_i(uint8_t wp_id, int32_t alt)
Paparazzi floating point math for geodetic calculations.
float waypoint_get_alt(uint8_t wp_id)
Get altitude of waypoint in meters (above reference)
void waypoints_localize_all(void)
update local ENU coordinates of all global waypoints
void waypoint_move_lla(uint8_t wp_id, struct LlaCoor_i *lla)
void waypoint_move_enu_i(uint8_t wp_id, struct EnuCoor_i *new_pos)
void waypoint_set_xy_i(uint8_t wp_id, int32_t x, int32_t y)
Set only local XY coordinates of waypoint without update altitude.
void waypoint_set_here(uint8_t wp_id)
set waypoint to current location and altitude
void waypoint_set_latlon(uint8_t wp_id, struct LlaCoor_i *lla)
set waypoint latitude/longitude without updating altitude
void waypoint_clear_global_flag(uint8_t wp_id)
Paparazzi fixed point math for geodetic calculations.
struct LlaCoor_i * waypoint_get_lla(uint8_t wp_id)
Get LLA coordinates of waypoint.
void waypoint_copy(uint8_t wp_dest, uint8_t wp_src)
copy one waypoint to another, this includes all flags from the source waypoint
vector in East North Up coordinates
float waypoint_get_x(uint8_t wp_id)
Get X/East coordinate of waypoint in meters.
void waypoint_set_enu_i(uint8_t wp_id, struct EnuCoor_i *enu)
void waypoints_init(void)
initialize global and local waypoints
struct EnuCoor_i enu_i
with INT32_POS_FRAC
void waypoint_set_here_2d(uint8_t wp_id)
set waypoint to current horizontal location without modifying altitude
uint8_t flags
bitmask encoding valid representations and if local or global
void waypoint_localize(uint8_t wp_id)
update local ENU coordinates from its LLA coordinates
struct Waypoint waypoints[]
size == nb_waypoint, waypoint 0 is a dummy waypoint