Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
pprz_geodetic_float.h File Reference

Paparazzi floating point math for geodetic calculations. More...

#include "pprz_geodetic.h"
#include "pprz_algebra_float.h"
#include "std.h"
+ Include dependency graph for pprz_geodetic_float.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  EcefCoor_f
 vector in EarthCenteredEarthFixed coordinates More...
 
struct  LlaCoor_f
 vector in Latitude, Longitude and Altitude More...
 
struct  NedCoor_f
 vector in North East Down coordinates Units: meters More...
 
struct  EnuCoor_f
 vector in East North Up coordinates Units: meters More...
 
struct  UtmCoor_f
 position in UTM coordinates Units: meters More...
 
struct  LtpDef_f
 definition of the local (flat earth) coordinate system More...
 

Functions

void lla_of_utm_f (struct LlaCoor_f *lla, struct UtmCoor_f *utm)
 
void utm_of_lla_f (struct UtmCoor_f *utm, struct LlaCoor_f *lla)
 
void ltp_def_from_ecef_f (struct LtpDef_f *def, struct EcefCoor_f *ecef)
 
void ltp_def_from_lla_f (struct LtpDef_f *def, struct LlaCoor_f *lla)
 
void lla_of_ecef_f (struct LlaCoor_f *out, struct EcefCoor_f *in)
 
void ecef_of_lla_f (struct EcefCoor_f *out, struct LlaCoor_f *in)
 
void enu_of_ecef_point_f (struct EnuCoor_f *enu, struct LtpDef_f *def, struct EcefCoor_f *ecef)
 
void ned_of_ecef_point_f (struct NedCoor_f *ned, struct LtpDef_f *def, struct EcefCoor_f *ecef)
 
void enu_of_ecef_vect_f (struct EnuCoor_f *enu, struct LtpDef_f *def, struct EcefCoor_f *ecef)
 
void ned_of_ecef_vect_f (struct NedCoor_f *ned, struct LtpDef_f *def, struct EcefCoor_f *ecef)
 
void enu_of_lla_point_f (struct EnuCoor_f *enu, struct LtpDef_f *def, struct LlaCoor_f *lla)
 
void ned_of_lla_point_f (struct NedCoor_f *ned, struct LtpDef_f *def, struct LlaCoor_f *lla)
 
void ecef_of_enu_point_f (struct EcefCoor_f *ecef, struct LtpDef_f *def, struct EnuCoor_f *enu)
 
void ecef_of_ned_point_f (struct EcefCoor_f *ecef, struct LtpDef_f *def, struct NedCoor_f *ned)
 
void ecef_of_enu_vect_f (struct EcefCoor_f *ecef, struct LtpDef_f *def, struct EnuCoor_f *enu)
 
void ecef_of_ned_vect_f (struct EcefCoor_f *ecef, struct LtpDef_f *def, struct NedCoor_f *ned)
 

Detailed Description

Paparazzi floating point math for geodetic calculations.

Definition in file pprz_geodetic_float.h.


Data Structure Documentation

◆ EcefCoor_f

struct EcefCoor_f

vector in EarthCenteredEarthFixed coordinates

Origin at center of mass of the Earth. Z-axis is pointing north, the x-axis intersects the sphere of the earth at 0° latitude (Equator) and 0° longitude (Greenwich). Y-axis completes it to right-hand system. Units: meters

Definition at line 45 of file pprz_geodetic_float.h.

Data Fields
float x in meters
float y in meters
float z in meters

◆ LlaCoor_f

struct LlaCoor_f

vector in Latitude, Longitude and Altitude

Definition at line 54 of file pprz_geodetic_float.h.

Data Fields
float alt in meters (normally above WGS84 reference ellipsoid)
float lat in radians
float lon in radians

◆ NedCoor_f

struct NedCoor_f

vector in North East Down coordinates Units: meters

Definition at line 63 of file pprz_geodetic_float.h.

Data Fields
float x in meters
float y in meters
float z in meters

◆ EnuCoor_f

struct EnuCoor_f

vector in East North Up coordinates Units: meters

Definition at line 72 of file pprz_geodetic_float.h.

Data Fields
float x in meters
float y in meters
float z in meters

◆ UtmCoor_f

struct UtmCoor_f

position in UTM coordinates Units: meters

Definition at line 81 of file pprz_geodetic_float.h.

Data Fields
float alt in meters (above WGS84 reference ellipsoid or above MSL)
float east in meters
float north in meters
uint8_t zone UTM zone number.

◆ LtpDef_f

struct LtpDef_f

definition of the local (flat earth) coordinate system

Defines the origin of the local coordinate system in ECEF and LLA coordinates and the roation matrix from ECEF to local frame

Definition at line 93 of file pprz_geodetic_float.h.

+ Collaboration diagram for LtpDef_f:
Data Fields
struct EcefCoor_f ecef origin of local frame in ECEF
float hmsl Height above mean sea level in meters.
struct LlaCoor_f lla origin of local frame in LLA
struct FloatRMat ltp_of_ecef rotation from ECEF to local frame

Function Documentation

◆ ecef_of_enu_point_f()

void ecef_of_enu_point_f ( struct EcefCoor_f ecef,
struct LtpDef_f def,
struct EnuCoor_f enu 
)

