beautypg.com

Rainbow Electronics GM862-QUAD-PY User Manual

Page 259

background image




AT Commands Reference Guide

80000ST10025a Rev. 5 - 09/07/08

Reproduction forbidden without Telit Communications S.p.A. written authorization - All Rights Reserved

page 259 of 434

#GPIO - General Purpose Input/Output Pin Control

SELINT 0 / 1

Example

AT#GPIO=3,0,1
OK

AT#GPIO=3,2
#GPIO: 1,0
OK

AT#GPIO=4,1,1
OK
AT#GPIO=5,0,0

OK
AT#GPIO=6,2
#GPIO: 0,1

OK


#GPIO - General Purpose Input/Output Pin Control

SELINT 2

AT#GPIO=[,
[,

]]

Execution command sets the value of the general purpose output pin
GPIO according to

and parameter.
Not all configuration for the three parameters are valid.

Parameters:
- GPIO pin number; supported range is from 1 to a value that

depends on the hardware.

- its meaning depends on

setting:
0 - no meaning if =0 - INPUT
- output pin cleared to 0 (Low) if =1 - OUTPUT
- no meaning if =2 - ALTERNATE FUNCTION
1 - no meaning if =0 - INPUT
- output pin set to 1 (High) if =1 - OUTPUT
- no meaning if =2 - ALTERNATE FUNCTION
2 - Reports the read value from the input pin if =0 - INPUT
- Reports the read value from the input pin if =1 - OUTPUT
- Reports a no meaning value if =2 - ALTERNATE FUNCTION
- GPIO pin direction
0 - pin direction is INPUT
1 - pin direction is OUTPUT
2 - pin direction is ALTERNATE FUNCTION (see Note).

Note: when =2 (and is omitted) the command reports the
direction and value of pin GPIO in the format:

#GPIO: ,

where:
- current direction setting for the GPIO

logic value read from pin GPIO in the case the pin

is set
to input;

logic value present in output of the pin GPIO in the case the