jmri
Class PushbuttonPacket
java.lang.Object
jmri.PushbuttonPacket
public class PushbuttonPacket
- extends Object
Generates an NMRA packet containing the correct payload to enable or
disable pushbutton lockout. Currently supports the following Decoders
NCE
CVP AD4
NCE is the easliest to implement, CV556 = 0 disable lockout, CV556 = 1 enable lockout
CVP is a bit tricker, CV514 controls the lockout for four turnouts. Each turnout
can have one or two button controls. Therefore the user must specify if they are
using one or two buttons for each turnout.
From the CVP user manual:
Function CV514
Lock all inputs 0
Unlock 1 1
Unlock 2 4
Unlock 3 16
Unlock 4 64
Unlock all 85
Enable 2 button 255
This routine assumes that for two button operations the following table is true:
Lock all inputs 0
Unlock 1 3
Unlock 2 12
Unlock 3 48
Unlock 4 192
Unlock all 255
Each CVP can operate up to four turnouts, luckly for us, they are sequential.
Also note that CVP decoder's use the old legacy format for ops mode programming.
- Author:
- Daniel Boudreau Copyright (C) 2007
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
unknown
public static final String unknown
- Valid stationary decoder names
- See Also:
- Constant Field Values
NCEname
public static final String NCEname
- See Also:
- Constant Field Values
CVP_1Bname
public static final String CVP_1Bname
- See Also:
- Constant Field Values
CVP_2Bname
public static final String CVP_2Bname
- See Also:
- Constant Field Values
PushbuttonPacket
public PushbuttonPacket()
pushbuttonPkt
public static byte[] pushbuttonPkt(String prefix,
int turnoutNum,
boolean locked)
getValidDecoderNames
public static String[] getValidDecoderNames()
Copyright © 1997 - 2011 JMRI Community.
JMRI, DecoderPro, PanelPro, SoundPro, DispatcherPro and associated logos are our trademarks.
Additional information on copyright, trademarks and licenses is linked here.
Site hosted by: