AgIsoStack++
A control-function-focused implementation of the major ISOBUS and J1939 protocols
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Private Attributes | Static Private Attributes | List of all members
isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate Class Reference

This message is a way for a GNSS receiver to provide a current position without using fast packet based on The content of the last position data combined from the GNSS Position Data message and any prior position delta messages. This PGN provides latitude and longitude referenced to WGS84. More...

#include <nmea2000_message_definitions.hpp>

Public Member Functions

 PositionDeltaHighPrecisionRapidUpdate (std::shared_ptr< ControlFunction > source)
 Constructor for a PositionDeltaHighPrecisionRapidUpdate message data object.
 
std::shared_ptr< ControlFunctionget_control_function () const
 Returns the control function sending this instance of this message.
 
std::uint32_t get_timestamp () const
 Returns a timestamp in milliseconds corresponding to when the message was last sent or received.
 
bool set_timestamp (std::uint32_t timestamp)
 Sets the time in milliseconds when the message was last sent or received.
 
std::int32_t get_raw_latitude_delta () const
 Returns the latitude delta relative to our last position in 1x10E-16 degrees.
 
double get_latitude_delta () const
 Returns the latitude delta relative to our last position in degrees.
 
bool set_latitude_delta (std::int32_t delta)
 Sets the current latitude delta in units of 1x10E-16 degrees.
 
std::int32_t get_raw_longitude_delta () const
 Returns the longitude delta relative to our last position in 1x10E-16 degrees.
 
double get_longitude_delta () const
 Returns the longitude delta relative to our last position in degrees.
 
bool set_longitude_delta (std::int32_t delta)
 Sets the current longitude delta relative to our last position in 1x10E-16 degrees.
 
std::uint8_t get_sequence_id () const
 Returns the sequence ID. This is used to associate data within other PGNs with this message.
 
bool set_sequence_id (std::uint8_t sequenceNumber)
 Sets the sequence ID for this message.
 
std::uint8_t get_raw_time_delta () const
 Returns the raw time delta since the last reported time in 5x10e-3 seconds.
 
double get_time_delta () const
 Returns the raw time delta since the last reported time in seconds.
 
bool set_time_delta (std::uint8_t delta)
 Sets the time delta, in units of 5x10e-3 seconds.
 
void serialize (std::vector< std::uint8_t > &buffer) const
 Serializes the current state of this object into a buffer to be sent on the CAN bus.
 
bool deserialize (const CANMessage &receivedMessage)
 Deserializes a CAN message to populate this object's contents. Updates the timestamp when called.
 

Static Public Member Functions

static std::uint32_t get_timeout ()
 Returns the timeout (the sending interval) for this message in milliseconds.
 

Private Attributes

std::shared_ptr< ControlFunctionsenderControlFunction
 The sender of the message data.
 
std::uint32_t messageTimestamp_ms = 0
 A timestamp in milliseconds when this message was last sent or received.
 
std::int32_t latitudeDelta = 0
 The latitude delta in 1x10E-16 degrees.
 
std::int32_t longitudeDelta = 0
 The longitude delta in 1x10E-16 degrees.
 
std::uint8_t sequenceID = 0
 The sequence identifier field is used to tie related PGNs together. In this case, ties back to GNSS Position Data sequence ID most likely.
 
std::uint8_t timeDelta = 0
 The time delta in 5x10e-3 seconds.
 

Static Private Attributes

static constexpr std::uint32_t CYCLIC_MESSAGE_RATE_MS = 250
 The transmit interval for this message as specified in NMEA2000.
 

Detailed Description

This message is a way for a GNSS receiver to provide a current position without using fast packet based on The content of the last position data combined from the GNSS Position Data message and any prior position delta messages. This PGN provides latitude and longitude referenced to WGS84.

Definition at line 378 of file nmea2000_message_definitions.hpp.

Constructor & Destructor Documentation

◆ PositionDeltaHighPrecisionRapidUpdate()

isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::PositionDeltaHighPrecisionRapidUpdate ( std::shared_ptr< ControlFunction > source)
explicit

Constructor for a PositionDeltaHighPrecisionRapidUpdate message data object.

Parameters
[in]sourceThe control function sending this message

Definition at line 469 of file nmea2000_message_definitions.cpp.

Member Function Documentation

◆ deserialize()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::deserialize ( const CANMessage & receivedMessage)

Deserializes a CAN message to populate this object's contents. Updates the timestamp when called.

Parameters
[in]receivedMessageThe CAN message to parse when deserializing
Returns
True if the message was successfully deserialized and the data content was different than the stored content.

Definition at line 568 of file nmea2000_message_definitions.cpp.

Here is the call graph for this function:

◆ get_control_function()

std::shared_ptr< ControlFunction > isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_control_function ( ) const

Returns the control function sending this instance of this message.

Returns
The control function sending this instance of this message

Definition at line 474 of file nmea2000_message_definitions.cpp.

◆ get_latitude_delta()

double isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_latitude_delta ( ) const

Returns the latitude delta relative to our last position in degrees.

Returns
Latitude delta relative to our last position in degrees

Definition at line 496 of file nmea2000_message_definitions.cpp.

◆ get_longitude_delta()

double isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_longitude_delta ( ) const

Returns the longitude delta relative to our last position in degrees.

Returns
Longitude delta relative to our last position in degrees

Definition at line 513 of file nmea2000_message_definitions.cpp.

◆ get_raw_latitude_delta()