◆ ecef_of_enu_vect_f()

void ecef_of_enu_vect_f ( struct EcefCoor_f ecef,
struct LtpDef_f def,
struct EnuCoor_f enu 
)

◆ ecef_of_lla_f()

◆ ecef_of_ned_point_f()

void ecef_of_ned_point_f ( struct EcefCoor_f ecef,
struct LtpDef_f def,
struct NedCoor_f ned 
)

Definition at line 157 of file pprz_geodetic_float.c.

References ecef_of_enu_point_f(), and ENU_OF_TO_NED.

Referenced by detection_cb(), stateCalcPositionEcef_f(), stateCalcPositionEcef_i(), stateCalcPositionLla_f(), and tag_tracking_report().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ecef_of_ned_vect_f()

void ecef_of_ned_vect_f ( struct EcefCoor_f ecef,
struct LtpDef_f def,
struct NedCoor_f ned 
)

Definition at line 192 of file pprz_geodetic_float.c.

References ecef_of_enu_vect_f(), and ENU_OF_TO_NED.

Referenced by stateCalcAccelEcef_f(), and stateCalcSpeedEcef_f().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ enu_of_ecef_point_f()

void enu_of_ecef_point_f ( struct EnuCoor_f enu,
struct LtpDef_f def,
struct EcefCoor_f ecef 
)

Definition at line 85 of file pprz_geodetic_float.c.

References LtpDef_f::ecef, LtpDef_f::ltp_of_ecef, MAT33_VECT3_MUL, and VECT3_DIFF.

Referenced by enu_of_lla_point_f(), ned_of_ecef_point_f(), stateCalcPositionEnu_f(), and stateCalcPositionEnu_i().

+ Here is the caller graph for this function:

◆ enu_of_ecef_vect_f()

void enu_of_ecef_vect_f ( struct EnuCoor_f enu,
struct LtpDef_f def,
struct EcefCoor_f ecef 
)

Definition at line 100 of file pprz_geodetic_float.c.

References LtpDef_f::ltp_of_ecef, and MAT33_VECT3_MUL.

Referenced by ned_of_ecef_vect_f(), and stateCalcSpeedEnu_f().

+ Here is the caller graph for this function:

◆ enu_of_lla_point_f()

void enu_of_lla_point_f ( struct EnuCoor_f enu,
struct LtpDef_f def,
struct LlaCoor_f lla 
)

Definition at line 112 of file pprz_geodetic_float.c.

References ecef_of_lla_f(), and enu_of_ecef_point_f().

Referenced by acInfoCalcPositionEnu_f(), acInfoCalcPositionEnu_i(), nav_land_at_loc(), and stateCalcPositionEnu_f().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ lla_of_ecef_f()

void lla_of_ecef_f ( struct LlaCoor_f out,
struct EcefCoor_f in 
)

◆ lla_of_utm_f()

◆ ltp_def_from_ecef_f()

void ltp_def_from_ecef_f ( struct LtpDef_f def,
struct EcefCoor_f ecef 
)

Definition at line 36 of file pprz_geodetic_float.c.

References LtpDef_f::ecef, LlaCoor_f::lat, LtpDef_f::lla, lla_of_ecef_f(), LlaCoor_f::lon, LtpDef_f::ltp_of_ecef, FloatRMat::m, and VECT3_COPY.

+ Here is the call graph for this function:

◆ ltp_def_from_lla_f()

void ltp_def_from_lla_f ( struct LtpDef_f def,
struct LlaCoor_f lla 
)

Definition at line 60 of file pprz_geodetic_float.c.

References LtpDef_f::ecef, ecef_of_lla_f(), LlaCoor_f::lat, LtpDef_f::lla, LLA_COPY, LlaCoor_f::lon, LtpDef_f::ltp_of_ecef, and FloatRMat::m.

+ Here is the call graph for this function:

◆ ned_of_ecef_point_f()

void ned_of_ecef_point_f ( struct NedCoor_f ned,
struct LtpDef_f def,
struct EcefCoor_f ecef 
)

Definition at line 92 of file pprz_geodetic_float.c.

References enu_of_ecef_point_f(), and ENU_OF_TO_NED.

Referenced by ned_of_lla_point_f(), stateCalcPositionNed_f(), and stateCalcPositionNed_i().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ned_of_ecef_vect_f()

void ned_of_ecef_vect_f ( struct NedCoor_f ned,
struct LtpDef_f def,
struct EcefCoor_f ecef 
)

Definition at line 105 of file pprz_geodetic_float.c.

References enu_of_ecef_vect_f(), and ENU_OF_TO_NED.

Referenced by gps_cb(), ins_float_invariant_update_gps(), stateCalcAccelNed_f(), stateCalcHorizontalSpeedNorm_i(), and stateCalcSpeedNed_f().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ned_of_lla_point_f()

void ned_of_lla_point_f ( struct NedCoor_f ned,
struct LtpDef_f def,
struct LlaCoor_f lla 
)

Definition at line 119 of file pprz_geodetic_float.c.

References ecef_of_lla_f(), and ned_of_ecef_point_f().

Referenced by stateCalcPositionNed_f().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ utm_of_lla_f()