Rs-232 serial interface programming – LightSpeed Technologies CAT 860 User Manual

Page 18

Advertising
background image

34

35

1. Overview

2. Setup & Use

3. Optional

Accessories

4. T

roubleshooting

5. W

arranty

, Safety

& Specifications

1. Overview

2. Setup & Use

3. Optional

Accessories

4. T

roubleshooting

5. W

arranty

, Safety

& Specifications

13. RS-232 SERIAL INTERFACE
PROGRAMMING

CONT’D

General Format for Query Command Exchange:

In this example the external controller sends query command packet to CAT
860. CAT 860 repeats back the action command packet in response which also
includes one or two imbedded <Param> characters. The <Param> characters
which are added to the query command packets contain the values of the perti-
nent internal CAT 860 registers.

Controller: <STX><CMD><EOT>
CAT 860:

<STX><CMD><Param><Param><EOT>

General Format for Aborted Command Exchange (Both Basic and Advanced

Command Sets:

In this example the external controller sends either an action or query command
to CAT 860 and the command is either corrupted or unsupported. The <Param>
characters can be absent.

Controller: <STX><CMD><Param><EOT>
CAT 860:

<NACK>

Note: It is expected that each button press from the serial controller would use
only a single command/query packet. If a single button press must issue a string
of multiple command/query packets then each packet must be separated by at
least a 10ms delay, or alternately, a new packet must wait until the CAT 860 issues
a response packet/character before it can be sent.

Control Character Hex Value and Definition
STX

(0x02)

Start character of an action command packet.

EOT

(0x04)

End character of any command packet.

ACK

(0x06)

Only response character from the CAT 860
if action command (PING command only) is
properly received and accepted.

NACK

(0x15)

Only response character from the CAT 860 if
any command is corrupted or unsupported.
The CAT 860 should send a NACK if:

1. The CAT 860 can not recognize the start or

command characters.

2. The CAT 860 does not receive an end

character after receiving a total of twenty
characters after receiving valid start and
command characters.

3. The CAT 860 does not receive an end

character after waiting 50ms after receiving
valid start and command characters.

CMD

(find hex value
from Table 1)

This is the general symbol for the command
character derived from Table 1.

Param

(find hex value
from Table 1)

This is the general symbol for the parameter
character(s) associated with the command
character. They are derived form Table 1.

13. RS-232 SERIAL INTERFACE
PROGRAMMING

CONT’D

General Format for Action Command Exchange for Basic and Advanced

Command Set:

In this example, the serial controller sends an action command packet to the
CAT 860 and in response the CAT 860 repeats back the action command packet
the serial controller. The <Param> characters can be absent from the action
command packet, but all response packets will have one or two added <Param>
characters containing the values of the pertinent internal CAT 860 register.

Controller: <STX><CMD><Param><EOT>
CAT 860:

<STX><CMD><Param><EOT>

Advertising