1
0
mirror of https://github.com/thooge/esp32-nmea2000-obp60.git synced 2025-12-16 07:23:07 +01:00

intermediate: add nmea0183 to n2k

This commit is contained in:
andreas
2021-10-30 21:37:44 +02:00
parent 0b4aa58d71
commit c8778e4ceb
4 changed files with 184 additions and 9 deletions

View File

@@ -0,0 +1,20 @@
#ifndef _NMEA0183DATATON2K_H
#define _NMEA0183DATATON2K_H
#include "GwLog.h"
#include "GwBoatData.h"
#include "N2kMessages.h"
class NMEA0183DataToN2K{
public:
typedef bool (*N2kSender)(const tN2kMsg &msg);
protected:
GwLog * logger;
GwBoatData *boatData;
N2kSender sender;
public:
NMEA0183DataToN2K(GwLog *logger,GwBoatData *boatData,N2kSender callback);
virtual bool parseAndSend(const char *buffer, int sourceId);
virtual unsigned long *handledPgns()=0;
static NMEA0183DataToN2K* create(GwLog *logger,GwBoatData *boatData,N2kSender callback);
};
#endif