EG_GenLoc41e_1055_UG_003_UK
Page 42 / 71
Descriptions and non-contractual illustrations in this document are given as an indication only.
ERCOGENER reserves the right to make any modifications.
Dct_427_02
7.4 Inputs/Outputs functioning
The modem contains the EGM standard library (see the documents "EG_EGM_CL_xxx_yy" of
ERCOGENER); in this case, the modem GenLoc 41e provides 3 inputs (opto-coupled) and 1 output (open
collector) available for an external use.
These functions can be controlled by AT commands:
AT+GPIOSET
for a writing access to a GPIO with the GPIO used as an output,
AT+GPIOGET
for a reading access to the GPIO with the GPIO used as an input.
AT+GPIOSET=10
This command is used to control the output. By default, the output is cabled as an open
collector. To control it:
AT+GPIOSET=<n>,<x>
with:
<n>
= 10 : Only 1 output available on the GenLoc 41e (so n=10),
<x>
= 0 : Output OFF
1 : Output ON
Examples:
AT+GPIOGET
This command is used to read the inputs. By default the inputs 1 to 3 are opto-coupled. To
read them:
AT+GPIOGET=<n>
with:
<n>
= 7 : reading the input 1
8 : reading the input 2
9 : reading the input 3
Examples:
See table of § 8.2.4 Inputs/Output
Command
Response
Interpretation
AT+GPIOSET=10,1
OK
Output 1 OFF, transistor closed
AT+GPIOSET=10,0
OK
Output 1 goes to ON (transistor open )
Command
Response
Interpretation
AT+GPIOGET=7
+GPIOGET: 7= 1
OK
Input 1 read at 1, the input 1 is controlled
AT+GPIOGET=9
+GPIOGET: 9= 0
OK
Input 3 read a 0, the input 3 is not controlled