User manual

13
Manual WM-IIRO-8
Command Functions
The following paragraphs give details of the command functions, describe what the commands
cause, and give examples. Please note that all commands have an acknowledgment response. You
must wait for a response from a command before another com mand is sent.
Read Digital Inputs
I Read 8 bits
Ixx Read bit number xx
These commands read the digital input bits from the pod. All byte or word wide responses are sent
most-significant nibble first.
Examples:
Read ALL 8 bits.
SEND: I
RECEIVE: FF[CR]
Read only bit 2
SEND: I02
RECEIVE: 1[CR]
Write Digital Outputs
Oxx W rite to all 8 digital output bits
Ox± Set bit x hi or low
Oxx± Set bit xx hi or low
Ox±xx Pulse bit x hi or low for time xx
Oxx±xx Pulse bit xx hi or low for time xx
bx±xx Identical to Ox±xx
bxx±xx Identical to Oxx±xx
These commands write outputs to digital bits. Any attempt to write to a bit configured as input will fail.
Writing to a byte or word wherein some bits are input and some are output will cause the output
latches to change to the new value, but the bits which are inputs will not output the value until/unless
they are placed in output mode.
Single bit commands will return an error (4) if an attempt is made to write to a bit configured as input.
Writing a one to a port asserts the pull-down. Writing a zero de-asserts the pull-down. Therefore,
if the factory installed +5V pull-up is installed, writing a one will cause zero volts to be at the
connector, and writing a zero will cause +5 volts to be asserted. If the factory installed pull-up has
been removed, the user supplied pull-up will be asserted.
Write a zero to bit 2 (set output to +5V or user pull-up)
SEND: O2-
or
SEND: O02-
RECEIVE: [CR]