Digital I/O support
AO (API Output Options) determines the I/O lines available for sampling. By default, AO is configured to be compatible with legacy devices.
- Configure AO to 0 or 1 to make digital I/O available on lines DIO0 through DIO14 (D0 - D9 and P0 - P4).
- Configure AO to 2 to make digital I/O available on lines DIO0 through DIO8 (D0 - D8). This provides compatibility with S1 and S2C devices and is the default configuration.
See Legacy support for more information.
Digital sampling is enabled on these pins if configured as 3, 4, or 5 with the following meanings:
-
3 is digital input.
-
Use PR (Pull-up/Down Resistor Enable) to enable internal pull up/down resistors for each digital input. Use PD (Pull Up/Down Direction) to determine the direction of the internal pull up/down resistor. All disabled and digital input pins are pulled up by default.
-
- 4 is digital output low.
- 5 is digital output high.
Function when AO = 0 or 1 |
Legacy Function when AO = 2 |
Micro Pin |
SMT Pin |
TH Pin |
AT Command |
---|---|---|---|---|---|
DIO0 |
DIO0 |
31 |
33 |
20 |
|
DIO1 |
DIO1 |
30 |
32 |
19 |
|
DIO2 |
DIO2 |
29 |
31 |
18 |
|
DIO3 |
DIO3 |
28 |
30 |
17 |
|
DIO4 |
DIO4 |
23 |
24 |
11 |
|
DIO5 |
DIO5 |
26 |
28 |
15 |
|
DIO6 |
DIO6 |
27 |
29 |
16 |
|
DIO7 |
DIO7 |
24 |
25 |
12 |
|
DIO8 |
DIO8 |
9 |
10 |
9 |
|
DIO9 |
N/A |
25 |
26 |
13 |
|
DIO10 |
N/A |
7 |
7 |
6 |
|
DIO11 |
N/A |
8 |
8 |
7 |
|
DIO12 |
N/A |
5 |
5 |
4 |
|
DIO13 |
N/A |
3 |
3 |
2 |
|
DIO14 |
N/A |
4 |
4 |
3 |
I/O sampling is not available for pins P5 through P9. See the XBee 3 Hardware Reference Manual for full pinouts and functionality.