public class DemoUsage extends DemoBase
icube.ezhdlc, Trial Version - 2.0.1
icube.xmlpdu, Version - 2.0.1
icube.wrapper, Version - 2.0.1
usage:
LibrariesDemo
this usage description.
LibrariesDemo [@filename] 1 xmlfile1 xmlfile2 ... xmlfile'n'
( hdcl serial | tcp/ip )
xml files are processed successively
the first xml file should have an 'association request'
so that the requests in the files that follow
receive correct answers.
LibrariesDemo [@filename] 2 xmlfile1 xmlfile2
( hdcl serial | tcp/ip )
the second xml file is processed endlessly
xmlfile1 should have an 'association request'
so that the requests in xmlfile2
receive correct answers.
LibrariesDemo [@filename] 3 xmlfile1 xmlfile2 ... xmlfile'n'
( wrapper tcp/ip )
xml files are processed successively
the first xml file should have an 'association request'
so that the requests in the files that follow
receive correct answers.
LibrariesDemo [@filename] 4 xmlfile1 xmlfile2
( wrapper tcp/ip )
the second xml file is processed endlessly
xmlfile1 should have an 'association request'
so that the requests in xmlfile2
receive correct answers.
LibrariesDemo [@filename] 5
find serial-io ports
an optional parameters definition file may be specified as first parameter;
if specified, it must start with an '@' i.e. @settings.txt
The format of the paremeters definition file follow the format of Java properties file.
The following examples is used to address an L&G meter.
# use '0x' prefix for hexadecimal value
# the demo provides connection to the device server
# in three different ways, so it's necessary to
# set TEST_KIND to one of
# HDLC_SERIAL for HDLC with a serial connection
# HDLC_TCP for HDLC with a TCP/IP connection
# WRAPPER for 'wrapper protocol data unit (WPDU) with a TCP/IP connection
#TEST_KIND = HDLC_SERIAL
#TEST_KIND = HDLC_TCP
TEST_KIND = WRAPPER
# --------------------------------------
# HDLC tests
# serial port
hdlc_COMport = COM1
#hdlc_COMport = /dev/ttyS0
hdlc_COMbaud = 9600
# TCP/IP
#hdlc_TCPhost = 192.168.1.2
hdlc_TCPhost = 127.0.0.1
hdlc_TCPport = 8000
# HDLC parameters
ClientMACAddress = 0x10
ServerAddressSize = 1
ServerUpperMACAddressValue = 1
ServerLowerMACAddressValue = 0
ResponseTimeout = 3000
DiscToNDMTimeout = 1000
# --------------------------------------
# WRAPPER test
#wrapper_TCPhost = 192.168.1.2
wrapper_TCPhost = 127.0.0.1
wrapper_TCPport = 2048
# WRAPPER parameters
wrapper_ClienAddress = 0x10
wrapper_ServerAddress = 1
Constructor and Description |
---|
DemoUsage() |
Modifier and Type | Method and Description |
---|---|
void |
displayUsage()
Displays demo usage.
|
void |
exeDemo(java.lang.String[] args,
java.lang.String filename)
Executes the demo.
|
public void displayUsage()
DemoBase
Extending classes should call
displayUsage
in class DemoBase
public void exeDemo(java.lang.String[] args, java.lang.String filename) throws java.lang.Exception
DemoBase
Here we simply display the libraries' versions
Extending classes should call super.exeDemo() to display the versions.