
55
2.0 Getting Started
2.10.10 Serial Port
2.10.10.1 closePort()
2.10.10.1.1 Description
Closes the serial port.
2.10.10.1.2 Arguments
None.
2.10.10.1.3 Returns
Nothing.
2.10.10.1.4 Constants
None.
2.10.10.1.5 Example
See the
openPort()
method.
2.10.10.2 getDTR()
2.10.10.2.1 Description
Gets the status of the DTR signal of the serial port. DTR is an output
signal.
2.10.10.2.2 Arguments
None.
2.10.10.2.3 Returns
A boolean which indicates the DTR signal status (
true
= high,
false
= low).
2.10.10.2.4 Constants
None.
2.10.10.2.5 Example
2.10.10.3 getRTS()
2.10.10.3.1 Description
Gets the status of the RTS signal of the serial port. RTS is an output
signal.
2.10.10.3.2 Arguments
None.
2.10.10.3.3 Returns
A boolean which indicates the RTS signal status (
true
= high,
false
=
low).
2.10.10.3.4 Constants
None.
2.10.10.3.5 Example
See the
getDTR()
method.
2.10.10.4 openPort()
2.10.10.4.1 Description
Opens the serial port.
openPort()
and
closePort()
can be used when you need to release
the serial port, start an application that uses the port for a while, and
then reopen the port.
2.10.10.4.2 Arguments
None.
2.10.10.4.3 Returns
A boolean indicating if the port could be opened. If the port is being
held open by another application a call to this method will return false.
2.10.10.4.4 Constants
None.
2.10.10.4.5 Example
Note:
This is only a code fragment.