Adafruit GPS Library
Classes | Macros | Enumerations
Adafruit_NMEA.h File Reference

Hardware-independent NMEA sentence and field utilities. More...

#include <stddef.h>
#include <stdint.h>

Go to the source code of this file.

Classes

struct  nmea_span_t
 
struct  nmea_sentence_t
 
struct  nmea_decimal_t
 
class  Adafruit_NMEA
 

Macros

#define NMEA_COMMAND_OVERHEAD   7
 Bytes for '$', '*HH', CR/LF, and NUL.
 

Enumerations

enum  nmea_frame_status_t : uint8_t {
  NMEA_FRAME_INCOMPLETE, NMEA_FRAME_VALID, NMEA_FRAME_BAD_FORMAT, NMEA_FRAME_BAD_CHECKSUM,
  NMEA_FRAME_OVERFLOW
}
 
enum  nmea_number_status_t : uint8_t {
  NMEA_NUMBER_VALID, NMEA_NUMBER_MISSING, NMEA_NUMBER_EMPTY, NMEA_NUMBER_BAD_FORMAT,
  NMEA_NUMBER_OUT_OF_RANGE
}
 Result of converting one complete field to a decimal number. More...
 

Detailed Description

Hardware-independent NMEA sentence and field utilities.

Written for Adafruit Industries. BSD license; see license.txt.

Enumeration Type Documentation

◆ nmea_frame_status_t

enum nmea_frame_status_t : uint8_t

Result of framing or validating a sentence. Recognition belongs to GNSS or receiver-specific decoders: an unknown address can still be VALID.

Enumerator
NMEA_FRAME_INCOMPLETE 

More bytes are needed; no new sentence is ready.

NMEA_FRAME_VALID 

Complete format and checksum are valid.

NMEA_FRAME_BAD_FORMAT 

Invalid argument, address, framing, or trailer.

NMEA_FRAME_BAD_CHECKSUM 

Two hex checksum digits do not match the payload.

NMEA_FRAME_OVERFLOW 

Receive buffer has no room for the whole sentence.

◆ nmea_number_status_t

enum nmea_number_status_t : uint8_t

Result of converting one complete field to a decimal number.

Enumerator
NMEA_NUMBER_VALID 

The complete field is a representable decimal.

NMEA_NUMBER_MISSING 

Field is absent.

NMEA_NUMBER_EMPTY 

Field is present but empty.

NMEA_NUMBER_BAD_FORMAT 

Invalid character or decimal syntax.

NMEA_NUMBER_OUT_OF_RANGE 

Coefficient or decimal-place count overflowed.