
13
Man ual W M-IIRO -8
Command Functions
The following paragraphs give details of the command functions, describe what the comm ands
cause, and give examples. Please note that all comm ands have an acknowledgment response. You
m ust w ait for a resp ons e from a co m m and befo re an othe r com m and is sen t.
Read Digital Inputs
I
Re ad 8 bits
Ixx
Read bit number xx
These comm ands read the digital input bits from the pod. All byte or word wide responses are sent
m ost-s ignifica nt nibb le first.
Exam ples:
Re ad A LL 8 bits.
SEND:
I
RECEIVE:
FF[CR]
Re ad o nly bit 2
SEND:
I02
RECEIVE:
1[CR]
Write Digital Outputs
Oxx
W rite to all 8 dig ital outpu t 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 comm ands write outputs to digital bits. Any attempt to write to a bit configured as input will fa il.
W riting 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.
Sin gle bit comm ands will return an error (4) if an attempt is made to write to a bit con figure d as input.
W riting a one to a port asserts the pull-down. W riting a zero de-asserts the pull-down. Therefore,
if the fac tory ins5V pull-up is installed, writing a one will cause zero volts to be at the
conne ctor, 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.
W rite a zero to bit 2 (set output to +5V or user pull-up)
SEND:
O2-
or
SE ND :
O02-
RECEIVE:
[CR]