42 lines
1.2 KiB
C
42 lines
1.2 KiB
C
//
|
|
// Created by villuton on 25.03.25.
|
|
//
|
|
|
|
#ifndef NMEA_GSA_H
|
|
#define NMEA_GSA_H
|
|
|
|
#include "Nmea_Config.h"
|
|
|
|
#define GSA_MSG_ID "GSA"
|
|
#define GSA_MSG_ID_LEN (3)
|
|
|
|
#define GSA_FIX_MODE_EMPTY (0)
|
|
#define GSA_FIX_MODE_Manual 'M'
|
|
#define GSA_FIX_MODE_Automatic 'A'
|
|
|
|
typedef enum {
|
|
GSA_NaN = 0, /**< (Empty field) */
|
|
GSA_FixNotAvailable = 1, /**< Fix not available */
|
|
GSA_2D = 2, /**< 2D */
|
|
GSA_3D = 3 /**< 3D */
|
|
}eGSA_fix_type;
|
|
|
|
|
|
/**
|
|
* GSA packet information structure (Satellite status)
|
|
*/
|
|
typedef struct
|
|
{
|
|
char fix_mode; /**< Mode (M = Manual, forced to operate in 2D or 3D; A = Automatic, 3D/2D) */
|
|
int fix_type; /**< Type, used for navigation (1 = Fix not available; 2 = 2D; 3 = 3D) */
|
|
int sat_prn[NMEA_MAXSAT]; /**< PRNs of satellites used in position fix (null for unused fields) */
|
|
double PDOP; /**< Dilution of precision */
|
|
double HDOP; /**< Horizontal dilution of precision */
|
|
double VDOP; /**< Vertical dilution of precision */
|
|
|
|
} tNmeaGSA;
|
|
|
|
bool NmeaGsa_Parse(char *str, size_t len, tNmeaGSA *result);
|
|
|
|
#endif //NMEA_GSA_H
|