-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Decodes traction request and reply messages for the monitor window (#195
) This PR adds toString() methods to the TractionControlRequest and TractionControlReply messages. These tostring methods are used by the OpenLCB/LCC monitor log in JMRI. The decoding interprets the message command, subcommand and renders the arguments in text form. Adds unit tests for untested parts of the traction messages, including creators and accessors. Adds a few missing details from the TractionWM to the traction request/reply classes. Misc supporting changes: - Fixes bugs in the Utilities.NetworkToHostUintXX methods. - Adds 24-bit Utilities.NetworkToHostUintXX method. - Adds a constructor to NodeID that takes a long argument. - Fixes missing rounding in the Float16 constructor (it was truncating to zero instead of rounding). - Adds isPositive to Float16 class. === * Adds isPositive to Float16. Fixes a rounding problem in the LSB when conmvertingvalue from double. * Fixes array index out of bounds exceptions in Utilities. Adds support for UInt24 parsing and rendering. * Starts adding toString() method for TractionControlRequest. Adds unit tests for set/get speed, function and estop commands. * Adds a constructor to NodeID to create it from a long containind 48 bits of data. * Adds printouts and tests for controller change messages. * Adds tostring and tests for listener and management messages. * Adds tostring to traction reply message. Adds unit tests for traction reply class. * Implements generating an ESTOP message by sending a nan float value to the speed versionedvalue.
- Loading branch information
1 parent
84e7990
commit 3e2078f
Showing
11 changed files
with
792 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.