std::int32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_raw_latitude_delta ( ) const

Returns the latitude delta relative to our last position in 1x10E-16 degrees.

Returns
Latitude delta relative to our last position in 1x10E-16 degrees

Definition at line 491 of file nmea2000_message_definitions.cpp.

◆ get_raw_longitude_delta()

std::int32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_raw_longitude_delta ( ) const

Returns the longitude delta relative to our last position in 1x10E-16 degrees.

Returns
Longitude delta relative to our last position in 1x10E-16 degrees

Definition at line 508 of file nmea2000_message_definitions.cpp.

◆ get_raw_time_delta()

std::uint8_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_raw_time_delta ( ) const

Returns the raw time delta since the last reported time in 5x10e-3 seconds.

Returns
Time delta in units of 5x10e-3 seconds

Definition at line 537 of file nmea2000_message_definitions.cpp.

◆ get_sequence_id()

std::uint8_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_sequence_id ( ) const

Returns the sequence ID. This is used to associate data within other PGNs with this message.

Returns
The sequence ID for this message

Definition at line 525 of file nmea2000_message_definitions.cpp.

◆ get_time_delta()

double isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_time_delta ( ) const

Returns the raw time delta since the last reported time in seconds.

Returns
Time delta in units of seconds

Definition at line 542 of file nmea2000_message_definitions.cpp.

◆ get_timeout()

std::uint32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_timeout ( )
static

Returns the timeout (the sending interval) for this message in milliseconds.

Returns
This message's timeout (the sending interval) in milliseconds

Definition at line 587 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

◆ get_timestamp()

std::uint32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::get_timestamp ( ) const

Returns a timestamp in milliseconds corresponding to when the message was last sent or received.

Returns
A timestamp in milliseconds corresponding to when the message was last sent or received

Definition at line 479 of file nmea2000_message_definitions.cpp.

◆ serialize()

void isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::serialize ( std::vector< std::uint8_t > & buffer) const

Serializes the current state of this object into a buffer to be sent on the CAN bus.

Parameters
[in]bufferA buffer to serialize the message data into

Definition at line 554 of file nmea2000_message_definitions.cpp.

◆ set_latitude_delta()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::set_latitude_delta ( std::int32_t delta)

Sets the current latitude delta in units of 1x10E-16 degrees.

Parameters
[in]deltaLatitude delta to set in units of 1x10E-16 degrees
Returns
True if the value that was set differed from the stored value, otherwise false

Definition at line 501 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

◆ set_longitude_delta()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::set_longitude_delta ( std::int32_t delta)

Sets the current longitude delta relative to our last position in 1x10E-16 degrees.

Parameters
[in]deltaLongitude delta to set in units of 1x10E-16 degrees
Returns
True if the value that was set differed from the stored value, otherwise false

Definition at line 518 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

◆ set_sequence_id()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::set_sequence_id ( std::uint8_t sequenceNumber)

Sets the sequence ID for this message.

Parameters
[in]sequenceNumberThe sequence number to set. Max value is 252.
Returns
True if the value that was set differed from the stored value, otherwise false

Definition at line 530 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

◆ set_time_delta()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::set_time_delta ( std::uint8_t delta)

Sets the time delta, in units of 5x10e-3 seconds.

Parameters
[in]deltaThe time delta to set in units of 5x10e-3 seconds
Returns
True if the value that was set differed from the stored value, otherwise false

Definition at line 547 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

◆ set_timestamp()

bool isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::set_timestamp ( std::uint32_t timestamp)

Sets the time in milliseconds when the message was last sent or received.

Parameters
[in]timestampThe timestamp (in milliseconds) to set for when this message was sent or received
Returns
True if the value that was set differed from the stored value, otherwise false

Definition at line 484 of file nmea2000_message_definitions.cpp.

Here is the caller graph for this function:

Member Data Documentation

◆ CYCLIC_MESSAGE_RATE_MS

constexpr std::uint32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::CYCLIC_MESSAGE_RATE_MS = 250
staticconstexprprivate

The transmit interval for this message as specified in NMEA2000.

Definition at line 460 of file nmea2000_message_definitions.hpp.

◆ latitudeDelta

std::int32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::latitudeDelta = 0
private

The latitude delta in 1x10E-16 degrees.

Definition at line 464 of file nmea2000_message_definitions.hpp.

◆ longitudeDelta

std::int32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::longitudeDelta = 0
private

The longitude delta in 1x10E-16 degrees.

Definition at line 465 of file nmea2000_message_definitions.hpp.

◆ messageTimestamp_ms

std::uint32_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::messageTimestamp_ms = 0
private

A timestamp in milliseconds when this message was last sent or received.

Definition at line 463 of file nmea2000_message_definitions.hpp.

◆ senderControlFunction

std::shared_ptr<ControlFunction> isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::senderControlFunction
private

The sender of the message data.

Definition at line 462 of file nmea2000_message_definitions.hpp.

◆ sequenceID

std::uint8_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::sequenceID = 0
private

The sequence identifier field is used to tie related PGNs together. In this case, ties back to GNSS Position Data sequence ID most likely.

Definition at line 466 of file nmea2000_message_definitions.hpp.

◆ timeDelta

std::uint8_t isobus::NMEA2000Messages::PositionDeltaHighPrecisionRapidUpdate::timeDelta = 0
private

The time delta in 5x10e-3 seconds.

Definition at line 467 of file nmea2000_message_definitions.hpp.


The documentation for this class was generated from the following files: