NMEA0183 icon indicating copy to clipboard operation
NMEA0183 copied to clipboard

Add APB message

Open tonswieb opened this issue 2 years ago • 1 comments

Hi @ttlappalainen , Could you add the APB message to your library. Thanks.

tonswieb avatar Aug 17 '22 21:08 tonswieb

You could use NMEA0183GetDouble to read double values. It set value to NA, if value does not exist. E.g., APB.xte=NMEA0183GetDouble(NMEA0183Msg.Field(2)); APB.btw=NMEA0183GetDouble(NMEA0183Msg.Field(10),degToRad);

In generally sorting structure saves some memory. Now you have: char, char, double, char, char, double,... Due to aligning structure will eat space: char, char, (6 byte align), double, char, char, (6 byte align), double. By sorting all doubles first saves aligning bytes.

ttlappalainen avatar Aug 18 '22 04:08 ttlappalainen