AgIsoStack++
A control-function-focused implementation of the major ISOBUS and J1939 protocols
|
Message normally sent by the Tractor ECU on the implement bus on construction and agricultural implements providing to connected systems the current measured ground speed (also includes a free-running distance counter and an indication of the direction of travel). More...
#include <isobus_speed_distance_messages.hpp>
Public Member Functions | |
GroundBasedSpeedData (std::shared_ptr< ControlFunction > sender) | |
Constructor for a GroundBasedSpeedData. | |
std::uint32_t | get_machine_distance () const |
Actual distance traveled by a machine, based on measurements from a sensor such as that is not susceptible to wheel slip (e.g. radar, GPS, LIDAR, or stationary object tracking) | |
bool | set_machine_distance (std::uint32_t distance) |
Sets the actual distance traveled by a machine, based on measurements from a sensor such as that is not susceptible to wheel slip. | |
std::uint16_t | get_machine_speed () const |
Returns the actual ground speed of a machine, measured by a sensor such as that is not susceptible to wheel slip in mm/s. | |
bool | set_machine_speed (std::uint16_t speed) |
Sets the actual ground speed of a machine, measured by a sensor such as that is not susceptible to wheel slip in mm/s. | |
MachineDirection | get_machine_direction_of_travel () const |
Returns A measured signal indicating either forward or reverse as the direction of travel. | |
bool | set_machine_direction_of_travel (MachineDirection directionOfTravel) |
Sets a measured signal indicating either forward or reverse as the direction of travel. | |
std::shared_ptr< ControlFunction > | get_sender_control_function () const |
Returns a pointer to the sender of the message. If an ICF is the sender, returns the ICF being used to transmit from. | |
void | set_timestamp_ms (std::uint32_t timestamp) |
Sets the timestamp for when the message was received or sent. | |
std::uint32_t | get_timestamp_ms () const |
Returns the timestamp for when the message was received, in milliseconds. | |
Private Attributes | |
std::shared_ptr< ControlFunction > const | controlFunction |
The CF that is sending the message. | |
std::uint32_t | timestamp_ms = 0 |
A timestamp for when the message was released in milliseconds. | |
std::uint32_t | groundBasedMachineDistance_mm = 0 |
Stores the ground-based speed's distance in millimeters. | |
std::uint16_t | groundBasedMachineSpeed_mm_per_sec = 0 |
Stores the ground-based speed in mm/s. | |
MachineDirection | machineDirectionState = MachineDirection::NotAvailable |
Stores direction of travel. | |
Message normally sent by the Tractor ECU on the implement bus on construction and agricultural implements providing to connected systems the current measured ground speed (also includes a free-running distance counter and an indication of the direction of travel).
Definition at line 349 of file isobus_speed_distance_messages.hpp.
|
explicit |
Constructor for a GroundBasedSpeedData.
[in] | sender | The control function that is sending this message |
Definition at line 277 of file isobus_speed_distance_messages.cpp.
SpeedMessagesInterface::MachineDirection isobus::SpeedMessagesInterface::GroundBasedSpeedData::get_machine_direction_of_travel | ( | ) | const |
Returns A measured signal indicating either forward or reverse as the direction of travel.
Definition at line 319 of file isobus_speed_distance_messages.cpp.
std::uint32_t isobus::SpeedMessagesInterface::GroundBasedSpeedData::get_machine_distance | ( | ) | const |
Actual distance traveled by a machine, based on measurements from a sensor such as that is not susceptible to wheel slip (e.g. radar, GPS, LIDAR, or stationary object tracking)
Definition at line 282 of file isobus_speed_distance_messages.cpp.
std::uint16_t isobus::SpeedMessagesInterface::GroundBasedSpeedData::get_machine_speed | ( | ) | const |
Returns the actual ground speed of a machine, measured by a sensor such as that is not susceptible to wheel slip in mm/s.
Definition at line 301 of file isobus_speed_distance_messages.cpp.
std::shared_ptr< ControlFunction > isobus::SpeedMessagesInterface::GroundBasedSpeedData::get_sender_control_function | ( | ) | const |
Returns a pointer to the sender of the message. If an ICF is the sender, returns the ICF being used to transmit from.
Definition at line 331 of file isobus_speed_distance_messages.cpp.
std::uint32_t isobus::SpeedMessagesInterface::GroundBasedSpeedData::get_timestamp_ms | ( | ) | const |
Returns the timestamp for when the message was received, in milliseconds.
Definition at line 341 of file isobus_speed_distance_messages.cpp.
bool isobus::SpeedMessagesInterface::GroundBasedSpeedData::set_machine_direction_of_travel | ( | MachineDirection | directionOfTravel | ) |
Sets a measured signal indicating either forward or reverse as the direction of travel.
directionOfTravel | The measured direction of travel for the machine |
Definition at line 324 of file isobus_speed_distance_messages.cpp.
bool isobus::SpeedMessagesInterface::GroundBasedSpeedData::set_machine_distance | ( | std::uint32_t | distance | ) |
Sets the actual distance traveled by a machine, based on measurements from a sensor such as that is not susceptible to wheel slip.
distance | The actual distance traveled by a machine (millimeters) |
Definition at line 294 of file isobus_speed_distance_messages.cpp.
bool isobus::SpeedMessagesInterface::GroundBasedSpeedData::set_machine_speed | ( | std::uint16_t | speed | ) |
Sets the actual ground speed of a machine, measured by a sensor such as that is not susceptible to wheel slip in mm/s.
speed | The actual ground speed of a machine, measured by a sensor such as that is not susceptible to wheel slip in mm/s |
Definition at line 312 of file isobus_speed_distance_messages.cpp.
void isobus::SpeedMessagesInterface::GroundBasedSpeedData::set_timestamp_ms | ( | std::uint32_t | timestamp | ) |
Sets the timestamp for when the message was received or sent.
[in] | timestamp | The timestamp, in milliseconds, when the message was sent or received |
Definition at line 336 of file isobus_speed_distance_messages.cpp.
|
private |
The CF that is sending the message.
Definition at line 409 of file isobus_speed_distance_messages.hpp.
|
private |
Stores the ground-based speed's distance in millimeters.
Definition at line 411 of file isobus_speed_distance_messages.hpp.
|
private |
Stores the ground-based speed in mm/s.
Definition at line 412 of file isobus_speed_distance_messages.hpp.
|
private |
Stores direction of travel.
Definition at line 413 of file isobus_speed_distance_messages.hpp.
|
private |
A timestamp for when the message was released in milliseconds.
Definition at line 410 of file isobus_speed_distance_messages.hpp.