Package jmri.jmrix.can.cbus.node
Class CbusAllocateNodeNumber
java.lang.Object
jmri.jmrix.can.cbus.node.CbusAllocateNodeNumber
- All Implemented Interfaces:
EventListener,AbstractMRListener,CanListener
Listens for CBUS Nodes requesting a Node Number, and asks the user for one.
Incoming frames, the node number dialogue and the Set Node Number timeout
are all handled on the GUI thread, which owns the allocation state.
Once dispose() has been called, frames and timeouts that were
already queued for the GUI thread are ignored.
-
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptionvoiddispose()Stop listening and cancel any Set Node Number timeout.voidIf popup not open send a setup param request to try and catch nodes awaiting number allocation when an all node respond message is sent.voidCapture CBUS_RQNN, CBUS_PARAMS, CBUS_NNACK, CBUS_NAMEprotected voidsetTimeout(int newVal) Set the SNN timeout, for Testing purposesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface jmri.jmrix.can.CanListener
addTc, addTc, removeTc, removeTc
-
Constructor Details
-
CbusAllocateNodeNumber
-
-
Method Details
-
setTimeout
Set the SNN timeout, for Testing purposes- Parameters:
newVal- Timeout value in ms
-
message
If popup not open send a setup param request to try and catch nodes awaiting number allocation when an all node respond message is sent.- Specified by:
messagein interfaceCanListener- Parameters:
m- Outgoing CanMessage
-
reply
Capture CBUS_RQNN, CBUS_PARAMS, CBUS_NNACK, CBUS_NAME- Specified by:
replyin interfaceCanListener- Parameters:
m- incoming CanReply
-
dispose
Stop listening and cancel any Set Node Number timeout. Frames and timeouts already queued for the GUI thread are then ignored.
-