Skip to content

Commit db7a8ea

Browse files
Merge pull request #1204 from ApolloAutomation/docs/btn1-gpio-pinout
docs: BTN-1 GPIO pinout for the side and top headers
2 parents a3c9197 + e54b337 commit db7a8ea

5 files changed

Lines changed: 56 additions & 0 deletions

File tree

92.5 KB
Loading
162 KB
Loading
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
title: GPIO pinout - BTN-1
3+
description: Pin-by-pin maps of the BTN-1's side and top GPIO headers, with the GPIO number and function of every pin.
4+
---
5+
--8<-- "products/btn1/additional-info/gpio-pinout.md:5:"
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
---
2+
title: GPIO pinout - BTN-1
3+
description: Pin-by-pin maps of the BTN-1's side and top GPIO headers, with the GPIO number and function of every pin.
4+
---
5+
# BTN-1 GPIO pinout
6+
7+
The BTN-1 has two GPIO headers on its circuit board: a 10-pin header on the side and a 16-pin header on the top. Use these maps to wire extra sensors, LEDs, or other hardware to your BTN-1 and to find the GPIO numbers you need in ESPHome.
8+
9+
!!! note "Open the case to reach the headers"
10+
11+
The headers are on the circuit board inside the case. Follow [Teardown and reassembly of BTN-1](../troubleshooting/btn1-teardown.md) to lift out the board, and flip the battery switch off first if your BTN-1 has a battery.
12+
13+
## Side header
14+
15+
![BTN-1 side GPIO header seen edge-on, with pins 1 to 5 on the top row, pins 6 to 10 on the bottom row, and the function of each pin listed below](/assets/btn-1-side-gpio-pinout.webp)
16+
17+
The table below is laid out like the header in the photo, with pin 1 at the end farthest from the USB-C port.
18+
19+
| Row | | | | | |
20+
| --- | --- | --- | --- | --- | --- |
21+
| Nearest the board | **1** GPIO23 | **2** Ground | **3** LED_Next (GPIO21) | **4** +VOUTPUT | **5** +3v3_CTRL |
22+
| Outer | **6** GPIO4 | **7** GPIO22 | **8** GPIO19 | **9** SCL | **10** SDA |
23+
24+
- **LED_Next** is tied to the BTN-1's existing LEDs.
25+
- **+VOUTPUT** is 5V from USB, or + from the battery.
26+
27+
## Top header
28+
29+
![BTN-1 top GPIO headers on the circuit board, with pins 1 to 8 on the left header, pins 9 to 16 on the right header, and the function of each pin listed below](/assets/btn-1-top-gpio-pinout.webp)
30+
31+
The top header is two blocks of eight pins, laid out below like the header in the image.
32+
33+
### Block nearest the USB-C port
34+
35+
| Row | | | | |
36+
| --- | --- | --- | --- | --- |
37+
| Nearest the board | **1** +VBAT | **2** Reset button | **3** Boot button (GPIO2) | **4** SCL (GPIO0) |
38+
| Outer | **5** USB D- | **6** USB D+ | **7** SDA (GPIO1) | **8** GPIO3 |
39+
40+
### Block nearest the buttons
41+
42+
| Row | | | | |
43+
| --- | --- | --- | --- | --- |
44+
| Nearest the board | **9** GPIO7 | **10** GPIO14 | **11** GPIO15 | **12** GPIO20 |
45+
| Outer | **13** +5V | **14** +3v3_CTRL | **15** GPIO22 | **16** Ground |
46+
47+
!!! tip "+3v3_CTRL is switched"
48+
49+
The +3v3_CTRL pin on both headers only has power while GPIO18 is on. If something you power from it stays off, check that GPIO18 is on.

‎mkdocs.yml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,7 @@ nav:
266266
- Bluetooth Proxy: products/btn1/additional-info/bluetooth-proxy.md
267267
- How To Wake Up Your Sensor: products/btn1/battery-sensors/wake-up-battery-sensor.md
268268
- Prevent Sleep: products/btn1/additional-info/prevent-sleep.md
269+
- GPIO Pinout: products/btn1/additional-info/gpio-pinout.md
269270
- Examples:
270271
- Blueprint: products/btn1/examples/blueprint.md
271272
- Troubleshooting:
@@ -711,6 +712,7 @@ nav:
711712
- Sensor Definitions: homey/products/btn1/setup/sensor-definitions.md
712713
- How To Wake Up Your Sensor: homey/products/btn1/battery-sensors/wake-up-battery-sensor.md
713714
- Prevent Sleep: homey/products/btn1/additional-info/prevent-sleep.md
715+
- GPIO Pinout: homey/products/btn1/additional-info/gpio-pinout.md
714716
- Addons:
715717
- BTN-1 Addon: homey/products/btn1/addons/btn1-addon.md
716718
- Examples:

0 commit comments

Comments
 (0)