mirror of
https://github.com/thooge/esp32-nmea2000-obp60.git
synced 2025-12-24 03:03:06 +01:00
Added waypoint name to boatdata
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#define GWTYPE_UINT32 2
|
||||
#define GWTYPE_UINT16 3
|
||||
#define GWTYPE_INT16 4
|
||||
#define GWTYPE_STRING 5
|
||||
#define GWTYPE_USER 100
|
||||
|
||||
class GwBoatItemTypes
|
||||
@@ -15,6 +16,7 @@ public:
|
||||
static int getType(const uint16_t &x) { return GWTYPE_UINT16; }
|
||||
static int getType(const int16_t &x) { return GWTYPE_INT16; }
|
||||
static int getType(const double &x) { return GWTYPE_DOUBLE; }
|
||||
static int getType(const String &x) { return GWTYPE_STRING; }
|
||||
static int getType(const GwSatInfoList &x) { return GWTYPE_USER + 1; }
|
||||
};
|
||||
|
||||
|
||||
@@ -58,6 +58,7 @@ class GwBoatItemBase{
|
||||
GWSC(formatRot);
|
||||
GWSC(formatDate);
|
||||
GWSC(formatTime);
|
||||
GWSC(formatName);
|
||||
protected:
|
||||
int type;
|
||||
unsigned long lastSet=0;
|
||||
@@ -235,6 +236,7 @@ class GwBoatData{
|
||||
GWBOATDATA(double,XTE,formatXte) // cross track error
|
||||
GWBOATDATA(double,WPLat,formatLatitude) // waypoint latitude
|
||||
GWBOATDATA(double,WPLon,formatLongitude) // waypoint longitude
|
||||
GWBOATDATA(String,WPName,formatName) // waypoint name
|
||||
GWSPECBOATDATA(GwBoatDataSatList,SatInfo,GwSatInfoList::toType,formatFixed0);
|
||||
public:
|
||||
GwBoatData(GwLog *logger, GwConfigHandler *cfg);
|
||||
|
||||
Reference in New Issue
Block a user