B&B Electronics ADAM-6066 - Manual User Manual

Page 171

Advertising
background image

161

Chapter 6

# is a delimiter character.
aa (range 00-FF) represents the 2-character hexadecimal
slave network address of the ADAM-6000 module.
(Always 01)
cc is used to indicate which channel(s) you want to set.
Writing to all channels (byte):
Both characters should be equal to zero.
Writing to a single channel (bit):
First character is 1.
Second character indicates channel number (00-01).
dd is the hexadecimal representation of the digital output
value(s).
Writing to all channels (byte)
The digital equivalent of these hexadecimal characters
represent the channels’ values.
Writing to a single channel (bit)
First character is always 0. The value of the second
character is either 0 or 1. (The DO value)

Response

>(cr) if the command was valid.
?aa(cr) if an invalid command has been issued.
There is no response if the module detects a syntax error or
communication error or if the address does not exist.
> delimiter indicating a valid command was received.
? delimiter indicating the command was invalid.
aa (range 00-FF) represents the 2-character hexadecimal
slave network address of a module that is responding.
(cr) is the terminating character, carriage return (0Dh)

Example command:

#011101(cr)

response: >(cr)
An output bit with value 1 is sent to digital output channel 1
of a module at address 01h.
DO channel 1 of the specific module is set to ON.
command: #010002(cr)
response: >(cr) An output byte with value 02 (10b) is sent
to the module at address 01h.
DO channels 1 is set to ON, and channel 0 is set to OFF.

Advertising