User Manual

111
GPIO
Description:
Configures digital I/Opins level to high (1) 5V or low
(0) 0V for output pins. Nothing happens if the pin is
an input.
Syntax:
GPIO<SP><decimal>
<decimal> - Decimal representation of the binary
value representing the GPIO pins. 0 – 255 are valid.
Example:
GPIO 46
Sets pins 7, 4, 3, and 2 to logic high(1) 5 V output if
these pins are configured as output pins using
GPIO:DIRection command (See “Table 9” to convert
the binary representation). Refer to section
3.13Digital I/O” for more details.
GPIO?
Description:
Queries the voltage levels 1 (5 V) or 0 (0 V) of digital
I/O input pins. Output pins return 0.
Query:
GPIO?
Return String:
130
Pins 9 and 2 have 5 V input if these pins are
configured as input pins using GPIO:DIRection
command (See “Table 9” to convert the binary
representation). Refer to section “3.13Digital I/O” for
more details.
Format:
<NR1>
GPIO:DIRection
Description:
Configures the digital I/O pins as inputs or outputs.
Syntax:
GPIO<SP><decimal>
<decimal> - Decimal representation of the binary
value representing the GPIO pins. 0 255 are valid.
Binary value of 1 is output and 0 is input.
Example:
GPIO:DIR 82
Sets pins 8, 6, and 2 as outputs and the rest as
inputs (See “Table 9” to convert the binary
representation). Refer to section “3.13Digital I/O” for
more details.