35 #include "pprzlink/pprzlink_device.h"
39 #define Invert2Bytes(x) ((x>>8) | (x<<8))
40 #define Invert4Bytes(x) ((x>>24) | ((x<<8) & 0x00FF0000) | ((x>>8) & 0x0000FF00) | (x<<24))
69 } __attribute__((packed));
110 } __attribute__((packed));
221 if ((p->
nav_type >> 8 & 0x7) >= 0x4) {
223 }
else if ((p->
nav_type >> 8 & 0x7) >= 0x1) {
269 if (start_time2 == 0) {
276 switch (message_id) {
289 struct link_device *
dev = &((SIRF_GPS_LINK).device);
291 while (dev->char_available(dev->periph)) {
uint16_t heading_err
in degrees * 10^2
uint8_t ch1prn
pseudo-random noise, 12 channels
int16_t vy
y-velocity * 8 in m/s
arch independent UART (Universal Asynchronous Receiver/Transmitter) API
uint8_t msg_id
hex value 0x02 ( = decimal 2)
void gps_sirf_event(void)
uint32_t pacc
position accuracy in cm
uint32_t ete
estimated time error, in seconds * 10^2
uint16_t sog
speed over ground, in m/s * 10^2
uint8_t nb_channels
Number of scanned satellites.
uint8_t msg_id
hex value 0x29 (= decimal 41)
int32_t longitude
in degrees (+= East) *10*7
uint8_t valid_fields
bitfield indicating valid fields (GPS_VALID_x_BIT)
int16_t heading_rate
in deg/s * 10^2
int32_t z_pos
z-position in m
Main include for ABI (AirBorneInterface).
Sirf protocol specific code.
uint32_t clock_drift_err
in m/s * 10^2
uint16_t nav_valid
if equal to 0x0000, then navigation solution is valid
void sirf_parse_msg(void)
#define GPS_FIX_3D
3D GPS fix
uint8_t add_info
Additional mode info.
int16_t mag_var
not implemented
uint32_t last_3dfix_ticks
cpu time ticks at last valid 3D fix
int32_t alt
in millimeters above WGS84 reference ellipsoid
uint32_t sacc
speed accuracy in cm/s
uint32_t last_msg_time
cpu time in sec at last received GPS message
uint32_t cacc
course accuracy in rad*1e7
Paparazzi floating point math for geodetic calculations.
#define GPS_VALID_COURSE_BIT
int32_t hmsl
height above mean sea level (MSL) in mm
uint16_t cog
course over ground, in degrees clockwise from true north * 10^2
int32_t alt_ellipsoid
in meters *10^2
int32_t alt_msl
in meters *10^2
uint8_t num_sat
Number of satellites used for solution.
uint32_t tow
GPS time of week in ms.
#define GPS_FIX_NONE
No GPS fix.
uint32_t tow
time of week in seconds *10^3]
uint32_t ehpe
estimated horizontal position error, in meters * 10^2
#define GPS_FIX_2D
2D GPS fix
Device independent GPS code (interface)
uint16_t pdop
position dilution of precision scaled by 100
uint16_t extended_week_number
struct EcefCoor_i ecef_pos
position in ECEF in cm
int16_t vz
z-velocity * 8 in m/s
uint8_t num_sat
Number of satellites in fix.
#define GPS_VALID_HMSL_BIT
uint32_t clock_bias_err
in m * 10^2
int32_t lon
in degrees*1e7
volatile uint32_t nb_sec_rem
remainder of seconds since startup in CPU_TICKS
int32_t x_pos
x-position in m
int32_t clock_drift
in m/s * 10^2
static const struct usb_device_descriptor dev
char msg_buf[SIRF_MAXLEN]
buffer for storing one nmea-line
uint32_t distance
Distance traveled since reset in m.
uint32_t last_3dfix_time
cpu time in sec at last valid 3D fix
int32_t course
GPS course over ground in rad*1e7, [0, 2*Pi]*1e7 (CW/north)
uint32_t tow
time of week in seconds * 10^2
volatile uint32_t nb_sec
full seconds since startup
uint16_t ehve
estimated horizontal velocity error in m/s * 10^2
void sirf_parse_char(uint8_t c)
#define GPS_VALID_POS_ECEF_BIT
uint8_t hdop
horizontal dilution of precision *5 (0.2 precision)
uint32_t last_msg_ticks
cpu time ticks at last received GPS message
#define GPS_VALID_POS_LLA_BIT
int32_t latitude
in degrees (+= North) *10^7
uint8_t num_sv
number of sat in fix
arch independent LED (Light Emitting Diodes) API
uint16_t gspeed
norm of 2d ground speed in cm/s
int32_t clock_bias
in m * 10^2
uint16_t distance_err
in meters
struct EcefCoor_i ecef_vel
speed ECEF in cm/s
#define GPS_VALID_VEL_ECEF_BIT
struct LlaCoor_i lla_pos
position in LLA (lat,lon: deg*1e7; alt: mm over ellipsoid)
uint32_t sat_id
satellites used in solution. Each satellite corresponds with a bit, e.g. bit 1 ON = SV 1 is used in s...
int32_t y_pos
y-position in m
uint32_t get_sys_time_usec(void)
Get the time in microseconds since startup.
int32_t lat
in degrees*1e7
uint32_t evpe
estimated vertical position error, in meters * 10^2
int16_t vx
x-velocity * 8 in m/s
int16_t climb_rate
in m/s * 10^2
#define UNINIT
Receiving pprz messages.
uint8_t hdop
Horizontal dilution of precision x 5 (0.2 precision)