Package jmri.jmrix.sprog
Class SprogSlot
java.lang.Object
jmri.jmrix.sprog.SprogSlot
Represent information for a DCC Command Station Queue entry where each entry
is a DCC packet to be transmitted to the rails.
A SlotListener can be registered to hear of changes in this slot. All changes in values will result in notification.
Updated by Andrew Crosland February 2012 to allow slots to hold 28 step speed packets
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()voideStop()voidf0to4packet(int address, boolean isLongAddress, boolean f0, boolean f0Momentary, boolean f1, boolean f1Momentary, boolean f2, boolean f2Momentary, boolean f3, boolean f3Momentary, boolean f4, boolean f4Momentary) voidf13to20packet(int address, boolean isLongAddress, boolean f13, boolean f13Momentary, boolean f14, boolean f14Momentary, boolean f15, boolean f15Momentary, boolean f16, boolean f16Momentary, boolean f17, boolean f17Momentary, boolean f18, boolean f18Momentary, boolean f19, boolean f19Momentary, boolean f20, boolean f20Momentary) voidf21to28packet(int address, boolean isLongAddress, boolean f21, boolean f21Momentary, boolean f22, boolean f22Momentary, boolean f23, boolean f23Momentary, boolean f24, boolean f24Momentary, boolean f25, boolean f25Momentary, boolean f26, boolean f26Momentary, boolean f27, boolean f27Momentary, boolean f28, boolean f28Momentary) voidf29to36packet(int address, boolean isLongAddress, boolean f29, boolean f29Momentary, boolean f30, boolean f30Momentary, boolean f31, boolean f31Momentary, boolean f32, boolean f32Momentary, boolean f33, boolean f33Momentary, boolean f34, boolean f34Momentary, boolean f35, boolean f35Momentary, boolean f36, boolean f36Momentary) voidf37to44packet(int address, boolean isLongAddress, boolean f37, boolean f37Momentary, boolean f38, boolean f38Momentary, boolean f39, boolean f39Momentary, boolean f40, boolean f40Momentary, boolean f41, boolean f41Momentary, boolean f42, boolean f42Momentary, boolean f43, boolean f43Momentary, boolean f44, boolean f44Momentary) voidf45to52packet(int address, boolean isLongAddress, boolean f45, boolean f45Momentary, boolean f46, boolean f46Momentary, boolean f47, boolean f47Momentary, boolean f48, boolean f48Momentary, boolean f49, boolean f49Momentary, boolean f50, boolean f50Momentary, boolean f51, boolean f51Momentary, boolean f52, boolean f52Momentary) voidf53to60packet(int address, boolean isLongAddress, boolean f53, boolean f53Momentary, boolean f54, boolean f54Momentary, boolean f55, boolean f55Momentary, boolean f56, boolean f56Momentary, boolean f57, boolean f57Momentary, boolean f58, boolean f58Momentary, boolean f59, boolean f59Momentary, boolean f60, boolean f60Momentary) voidf5to8packet(int address, boolean isLongAddress, boolean f5, boolean f5Momentary, boolean f6, boolean f6Momentary, boolean f7, boolean f7Momentary, boolean f8, boolean f8Momentary) voidf61to68packet(int address, boolean isLongAddress, boolean f61, boolean f61Momentary, boolean f62, boolean f62Momentary, boolean f63, boolean f63Momentary, boolean f64, boolean f64Momentary, boolean f65, boolean f65Momentary, boolean f66, boolean f66Momentary, boolean f67, boolean f67Momentary, boolean f68, boolean f68Momentary) voidf9to12packet(int address, boolean isLongAddress, boolean f9, boolean f9Momentary, boolean f10, boolean f10Momentary, boolean f11, boolean f11Momentary, boolean f12, boolean f12Momentary) intgetAddr()booleanlongbyte[]Get the payload of this slot.intintbooleanisActiveAddressMatch(DccLocoAddress address) booleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanisFree()booleanbooleanisOpsPkt()booleanintlocoAddr()voidset(int address, byte[] payload, int repeat) Set the contents of the slot.voidsetAccessoryPacket(int address, boolean closed, int repeats) voidsetAddr(int a) voidsetIsLong(boolean a) voidsetOps(int address, boolean longAddr, int cv, int val) voidsetRepeat(int r) voidsetSpeed(SpeedStepMode mode, int address, boolean isLongAddress, int speed, boolean forward) intintspeed()
-
Constructor Details
-
SprogSlot
-
-
Method Details
-
isF0to4Packet
-
isF5to8Packet
-
isF9to12Packet
-
isF13to20Packet
-
isF21to28Packet
-
isF29to36Packet
-
isF37to44Packet
-
isF45to52Packet
-
isF53to60Packet
-
isF61to68Packet
-
set
Set the contents of the slot. Intended for accessory packets.- Parameters:
address- intpayload- byte[]repeat- int
-
setAccessoryPacket
-
isSpeedPacket
-
setSpeed
public void setSpeed(SpeedStepMode mode, int address, boolean isLongAddress, int speed, boolean forward) -
setOps
-
f5to8packet
public void f5to8packet(int address, boolean isLongAddress, boolean f5, boolean f5Momentary, boolean f6, boolean f6Momentary, boolean f7, boolean f7Momentary, boolean f8, boolean f8Momentary) -
f9to12packet
public void f9to12packet(int address, boolean isLongAddress, boolean f9, boolean f9Momentary, boolean f10, boolean f10Momentary, boolean f11, boolean f11Momentary, boolean f12, boolean f12Momentary) -
f13to20packet
public void f13to20packet(int address, boolean isLongAddress, boolean f13, boolean f13Momentary, boolean f14, boolean f14Momentary, boolean f15, boolean f15Momentary, boolean f16, boolean f16Momentary, boolean f17, boolean f17Momentary, boolean f18, boolean f18Momentary, boolean f19, boolean f19Momentary, boolean f20, boolean f20Momentary) -
f21to28packet
public void f21to28packet(int address, boolean isLongAddress, boolean f21, boolean f21Momentary, boolean f22, boolean f22Momentary, boolean f23, boolean f23Momentary, boolean f24, boolean f24Momentary, boolean f25, boolean f25Momentary, boolean f26, boolean f26Momentary, boolean f27, boolean f27Momentary, boolean f28, boolean f28Momentary) -
f29to36packet
public void f29to36packet(int address, boolean isLongAddress, boolean f29, boolean f29Momentary, boolean f30, boolean f30Momentary, boolean f31, boolean f31Momentary, boolean f32, boolean f32Momentary, boolean f33, boolean f33Momentary, boolean f34, boolean f34Momentary, boolean f35, boolean f35Momentary, boolean f36, boolean f36Momentary) -
f37to44packet
public void f37to44packet(int address, boolean isLongAddress, boolean f37, boolean f37Momentary, boolean f38, boolean f38Momentary, boolean f39, boolean f39Momentary, boolean f40, boolean f40Momentary, boolean f41, boolean f41Momentary, boolean f42, boolean f42Momentary, boolean f43, boolean f43Momentary, boolean f44, boolean f44Momentary) -
f45to52packet
public void f45to52packet(int address, boolean isLongAddress, boolean f45, boolean f45Momentary, boolean f46, boolean f46Momentary, boolean f47, boolean f47Momentary, boolean f48, boolean f48Momentary, boolean f49, boolean f49Momentary, boolean f50, boolean f50Momentary, boolean f51, boolean f51Momentary, boolean f52, boolean f52Momentary) -
f53to60packet
public void f53to60packet(int address, boolean isLongAddress, boolean f53, boolean f53Momentary, boolean f54, boolean f54Momentary, boolean f55, boolean f55Momentary, boolean f56, boolean f56Momentary, boolean f57, boolean f57Momentary, boolean f58, boolean f58Momentary, boolean f59, boolean f59Momentary, boolean f60, boolean f60Momentary) -
f61to68packet
public void f61to68packet(int address, boolean isLongAddress, boolean f61, boolean f61Momentary, boolean f62, boolean f62Momentary, boolean f63, boolean f63Momentary, boolean f64, boolean f64Momentary, boolean f65, boolean f65Momentary, boolean f66, boolean f66Momentary, boolean f67, boolean f67Momentary, boolean f68, boolean f68Momentary) -
f0to4packet
public void f0to4packet(int address, boolean isLongAddress, boolean f0, boolean f0Momentary, boolean f1, boolean f1Momentary, boolean f2, boolean f2Momentary, boolean f3, boolean f3Momentary, boolean f4, boolean f4Momentary) -
isFinished
-
eStop
-
clear
-
isLongAddress
-
isFree
-
slotStatus
-
getRepeat
-
setRepeat
-
speed
-
locoAddr
-
getAddr
-
setAddr
-
getIsLong
-
setIsLong
-
isForward
-
isOpsPkt
-
isActiveAddressMatch
-
getPayload
Get the payload of this slot. Note - if this slot has a number of repeats, calling this method will also decrement the internal repeat counter.- Returns:
- a byte array containing the payload of this slot
-
getSlotNumber
-
getLastUpdateTime
-