BO  set DIO port A, B direction 
 
 IMM PGM MIP 
USAGE      ♦    ♦     ♦ 
 
SYNTAX   BOnn  or  BO? 
 
PARAMETERS 
Description  nn  [ int ]  -    hardware limit configuration 
 
Range    nn  -  0 to 03H (hexadecimal with leading zero(0)) on 
ESP100 and ESP300 
    or ? to read current setting 
 
Units    nn -  None 
 
Defaults   nn missing:   error 38, COMMAND PARAMETER MISSING 
           out of range:  error 7, PARAMETER OUT OF RANGE 
 
DESCRIPTION  This command is used to set digital I/O (DIO) port A, B, and C direction where 
bit-0 corresponds to port A, bit-1 to port B, and bit-2 to port C. If any bit is set to 
zero(0) then its corresponding port will become an input only. If any bit is set to 
one(1) then its corresponding port will becomes an output only.  Ports A and B 
only are available on the ESP100 and ESP300. 
 
A DIO within a port configured as an input can only report its present HIGH or 
LOW logic level. Whereas a DIO bit within a port configured as an output can 
set(1) or clear(0) the corresponding DIO hardware to HIGH or LOW logic level. 
Reading the status of a port configured as output returns its present output status. 
 
Note: 
All direction bits are automatically zeroed, or cleared, after a system reset. 
Therefore all DIO ports default to input by default. 
 
Note: 
Each DIO bit has a pulled-up resistor to +5V. Therefore, all bits will be at HIGH 
logic level if not connected to external circuit and configured as input. 
 
BIT# VALUE DEFINITION 
*0  0  port A (DIO bit-0 through bit-7) assigned as input 
0  1  port A (DIO bit-0 through bit-7) assigned as output 
*1  0  port B (DIO bit-8 through bit-15) assigned as input 
1  1  port B (DIO bit-8 through bit-15) assigned as output 
 
* default setting after system reset 
 
 
RETURNS   If the “?” sign takes the place of nn value, this command reports the current 
setting in hexadecimal notation. 
 
3-36          Section 3 – Remote Mode