Manual
RS-232C Communications 5-3
Exceptional Conditions
When the Automove System detects certain exceptional conditions, it immediately sends a
"?" (question mark) character to the host. These conditions are:
* Detecting invalid non-volatile memory contents at power up or RESET
* Entering the Emergency Stopped state
* Detecting motor slip via the optional Step Verify circuit
* Detecting any communications error (see
ESC.E)
* Detecting any ACL error (see OE)
When the host receives a "?" it can interrogate via the OS, OE,
ESC.E and ESC.O
commands to determine the cause. Remember that OS and OE do not execute immediately
if any ACL commands precede them in the input buffer.
In the case of erroneous ACL commands the "?" may be transmitted before the Automove
System has received all of the characters associated with the bad command; for example, if
the first of two parameters is out of range. Also, due to the Automove System's input buffer,
the host may have already sent several more commands by the time an erroneous command
causes a "?" to be sent.
The host software must be able to handle and respond to the unsolicited "?" character even
while the host is expecting data from some output request previously sent to the Automove
System. However, the "?" never occurs in the middle of the output sequence generated by a
given output request; it always comes between outputs. The "?" never causes an "output
conflict"; see the.
ESC E command in Chapter 6.
For example, assume that a series of OA commands are causing the Automove System to
repeatedly output 1234,5678 plus a Carriage Return and Linefeed; if the STOP button is
pushed, the "?" is always sent to the host between a Linefeed and the following "1"; never
within a given OA's output string. Thus if the host is putting the data into a string variable,
the string will contain ?1234,5678 instead of the expected 1234,5678.
The Input Buffer and Handshakes
As ACL commands are received they are placed in a 256-byte first-in/first-out input buffer.
Whenever the buffer contains any characters, the System extracts and processes them as fast
as possible, in the order they were received.
In order to prevent the buffer from overflowing, the host must implement one of four types
of handshake. These are: Hardwired DTR, Xon/Xoff, Enq/Ack, and Software Checking. At
power up the Automove System defaults to the Hardwired DTR handshake. To use a
different handshake, the host must send one or more escape sequences to the System. See
Appendix F Choosing a Handshake.