Class CbusNodeParameterManager
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new CbusNodeCanListener -
Method Summary
Modifier and TypeMethodDescriptionprotected voidGet the Node TypeintGet Number of outstanding unknown Parameters to be fetched from a CbusNodeintgetParameter(int index) Get a Single Parameter valueGet the Parameter String in Hex Byte Formatint[]Get array of All parametersbooleanisFwEqualOrNewer(int major, int minor, int beta) Check if current node firmware is equal to or newer than provided version Note that CBUS firmware start with beta builds, followed by a release with the beta build set to 0, e.g.: major.minor Beta 1 major.minor Beta 2 ...voidvoidrequestParam(int param) Request a single Parameter from a Physical Nodeprotected voidSend a request for the next unknown parameter to the physical nodevoidsetParameter(int index, int newval) Set a Single Node Parameter.voidsetParameters(int[] newparams) Set Node Parameters.
-
Constructor Details
-
CbusNodeParameterManager
Create a new CbusNodeCanListener- Parameters:
node- The Node
-
-
Method Details
-
setParameters
Set Node Parameters.Para 0 Number of parameters
Para 1 The manufacturer ID
Para 2 Minor code version as an alphabetic character (ASCII)
Para 3 Manufacturer module identifier as a HEX numeric
Para 4 Number of supported events as a HEX numeric
Para 5 Number of Event Variables per event as a HEX numeric
Para 6 Number of supported Node Variables as a HEX numeric
Para 7 Major version
Para 8 Node flags
Para 9 Processor type
Para 10 Bus type
Para 11-14 load address, 4 bytes
Para 15-18 CPU manufacturer's id as read from the chip config space, 4 bytes
Para 19 CPU manufacturer code
Para 20 Beta revision (numeric), or 0 if release
- Parameters:
newparams- set the node parameters
-
setParameter
Set a Single Node Parameter. Parameter array should be initialised before calling. Notifies PropertyChangeListener "PARAMETER"- Parameters:
index- Parameter Index,newval- New Parameter Value, 0-255
-
getOutstandingParams
Get Number of outstanding unknown Parameters to be fetched from a CbusNode- Returns:
- Number of outstanding Parameters, else 8
-
getParameter
Get a Single Parameter valueeg. for param. array [3,1,2,3] index 2 returns 2
Para 0 Number of parameters
Para 1 The manufacturer ID
Para 2 Minor code version as an alphabetic character (ASCII)
Para 3 Manufacturer module identifier as a HEX numeric
Para 4 Number of supported events as a HEX numeric
Para 5 Number of Event Variables per event as a HEX numeric
Para 6 Number of supported Node Variables as a HEX numeric
Para 7 Major version
Para 8 Node flags
Para 9 Processor type
Para 10 Bus type
Para 11-14 load address, 4 bytes
Para 15-18 CPU manufacturer's id as read from the chip config space, 4 bytes
Para 19 CPU manufacturer code
Para 20 Beta revision (numeric), or 0 if release
- Parameters:
index- of which parameter, 0 gives the total parameters- Returns:
- Full Parameter value for a particular index, -1 if unknown
-
getParameters
Get array of All parameters- Returns:
- Full Parameter array, index 0 is total parameters
-
getParameterHexString
Get the Parameter String in Hex Byte Formateg. for param. array [3,1,2,3] returns "010203"
- Returns:
- Full Parameter String WITHOUT leading number of parameters
-
clearParameters
-
getNodeTypeString
Get the Node Type- Returns:
- eg. MERG Command Station CANCMD Firmware 4d Node 65534
-
requestEventTot
-
requestParam
Request a single Parameter from a Physical NodeWill not send the request if there are existing active timers. Starts Parameter timeout
- Parameters:
param- Parameter Index Number, Index 0 is total parameters
-
isFwEqualOrNewer
Check if current node firmware is equal to or newer than provided version Note that CBUS firmware start with beta builds, followed by a release with the beta build set to 0, e.g.: major.minor Beta 1 major.minor Beta 2 ... major.minor Beta x major.minor Beta 0- Parameters:
major- New FW major versionminor- New FW minor versionbeta- New FW beta build number- Returns:
- true if current node firmware is equal to or newer than provided version
-
sendRequestNextParam
Send a request for the next unknown parameter to the physical node
-