beautypg.com

Ansi x3.28 protocol example, Ansi x3.28 – Watlow Series 988 Family User Manual

Page 23

background image

Sending Commands, Chapter 4

Data Communications with the Watlow Series 988 Family

4.5

ANSI X3.28

ANSI X3.28 Protocol Example

This example demonstrates communication between a master device and a remote
device at address 4. Your personal computer must generate the master’s messages.

Establish Communications Link

Master:

4

(Attempt to link with device 4.)

Remote:

4

(The link is established.)

End Communications Link

Master:

(End data link.)

Remote:

No response.

“=” Command Example

Master:

= A2LO 500 (Set A2LO prompt value to 500.)

Remote:

(This will be returned once the unit has completed the value change.

Note: The commands IN1, IN2 and CF may take up to 2 seconds to return this character.
Do not send another message until this character is received.)

“?” Command Example

Master:

? A2LO (Request the A2LO prompt value.)

Remote:

(This will be returned once the device has the response ready. Do

not send the until this character has been received.)

or
(The command was not understood. Re-send corrected message.)

Master:

(The host gives the device permission to respond.)

Remote:

500 (The device sends back the requested value. Do not

send a response until the has been received.)

Master:

(The host received the message correctly.)
or
(The host did not understand the response.Device will re-send it.)

Remote:

(The device returns control to the host. Do not send a new message

until this character has been received.)

For maximum communications speed:
• Do not use a typical delay to wait before looking for a response.
• Scan for returned characters until the correct response is received.
• Use a time out to end a session if a correct response is not received in three seconds.

Try again later.

• Protocols are not flexible. Outside of the framing only the defined

protocol characters are allowed. Some programming languages add to the end
of transmissions. This must be disabled.

• End the communications link and re-establish it with and only when

changing to a new device at a different address. The master can communicate
repeatedly with a specific device once the initial data link is established.