Package jmri.jmrit.z21server
Class Service40
java.lang.Object
jmri.jmrit.z21server.Service40
Handle X-BUS Protokoll (header type 0x40).
Only function to handle a loco throttle have been implemented.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]handleService(byte[] data, InetAddress clientAddress) Handle a X-Bus command.static voidSet a listener to be called on track power manager events.
-
Constructor Details
-
Service40
public Service40()
-
-
Method Details
-
setChangeListener
Set a listener to be called on track power manager events. The listener is called with the Z21 LAN_X_BC_TRACK_POWER_ON/OFF packet to be sent to the client. Note that throttle changes are handled in the AppClient class.- Parameters:
cl- - listener class
-
handleService
Handle a X-Bus command.- Parameters:
data- - the Z21 packet bytes without data length and header.clientAddress- - the sending client's InetAddress- Returns:
- a response packet to be sent to the client or null if nothing is to sent (yet).
-