Control & Diagnostic Extension 5.15.5
Control & Diagnostic Extension 5.15.5
Release 5.15.5
This release fixes GPS position reporting from NMEA 2000 receivers, and fixes memory leaks and signal decoding problems in the C++ CAN message classes.
Fixes
GPS position from NMEA 2000 receivers
The CAN location plugin now reports a position fix to gpsd from a wider range of NMEA 2000 GPS receivers.
- GPS messages are accepted at any priority. Before, a receiver sending at a non-default priority was ignored.
- A fix is reported from Position Rapid Update (PGN 129025) and GNSS DOPs (PGN 129539). GNSS Position Data (PGN 129029) is no longer required.
- When the receiver's time message has no date, the system clock is used for the timestamp.
- The satellite count is taken from PGN 129029 or 129540. When neither is available, the satellite count is left out rather than reported as 0, which gpsd treats as no fix.
CAN signal values (C# and C++)
- Unscaled (raw) reads now return the value on the bus, including not-available markers such as 0x7FFF. Before, they were limited to the signal's scaled range.
- Signed enumeration signals now decode as signed values.
- Setting a big-endian (Motorola) signal now fully replaces its previous value. Before, bits from the old value could remain and corrupt the new one.
- Setting a signal to its maximum value in a message where the signal was not available now updates the message. Before, the change was skipped and the message was sent with the not-available value.
C++ generated CAN message classes
- Fixed memory leaks in the generated message classes, including about 450 bytes leaked on every J1939 message sent.
- Copying a message that was built to send no longer corrupts memory.
- Messages deleted through a base class pointer, such as those returned by CreateObject, are now fully cleaned up.
C++ signal decoding now matches C#
C++ applications now decode CAN signals the same way C# applications do.
- Signals beyond the first 8 bytes of a message, including all NMEA 2000 fast packet signals, now decode correctly. Signals that cross an 8-byte boundary are also handled.
- Negative values in signed signals now decode correctly.
- Float and double signals now decode correctly.
- 64-bit signals now decode correctly on 32-bit platforms.
- Messages whose length is not a multiple of 8 bytes no longer cause a buffer overflow.
Compatibility notes
No API changes. C++ applications should be rebuilt so the generated CAN message classes pick up these fixes.
If your application relied on unscaled reads being limited to the signal's range, check for not-available values yourself.
C++ applications may see slightly different signal values, now matching C#:
- Scaled values are limited to the signal's minimum and maximum.
- Reads into integer and enum types round to the nearest value instead of truncating. For example, 39.99 now reads as 40.
Please sign in to leave a comment.
Comments
0 comments