Description:
The DTMF board has 12 channels of GPIO. This command can assert a GPO in either of the two
states, HIGH Z or GND. It can also get the current state of the GPO's.
Upon board reset all 12 GPO's default to a HIGH Z state. Once asserted to GND the GPO's will
remain there until brought back to HIGH Z through command issue or board reset.
There are two variants of the get command. The first is a get all where only the command itself
is issued. The second takes the input source number as the argument to find the status of a
given input source GPO. The set command takes the input source number and the 'ON' or 'OFF'
argument.
Form:
Command Handler: DPID
GPOUTPUT|GPO|GP [CHANNEL] [ARGUMENT] [VALUE]
Argument List:
Terse Verbose Description
NONE ON Set the GPIO channel to the ON state assertion to GND.
NONE OFF Set the GPIO channel to the OFF state assertion to
HIGH Z.
Response:
MODIFY GPOUTPUT RESPONSE
Verbose- "OK\r\n" to acknowledge receipt of command, or
"ERROR- [Description]\r\n" if error, ending command
Terse- "0\r\n" to acknowledge receipt of command, or
"[NON-ZERO NUMERIC VALUE]\r\n" if error, ending command
"\r\n" concludes modify responses (empty line)
DISPLAY GPOUTPUT RESPONSE
Verbose- "OK\r\n" to acknowledge receipt of command, followed by
"[ARGUMENT] = [VALUE]\r\n", or
"ERROR- [Description]\r\n" if error, ending command
Terse- "0\r\n" to acknowledge receipt of command, followed by
"[TERSE NUMERIC VALUE]\r\n", or
"[NON-ZERO NUMERIC VALUE]\r\n" if error, ending command
"\r\n" concludes display responses (empty line)
Examples:
Verbose command to set DTMF port '8' to 'CLOSED' or 'GND':
*.DPID gpoutput 8 closed <enter>
Response is: OK\r\n
\r\n
Terse command to set DTMF port '8' to 'CLOSED' or 'GND':
*.DPID gp 8 closed <enter>
Response is: 0\r\n
\r\n
Verbose command to set DTMF port '3' to 'OPEN' or 'HIGH Z':
*.DPID gpoutput 3 open <enter>
Response is: OK\r\n
\r\n
Terse command to set DTMF port '8' to 'OPEN' or 'HIGH Z':
*.DPID gp 8 open <enter>
Response is: 0\r\n
\r\n
Verbose command to get DTMF port 7 status:
*.DPID gpoutput 7 <enter>
Response is: ?\r\n
\r\n
OK
Assinged Input = 7
Gpi State = OPEN
\r\n
Terse command to get DTMF port 7 status:
*.DPID gpoutput 7 <enter>
Response is: ?\r\n
\r\n
0
OPEN
\r\n
Verbose command to get all DTMF port's status:
*.DPID gpoutput <enter>
Response is: ?\r\n
\r\n
OK
Assinged Input = 1
Gpi State = OPEN
OK
Assinged Input = 2
Gpi State = OPEN
OK
Assinged Input = 3
Gpi State = OPEN
OK
Assinged Input = 4
Gpi State = OPEN
OK
Assinged Input = 5
Gpi State = OPEN
OK
Assinged Input = 6
Gpi State = OPEN
OK
Assinged Input = 7
Gpi State = OPEN
OK
Assinged Input = 8
Gpi State = OPEN
OK
Assinged Input = 9
Gpi State = OPEN
OK
Assinged Input = 10
Gpi State = OPEN
OK
Assinged Input = 11
Gpi State = OPEN
OK
Assinged Input = 12
Gpi State = OPEN
\r\n
Terse command to get all DTMF port's status:
*.DPID gp <enter>
Response is: ?\r\n
\r\n
0
1 OPEN
0
2 OPEN
0
3 OPEN
0
4 OPEN
0
5 OPEN
0
6 OPEN
0
7 OPEN
0
8 OPEN
0
9 OPEN
0
10 OPEN
0
11 OPEN
0
12 OPEN
\r\n
Notes:
status == 'CLOSED' == '1', status == 'OPEN' == '0'
'CLOSED' == GND
'OPEN' == HIGH Z
Default state upon boot is 'OPEN'
***Anytime the connector for GPIO on the DTMF board is connected to a path
* to ground, even through resistance, current will flow thus triggering
* a GPI condition. I am not sure what the minimum current flow needs to
* be to trigger a GPI though. Therefore when asserting a GPO to GND it
* will appear to be a GPI.***