Page: 42/81 User Manual PSU-CTRL-2D, Rev.1-00: Software Interface
commands, Boolean parameters are used. They use the uppercase
characters 'Y' for true and 'N' for false. An ASCII character string is
transferred as is but without the null-termination. Instead, the termina-
tion character of the command indicates the end of the string.
If a transmitted command is misspelled or unknown or if it contains in-
valid parameters, the device will not process it. The command and its
data are cleared from the input buffer and the device does not provide
any response. This implies that the communication control should
specify a certain timeout and if no response is received within this
timeout, the command has to be considered erroneous. The timeout
depends on the interface latency; with USB, the recommended value
is 100 ms. With the RS-232 interface, significantly shorter timeouts
can be used. However, the proper timeout value may also be influ-
enced by the operating system of the host and the serial-port hard-
ware. Thus, it should be determined experimentally. If the error detec-
tion is not time-critical in the application in question, the value recom-
mended for the USB interface (i.e. 100 ms) can also be used for the
RS-232 interface.
If the device does not respond or if the response is invalid, use the
handshake lines of the serial port to clear the input device buffer
(see section "Functionality of the Software Interface" and function
) before reattempting the operation. The clear-
ing procedure should start with deasserting the lines DTR and/or RTS
and waiting for an inactive signal CTS which indicates that the device
is not ready and that it has recognized the clear command. Then, the
abovementioned handshake lines should be reasserted and the de-
vice should respond with activating the signal CTS to indicate that it is
ready to receive further commands. Please ensure that the software
controlling the communication does not start to send any data to the
device while the signal CTS is still inactive, i.e. when the device is not
yet ready. The device would either not receive the data at all or the
first characters of the sent sequence may be lost.
If you use a communication speed different from the default value of
9600 baud, be sure to deassert the lines DTR and/or RTS for a short
time only. It is recommended to assert the handshake lines immedi-
ately after the device has responded with an inactive signal CTS. If
the handshake lines were deasserted for a longer time period (see
section "Functionality of the Software Interface"), the communication
speed would be set to the default value and it would need to be ad-
justed again by the function
.
CGC Instruments
Tel.: +49 (371) 355 098–55
Hübschmannstr. 18 | D–09112 Chemnitz
Fax: +49 (371) 355 098–60
internet: www.cgc-instruments.com
e–mail: [email protected]