|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.eurotech.framework.protocol.pcn.Pcn1001MasterConfig
public class Pcn1001MasterConfig
Defines PCN-1001 Master configuration class.
Constructor Summary | |
---|---|
Pcn1001MasterConfig()
Pcn1001MasterConfig default constructor. |
|
Pcn1001MasterConfig(int[] pcn1001SnpAddresses,
int commBaudRate,
int commDataBits,
int commStopBits,
int commParity,
int commSerialMode,
boolean initialCountReset,
boolean initialCountEnable,
boolean initialSetDateTime)
Pcn1001MasterConfig constructor |
|
Pcn1001MasterConfig(String serialDeviceVendorID,
String serialDeviceProductID,
int[] pcn1001SnpAddresses,
int commBaudRate,
int commDataBits,
int commStopBits,
int commParity,
int commSerialMode,
boolean initialCountReset,
boolean initialCountEnable,
boolean initialSetDateTime)
Pcn1001MasterConfig constructor |
Method Summary | |
---|---|
int |
getCommBaudRate()
Reports baud rate. |
int |
getCommDataBits()
Reports number of data bits. |
int |
getCommParity()
Reports parity. |
int |
getCommSerialMode()
Reports serial mode (type of flow control). |
int |
getCommStopBits()
Reports number of stop bits. |
Hashtable |
getHtPcn1001Config()
|
int |
getInOutPollRateFast()
Reports fast IN/OUT poll rate. |
int |
getInOutPollRateSlow()
Reports slow IN/OUT poll rate. |
int |
getInput0Function()
Reports input0 function. |
int |
getInput1Function()
Reports input1 function. |
int |
getNumCommRetries()
Reports number of communication retries. |
int |
getOutput0OpenTime()
Reports output0 open time in milliseconds. |
int |
getOutput1OpenTime()
Reports output1 open time in milliseconds. |
int[] |
getPcn1001SnpAddresses()
Reports an array of SNP addresses of the passenger counters attached. |
String |
getSerialDeviceProductID()
Reports serial device product ID |
String |
getSerialDeviceVendorID()
Reports serial device vendor ID |
String |
getSerialPortName()
Reports serial port name. |
boolean |
isInitialCountEnable()
Reports if counting needs to be enabled on startup. |
boolean |
isInitialCountReset()
Reports if IN/OUT counters need to be reset on startup. |
boolean |
isInitialDiagnosticsEnable()
Reports if diagnostics need to be enabled on startup. |
boolean |
isInitialSetDateTime()
Reports if system date and time needs to be set at startup. |
boolean |
isLedPropsEnabled()
Reports if led-related properties are enabled. |
boolean |
isUseAutoLed()
Reports if 'autoled' functionality is enabled. |
boolean |
isVerifyFunctionality()
Reports if PCN-1001 functionality needs to be verified with SNP poll. |
boolean |
isVerifyReset()
Reports if IN/OUT count reset needs to be verified with 'gcounters' command. |
void |
setCommBaudRate(int commBaudRate)
Sets baud rate. |
void |
setCommDataBits(int commDataBits)
Sets number of data bits. |
void |
setCommParity(int commParity)
Sets parity. |
void |
setCommSerialMode(int commSerialMode)
Sets serial mode (type of flow control) |
void |
setCommStopBits(int commStopBits)
Sets number of stop bits. |
void |
setHtPcn1001Config(Hashtable htPcn1001Config)
|
void |
setInitialCountEnable(boolean initialCountEnable)
Sets the InitialCountEnable flag. |
void |
setInitialCountReset(boolean initialCountReset)
Sets InitialCountReset flag |
void |
setInitialDiagnosticsEnable(boolean initialDiagnosticsEnable)
Sets the InitialDiagnosticsEnable flag. |
void |
setInitialSetDateTime(boolean initialSetDateTime)
Sets the initialSetDateTime flag. |
void |
setInOutPollRateFast(int inOutPollRateFast)
Sets fast IN/OUT poll rate. |
void |
setInOutPollRateSlow(int inOutPollRateSlow)
Sets slow IN/OUT poll rate. |
void |
setInput0Function(int input0Function)
Sets input0 function. |
void |
setInput1Function(int input1Function)
Sets input1 function. |
void |
setLedPropsEnable(boolean ledPropsEnable)
Sets the value of led-related properties flag. |
void |
setNumCommRetries(int numCommRetries)
Sets number of communication retries. |
void |
setOutput0OpenTime(int output0OpenTime)
Sets output0 open time. |
void |
setOutput1OpenTime(int output1OpenTime)
Sets output1 open time. |
void |
setPcn1001SnpAddresses(int[] pcn1001SnpAddresses)
Sets an array of SNP addresses of the passenger |
void |
setSerialDeviceProductID(String serialDeviceProductID)
Sets serial device product ID |
void |
setSerialDeviceVendorID(String serialDeviceVendorID)
Sets serial device vendor ID |
void |
setSerialPortName(String serialPortName)
Set the serial port name. |
void |
setUseAutoLed(boolean useAutoLed)
Sets the value of 'autoled' flag. |
void |
setVerifyFunctionality(boolean verifyFunctionality)
Set the 'verify functionality' flag. |
void |
setVerifyReset(boolean verifyReset)
Sets 'verify reset' flag. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int DFLT_SNP_POLL_TOUT
public static final int DFLT_SNP_CMD_TOUT
public static final int DFLT_NUM_RETRIES
public static final boolean DFLT_INIT_COUNT_RESET
public static final boolean DFLT_INIT_COUNT_ENABLE
public static final boolean DFLT_INIT_DIAGNOSTICS_ENABLE
public static final boolean DFLT_INIT_SET_DATETIME
public static final int DFLT_SNP_MASTER_ADDR
public static final int DFLT_SNP_SLAVE_ADDR
public static final boolean DFLT_LED_PROPS_ENABLE
public static final boolean DFLT_USE_AUTOLED
public static final int DFLT_LED_INTENSITY
public static final String DFLT_IP_ADDRESS
public static final String DFLT_VENDOR_ID
public static final String DFLT_PRODUCT_ID
public static final String INVALID_VENDOR_ID
public static final String INVALID_PRODUCT_ID
public static final int DFLT_NUM_COMM_RETRIES
public static final int DFLT_BAUD_RATE
public static final int DFLT_DATA_BITS
public static final int DFLT_STOP_BITS
public static final int DFLT_PARITY
public static final int DFLT_SERIAL_MODE
public static final int DFLT_INOUT_POLL_RATE_FAST
public static final int DFLT_INOUT_POLL_RATE_SLOW
public static final int DFLT_INPUT0_FUNCTION
public static final int DFLT_INPUT1_FUNCTION
public static final int DFLT_OUTPUT0_OPEN_TIME
public static final int DFLT_OUTPUT1_OPEN_TIME
public static final boolean DFLT_VERIFY_FUNCTIONALITY
public static final boolean DFLT_VERIFY_RESET
Constructor Detail |
---|
public Pcn1001MasterConfig()
public Pcn1001MasterConfig(int[] pcn1001SnpAddresses, int commBaudRate, int commDataBits, int commStopBits, int commParity, int commSerialMode, boolean initialCountReset, boolean initialCountEnable, boolean initialSetDateTime)
pcn1001SnpAddresses
- - SNP addresses of passenger couters attached as int[]
commBaudRate
- - baud rate as int
commDataBits
- - number of data bits as int
commStopBits
- - number of stop bits as int
commParity
- - parity as int
commSerialMode
- - mode (type of flow control) as int
initialCountReset
- - reset IN/OUT counters at startup as boolean
initialCountEnable
- - enable counting software at startup as boolean
initialSetDateTime
- - set system date and time at startup as boolean
public Pcn1001MasterConfig(String serialDeviceVendorID, String serialDeviceProductID, int[] pcn1001SnpAddresses, int commBaudRate, int commDataBits, int commStopBits, int commParity, int commSerialMode, boolean initialCountReset, boolean initialCountEnable, boolean initialSetDateTime)
serialDeviceVendorId
- - serial device vendor ID as String
serialDeviceProductId
- - serial device product ID as String
pcn1001SnpAddresses
- - SNP addresses of passenger couters attached as int[]
commBaudRate
- - baud rate as int
commDataBits
- - number of data bits as int
commStopBits
- - number of stop bits as int
commParity
- - parity as int
commSerialMode
- - mode (type of flow control) as int
initialCountReset
- - reset IN/OUT counters at startup as boolean
initialCountEnable
- - enable counting software at startup as boolean
initialSetDateTime
- - set system date and time at startup as boolean
Method Detail |
---|
public String getSerialDeviceVendorID()
String
public void setSerialDeviceVendorID(String serialDeviceVendorID)
serialDeviceVendorID
- as String
public String getSerialDeviceProductID()
String
public void setSerialDeviceProductID(String serialDeviceProductID)
serialDeviceProductID
- - product ID as String
public int getNumCommRetries()
int
public void setNumCommRetries(int numCommRetries)
numCommRetries
- - number of communication retries as int
public int[] getPcn1001SnpAddresses()
int[]
public void setPcn1001SnpAddresses(int[] pcn1001SnpAddresses)
pcn1001SnpAddresses
- - SNP addresses as int[]
public boolean isLedPropsEnabled()
boolean
public void setLedPropsEnable(boolean ledPropsEnable)
ledPropsEnable
- - of led-related properties flag as boolean
public boolean isUseAutoLed()
boolean
public void setUseAutoLed(boolean useAutoLed)
useAutoLed
- - value of 'autoled' flag as boolean
public Hashtable getHtPcn1001Config()
public void setHtPcn1001Config(Hashtable htPcn1001Config)
htPcn1001Config
- public String getSerialPortName()
String
public void setSerialPortName(String serialPortName)
serialPortName
- - serial port name as String
.
The name is OS dependent (e.g. "COM1" under Windows, "/dev/ttyS0" under Linux).public int getCommBaudRate()
int
public void setCommBaudRate(int commBaudRate)
commBaudRate
- - baud rate as int
public int getCommDataBits()
int
public void setCommDataBits(int commDataBits)
commDataBits
- - number of data bits as int
public int getCommStopBits()
int
public void setCommStopBits(int commStopBits)
commStopBits
- - number of stop bits as int
public int getCommParity()
int
public void setCommParity(int commParity)
commParity
- - parity as int
public int getCommSerialMode()
int
public void setCommSerialMode(int commSerialMode)
commSerialMode
- - serial mode as int
public int getInOutPollRateFast()
int
public void setInOutPollRateFast(int inOutPollRateFast)
inOutPollRateFast
- - fast IN/OUT poll rate in msec as int
public int getInOutPollRateSlow()
int
public void setInOutPollRateSlow(int inOutPollRateSlow)
inOutPollRateSlow
- - slow IN/OUT poll rate in msec as int
public boolean isInitialCountReset()
boolean
public void setInitialCountReset(boolean initialCountReset)
initialCountReset
- - StartupCountReset flag as boolean
public boolean isInitialCountEnable()
boolean
public void setInitialCountEnable(boolean initialCountEnable)
initialCountEnable
- - InitialCountEnable flag as boolean
public boolean isInitialDiagnosticsEnable()
boolean
public void setInitialDiagnosticsEnable(boolean initialDiagnosticsEnable)
initialDiagnosticsEnable
- - InitialDiagnosticsEnable flag as boolean
public boolean isInitialSetDateTime()
boolean
public void setInitialSetDateTime(boolean initialSetDateTime)
initialSetDateTime
- - 'set date and time' flag as boolean
public int getInput0Function()
int
public void setInput0Function(int input0Function)
input0Function
- - input0 function as int
public int getInput1Function()
int
public void setInput1Function(int input1Function)
input1Function
- - input1 function as int
public int getOutput0OpenTime()
int
public void setOutput0OpenTime(int output0OpenTime)
output0OpenTime
- - output0 open time as int
public int getOutput1OpenTime()
int
public void setOutput1OpenTime(int output1OpenTime)
output1OpenTime
- - output1 open time as int
public boolean isVerifyFunctionality()
boolean
public void setVerifyFunctionality(boolean verifyFunctionality)
verifyFunctionality
- - 'verify functionality' flag as boolean
public boolean isVerifyReset()
boolean
public void setVerifyReset(boolean verifyReset)
verifyReset
- - 'verify reset' flag as boolean
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |