jmri.jmrix.zimo
Class Mx1CommandStation

java.lang.Object
  extended by jmri.jmrix.zimo.Mx1CommandStation
All Implemented Interfaces:
DccCommandStation

public class Mx1CommandStation
extends Object
implements DccCommandStation

Defines standard operations for Dcc command stations.

Author:
Bob Jacobsen Copyright (C) 2001

Constructor Summary
Mx1CommandStation()
           
 
Method Summary
 int bcdToAsc(int hex)
           
 boolean getHasServiceMode()
          Zimo does use a service mode
 boolean getInServiceMode()
          If this command station has a service mode, is the command station currently in that mode?
 Mx1Message getReadPagedCVMsg(int cv)
           
 Mx1Message getTurnoutCommandMsg(int pNumber, boolean pClose, boolean pThrow, boolean pOn)
          Generate a message to change turnout state
 int getTurnoutMsgAddr(Mx1Message pMsg)
          If this is a turnout-type message, return address.
 String getVersionString()
          Provides the version string returned during the initial check.
 Mx1Message getWritePagedCVMsg(int cv, int val)
           
 boolean isTurnoutCommand(Mx1Message pMsg)
          Is this a command to change turnout state?
 Mx1Message resetModeMsg()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Mx1CommandStation

public Mx1CommandStation()
Method Detail

getHasServiceMode

public boolean getHasServiceMode()
Zimo does use a service mode

Specified by:
getHasServiceMode in interface DccCommandStation

getInServiceMode

public boolean getInServiceMode()
If this command station has a service mode, is the command station currently in that mode?

Specified by:
getInServiceMode in interface DccCommandStation

getVersionString

public String getVersionString()
Provides the version string returned during the initial check. This function is not yet implemented...

Specified by:
getVersionString in interface DccCommandStation

getTurnoutCommandMsg

public Mx1Message getTurnoutCommandMsg(int pNumber,
                                       boolean pClose,
                                       boolean pThrow,
                                       boolean pOn)
Generate a message to change turnout state


getTurnoutMsgAddr

public int getTurnoutMsgAddr(Mx1Message pMsg)
If this is a turnout-type message, return address. Otherwise return -1. Note we only identify the command now; the reponse to a request for status is not yet seen here.


isTurnoutCommand

public boolean isTurnoutCommand(Mx1Message pMsg)
Is this a command to change turnout state?


resetModeMsg

public Mx1Message resetModeMsg()

getReadPagedCVMsg

public Mx1Message getReadPagedCVMsg(int cv)

getWritePagedCVMsg

public Mx1Message getWritePagedCVMsg(int cv,
                                     int val)

bcdToAsc

public int bcdToAsc(int hex)


Copyright © 1997 - 2008 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: SourceForge_Logo