Specifications
CUSTOMATCOMMANDS
157 HSPA+ATCommandsReferenceGuide
ParametersandValues
<pin> GPIOpinnumber.Rangeisfrom1toavaluethatdependsonthehardware.
NewSocketmodemsupportGPIO0toGPIO3.
NewMTPCIE‐xsupportGPIO1toGPIO3.
<mode> <mode>‐Meaningdependson<dir>setting:
0 Nomeaningif<dir>=0‐INPUT
‐outputpinclearedto0(Low)if<dir>=1‐OUTPUT
‐nomeaningif<dir>=2‐ALTERNATEFUNCTION
‐nomeaningif<dir>=3–TRISTATEPULLDOWN
1 Nomeaningif<dir>=0‐INPUT
‐outputpinsetto1(High)if<dir>=1‐OUTPUT
‐nomeaningif<dir>=2‐ALTERNATEFUNCTION
‐nomeaningif<dir>=3–TRISTATEPULLDOWN
2 Reportsthereadvaluefromthein
putpinif<dir>=0‐INPUT
‐Reportsthereadvaluefromtheinputpinif<dir>=1‐OUTPUT
‐Reportsanomeaningvalueif<dir>=2‐ALTERNATEFUNCTION
‐Reportsanomeaningif<dir>=3–TRISTATEPULLDOWN
<dir> GPIOpindirection
0‐pindirectionisINPUT
1‐
pindirectionisOUTPUT
2‐pindirectionisALTERNATEFUNCTION.SeeNotessection.
3‐pinissettoPULLDOWN.SeeNotessection.
Notes
When<mode>=2(and<dir>isomitted)thecommandreportsthedirectionandvalueofpinGPIO<pin>inthe
format:
#GPIO:<dir>,<stat>
where:
<dir> CurrentdirectionsettingfortheGPIO<pin>.
<stat>
LogicvaluereadfrompinGPIO<pin>inthecasethepin<dir>issettoinput.
LogicvaluepresentinoutputofthepinGPIO<pin>inthecasethepin<dir>is
currentlysettooutput.
NomeaningvalueforthepinGPIO<pin>inth
ecasethepin<dir>issetto
alternatefunctionorTristatepulldown
"ALTERNATEFUNCTION"valueisvalidonlyforfollowingpins:
GPIO4‐alternatefunctionis“RFTransmissionControl”
GPIO5‐alternatefunctionis“RFTransmissionMonitor”
GPIO6‐alternatefunctionis"AlarmOu tput"(see+CALA)
GPIO7‐alternatefunctionis"BuzzerOutput"(see#SRP)
Whileusingthepinsinthealternatefunction,theGPIOread/writeaccesstothatpinisnotaccessibleAvoid
access.