[READ-ONLY] Mirror of https://github.com/flo-bit/buttfinity. smart buttons w/ gridfinity for smart home, macropad, midi keyboard and more flo-bit.dev/buttfinity/
esp32 esphome gridfinity home-assistant macropad
0

Configure Feed

Select the types of activity you want to include in your feed.

update docs

Florian (Oct 28, 2025, 2:17 AM +0100) 010dadd7 82634885

+269 -273
-32
Hardware.md
··· 1 - 2 - ## Parts 3 - 4 - > [!NOTE] 5 - > Amazon links are to the german amazon store and are not affiliate links, just where I bought the parts, I've tried to always use the most available parts, feel free to buy elsewhere. You can also use different microcontrollers, buttons/sensors, etc, see [Creating your own lids/bins](./docs/creating-your-own-lids-bins.md) for more information. 6 - 7 - ### Microcontroller 8 - 9 - - ESP32 D1 Mini USB C [amazon](https://amazon.de/dp/B0CJNMRG37) (recommended version, lots of pins, works as a BLE keyboard) 10 - 11 - - ESP8266 D1 Mini USB C [amazon](https://amazon.de/dp/B0D9W2WM2K) (cheaper version, less pins, DOES NOT work as a BLE keyboard, only for controlling your smart home with home assistant) 12 - 13 - - RP2040 Zero Mini [amazon](https://amazon.de/gp/product/B0CNSQCV9Q) (no bluetooth or wifi but works as a HID usb device) 14 - 15 - ### Various 16 - 17 - - Magnets (6x2mm) [amazon](https://amazon.de/dp/B0DRNQT85B) 18 - - Jumper cables 10cm & 20cm [amazon](https://www.amazon.de/dp/B0CFXZDBVY) 19 - - Pin headers 2.54mm [amazon](https://www.amazon.de/dp/B07XM71CHT) 20 - 21 - ### Buttons/controls 22 - 23 - > [!NOTE] 24 - > You don't need all of these, mix and match to your needs/preferences. If you have some other buttons/controls, feel free to [design your own lid](./docs/creating-your-own-lids-bins.md) (if you design something with a widely available part, a PR is welcome). 25 - 26 - For corresponding lids, see [Lids.md](./Lids.md). 27 - 28 - - MX keyswitches [amazon](https://amazon.de/dp/B0BM9KR6QH) 29 - - Self-locking push button switch 8x8mm [amazon](https://amazon.de/dp/B0D2RKL3L1) 30 - - Rotary encoder [amazon](https://amazon.de/dp/B09SG3HF9N) 31 - - Slider potentiometer 10k [amazon](https://www.amazon.de/dp/B0D6244S3Y) 32 - - Capacitive touch sensor [amazon](https://www.amazon.de/dp/B09VPK9N7F)
-71
Lids.md
··· 1 - # Lids 2 - 3 - ## Switches 4 - 5 - ### MX key switches 6 - 7 - > [!NOTE] 8 - > the mx switch lids are too tall to be used as a lid for the bin containing the microcontroller. Either use a lid with a different sensor or a blank lid. 9 - 10 - #### 1x1 round mx switch 11 - 12 - ![round-mx-key](https://github.com/user-attachments/assets/0d917087-21ff-4c26-b0a9-f32d2f6f3d86) 13 - 14 - Use with mx-switch-round-cap-23mm. 15 - 16 - #### 1x1 square mx switch 17 - 18 - ![square-mx-switch](https://github.com/user-attachments/assets/1ea6a703-620f-4e8e-b87d-ada5feed8370) 19 - 20 - Use with mx-switch-square-cap-33x33mm. 21 - 22 - #### 1x1 2 mx switches 23 - 24 - ![two-mx-switches](https://github.com/user-attachments/assets/96080e49-99f1-488b-b090-8cc5584aa161) 25 - 26 - Use with mx-switch-square-cap-15x33mm. 27 - 28 - #### 1x1 4 mx switches 29 - 30 - ![four-mx-keys](https://github.com/user-attachments/assets/66227468-aff2-439b-9f2a-dfe1a6d98079) 31 - 32 - Use with mx-switch-square-cap-15x15mm. 33 - 34 - #### 2x1 8 mx switches 35 - 36 - ![eight-mx-switches](https://github.com/user-attachments/assets/3c29489d-aed7-4dfd-9d7b-b15f0b13cd93) 37 - 38 - Use with mx-switch-square-cap-15x15mm. 39 - 40 - ### Self-locking 8x8mm switch 41 - 42 - #### 1x1 round self-locking switch 43 - 44 - ![round-lock-switch](https://github.com/user-attachments/assets/2db9126a-7a15-454f-b495-049386368cd5) 45 - 46 - 47 - Use with switch-lock-round-cap-23mm. 48 - 49 - ### Rotary encoder 50 - 51 - #### 1x1 rotary encoder 52 - 53 - ![rotary-encoder](https://github.com/user-attachments/assets/71e3282d-cf01-481a-a143-e656c34fc811) 54 - 55 - Use with rotary-encoder-cap-15mm. 56 - 57 - #### 1x1 4 rotary encoders 58 - 59 - ![four-rotary-encoders](https://github.com/user-attachments/assets/a92af47c-9342-4e72-b5de-7dede6285f84) 60 - 61 - Use with rotary-encoder-cap-15mm. 62 - 63 - ### Slider potentiometer 64 - 65 - Use with slider-cap-18mm. 66 - 67 - #### 2x1 75mm slider potentiometer 68 - 69 - ![slider](https://github.com/user-attachments/assets/e280cec2-2faa-49ae-88bf-b97bb8a23d37) 70 - 71 - Use with slider-cap-18mm.
+5 -9
Readme.md
··· 28 28 > [!NOTE] 29 29 > This documentation is for the ESP32 or ESP8266 version only, there is no tutorial for the RP2040 version yet. 30 30 31 - 1. Get the parts if you don't have them yet, see [Hardware Guide](Hardware.md) 32 - 2. 3D print the bins and lids, see [3D Printing](docs/3d-printing.md) 33 - 2. Install ESPHome, see [ESPHome Guide](docs/install-esphome.md) 31 + 1. Get the parts if you don't have them yet, see [Hardware Guide](docs/hardware/1-Hardware.md) 32 + 2. 3D print the bins and lids, see [3D Printing](docs/hardware/2-3d-printing.md) 33 + 2. Install ESPHome, see [ESPHome Guide](docs/software/1-install-esphome.md) 34 34 3. Either: 35 - - turn your Buttfinity into a BLE keyboard, see [Using as BLE Keyboard](docs/using-as-ble-keyboard.md) 36 - - or add buttons to your Home Assistant, see [Add Buttons to Home Assistant](docs/add-buttons-to-homeassistant.md) 37 - 38 - ## Creating your own lids/bins 39 - 40 - [Creating your own lids/bins](docs/creating-your-own-lids-bins.md). 35 + - turn your Buttfinity into a BLE keyboard, see [Using as BLE Keyboard](docs/software/2-using-as-ble-keyboard.md) 36 + - or add buttons to your Home Assistant, see [Add Buttons to Home Assistant](docs/software/3-add-buttons-to-homeassistant.md) 41 37 42 38 ## Credits 43 39
-13
docs/3d-printing.md
··· 1 - # 3D Printing 2 - 3 - Choose the lids you want to print depending on the buttons/controls you want to use, see [all available lids here](../Lids.md). 4 - 5 - You can find the stls for all models in the `stls/` folder or get the print profile with [all lids and bins on makerworld](https://makerworld.com/en/models/1834693-buttfinity-smart-gridfinity-buttons). 6 - 7 - You need one special bin for your microcontroller (a 1x1x5 bin with a special cutout for the microcontroller to snap into, currently there are bins for the ESP32 D1 mini, ESP8266 D1 mini and RP2040 Zero Mini), all other bins are basically normal 1x1x5 (or 2x1x5) gridfinity bins, just with some extra cutouts for the cables. 8 - 9 - Print one of the microcontroller bins and then the same amount of other bins minus one as you have 1x1 lids (and print a 2x1x5 bin for every 2x1 lid you want). 10 - 11 - You can optionally print a normal gridfinity baseplate if you want one or add magnets. 12 - 13 - There are also optional plugs for the outside of your assembled module, that can be used to fill the holes in the bins.
-19
docs/add-buttons-to-homeassistant.md
··· 1 - # Adding buttons to Home Assistant 2 - 3 - Add buttons or similar to Home Assistant by adding sensors to you ESPHome config (in ESPHome Device Builder click "Edit"). 4 - 5 - Simple example for a button (you might have to change the pin): 6 - 7 - ```yaml 8 - binary_sensor: 9 - - platform: gpio 10 - pin: 11 - number: GPIO22 12 - mode: INPUT_PULLUP 13 - inverted: true 14 - name: "Button" 15 - ``` 16 - 17 - In Home Assistant you can then go to "Settings" -> "Devices & Services", where your ESP should appear. Add it and you should see your Button as a sensor. Add automations using that button doing whatever you want it to do. 18 - 19 - Other sensors work mostly the same, see [the ESPHome documentation](https://esphome.io/components/) for available sensors.
-9
docs/creating-your-own-lids-bins.md
··· 1 - # Creating your own lids/bins 2 - 3 - ## Bins 4 - 5 - If you have a microcontroller you want to use that doesn't yet have a bin, you can create your own by using the openscad base file `./models/bins/buttfinity-bin-base.scad`, simply add some cutouts for your microcontroller and export as stl (see `./models/bins/buttfinity-bin-esp32.scad` for an example). 6 - 7 - ## Lids 8 - 9 - If you have a sensor or button you want to use that doesn't yet have a lid, you can create your own by using the openscad base file `./models/lids/lid-module.scad`, add some cutouts for your sensor or button and export as stl (see `./models/lids/switches/buttfinity-1x1-1-round-mx-switch-lid.scad` for an example).
-47
docs/install-esphome.md
··· 1 - # Installing ESPHome 2 - 3 - > [!NOTE] 4 - > If you don't have Home Assistant and just want to use Buttfinity as a BLE keyboard, instead of step 1, follow [the instructions here](./installing-without-homeassistant.md). 5 - 6 - 7 - 1. Add ESPHome to your Home Assistant by clicking [this link](https://my.home-assistant.io/redirect/supervisor_addon/?addon=5c53de3b_esphome&repository_url=https%3A%2F%2Fgithub.com%2Fesphome%2Fhome-assistant-addon) and clicking "Install". 8 - 9 - Then in ESPHome Device Builder: 10 - 11 - 2. Click "New Device" 12 - 13 - 3. Click "Continue" 14 - 15 - 4. Enter a name for your device and enter your Wifi name and password. 16 - 17 - 5. Select "ESP32" or "ESP8266" as the board (depending on your microcontroller) 18 - 19 - 6. Click "Skip" when asked to install to your device. 20 - 21 - 7. A new device should appear in the list, click "Edit" and you should see the config for your device. 22 - 23 - 8. If you have an ESP32, change line 5-8 to: 24 - 25 - ```yaml 26 - esp32: 27 - board: wemos_d1_mini32 28 - framework: 29 - type: arduino 30 - ``` 31 - 32 - If you have an ESP8266, change line 5-6 to: 33 - 34 - ```yaml 35 - esp8266: 36 - board: d1_mini 37 - ``` 38 - 39 - 9. Click "Install" in the top right corner and select "Manual Download". 40 - 41 - 10. Wait a few minutes until it's done compiling, then select "Factory Format (Previously Modern)" as the version you want to download. 42 - 43 - 11. Open [ESPHome Web](https://web.esphome.io/) and click "Add Device" in the top right corner, connect your microcontroller to your computer, click "Connect", select your device. 44 - 45 - 12. Click "Install" and add the project you downloaded from the ESPHome Device Builder and wait until it's done installing. 46 - 47 - 13. From now on you can flash you microcontroller wirelessly in the ESPHome Device Builder, you can either [add buttons to connect to Home Assistant](./add-buttons-to-homeassistant.md) there or [use it as a BLE keyboard](./using-as-ble-keyboard.md)
-28
docs/installing-without-homeassistant.md
··· 1 - # Installing ESPHome without Home Assistant 2 - 3 - If you don't have Home Assistant you can still use Buttfinity to control your computer (as a "fake" BLE keyboard). 4 - 5 - > [!IMPORTANT] 6 - > This only works with a ESP32 D1 Mini, ESP8266 does not work as a BLE keyboard. 7 - 8 - 1. Install [ESPHome Device Builder](https://esphome.io/guides/getting_started_command_line/#esphome-device-builder-docker) by: 9 - 10 - - Installing [Docker](https://docs.docker.com/get-started/get-docker/) if you don't have it yet 11 - 12 - - Running `ESPHome Device Builder` in a terminal: 13 - 14 - if you have a mac run: 15 - ```bash 16 - # MacOs 17 - docker run --rm -p 6052:6052 -e ESPHOME_DASHBOARD_USE_PING=true -v "${PWD}":/config -it ghcr.io/esphome/esphome 18 - ``` 19 - 20 - otherwise run: 21 - ```bash 22 - # On Docker, host networking mode is required for online status indicators 23 - docker run --rm --net=host -v "${PWD}":/config -it ghcr.io/esphome/esphome 24 - ``` 25 - 26 - 2. Open [`localhost:6052`](http://localhost:6052) in your browser and you should see the ESPHome dashboard. 27 - 28 - Next follow the instructions to [install ESPHome](./install-esphome-on-esp.md) on your ESP32 D1 Mini, then the instructions to [simulate a BLE keyboard](./using-as-ble-keyboard.md).
-38
docs/using-as-ble-keyboard.md
··· 1 - # Using as a BLE keyboard 2 - 3 - > [!IMPORTANT] 4 - > This only works with the ESP32 version, both ESP8266 and RP2040 are not supported, as they don't have bluetooth. 5 - 6 - Turn your Buttfinity module into a BLE keyboard by adding the following to you ESPHome config (in ESPHome Device Builder click "Edit"). 7 - 8 - ```yaml 9 - external_components: 10 - - source: github://dmamontov/esphome-blekeyboard 11 - 12 - ble_keyboard: 13 - id: my_ble_keyboard 14 - name: "Buttfinity BLE Keyboard" 15 - manufacturer_id: "Buttfinity" 16 - reconnect: true 17 - battery_level: 50 18 - buttons: true 19 - ``` 20 - 21 - Now you can add buttons to your Buttfinity that will send keystrokes to your computer like this (you might have to change the pin): 22 - 23 - ```yaml 24 - # type "hello world" when button is pressed 25 - binary_sensor: 26 - - platform: gpio 27 - pin: 28 - number: GPIO22 29 - mode: INPUT_PULLUP 30 - inverted: true 31 - name: "Button" 32 - on_press: 33 - - ble_keyboard.print: 34 - id: my_ble_keyboard 35 - text: "hello world" 36 - ``` 37 - 38 - See [esphome-blekeyboard](https://github.com/dmamontov/esphome-blekeyboard) for more information.
-7
docs/wiring.md
··· 1 - # Wiring 2 - 3 - The idea is to solder pin headers to your microcontroller and buttons/sensors. 4 - 5 - All buttons/sensors and the microcontroller can then easily be connected and disconnected again with jumper cables. 6 - 7 - As an alternative you can also solder jumper cables (ending in a female header) straight onto your buttons/sensors.
+32
docs/hardware/1-Hardware.md
··· 1 + 2 + ## Parts 3 + 4 + > [!NOTE] 5 + > Amazon links are to the german amazon store and are not affiliate links, just where I bought the parts, I've tried to always use the most available parts, feel free to buy elsewhere. You can also use different microcontrollers, buttons/sensors, etc, see [Creating your own lids/bins](./5-creating-your-own-lids-bins.md) for more information. 6 + 7 + ### Microcontroller 8 + 9 + - ESP32 D1 Mini USB C [amazon](https://amazon.de/dp/B0CJNMRG37) (recommended version, lots of pins, works as a BLE keyboard) 10 + 11 + - ESP8266 D1 Mini USB C [amazon](https://amazon.de/dp/B0D9W2WM2K) (cheaper version, less pins, DOES NOT work as a BLE keyboard, only for controlling your smart home with home assistant) 12 + 13 + - RP2040 Zero Mini [amazon](https://amazon.de/gp/product/B0CNSQCV9Q) (no bluetooth or wifi but works as a HID usb device) 14 + 15 + ### Various 16 + 17 + - Magnets (6x2mm) [amazon](https://amazon.de/dp/B0DRNQT85B) 18 + - Jumper cables 10cm & 20cm [amazon](https://www.amazon.de/dp/B0CFXZDBVY) 19 + - Pin headers 2.54mm [amazon](https://www.amazon.de/dp/B07XM71CHT) 20 + 21 + ### Buttons/controls 22 + 23 + > [!NOTE] 24 + > You don't need all of these, mix and match to your needs/preferences. If you have some other buttons/controls, feel free to [design your own lid](./5-creating-your-own-lids-bins.md) (if you design something with a widely available part, a PR is welcome). 25 + 26 + For corresponding lids, see [here](./3-Lids.md). 27 + 28 + - MX keyswitches [amazon](https://amazon.de/dp/B0BM9KR6QH) 29 + - Self-locking push button switch 8x8mm [amazon](https://amazon.de/dp/B0D2RKL3L1) 30 + - Rotary encoder [amazon](https://amazon.de/dp/B09SG3HF9N) 31 + - Slider potentiometer 10k [amazon](https://www.amazon.de/dp/B0D6244S3Y) 32 + - Capacitive touch sensor [amazon](https://www.amazon.de/dp/B09VPK9N7F)
+13
docs/hardware/2-3d-printing.md
··· 1 + # 3D Printing 2 + 3 + Choose the lids you want to print depending on the buttons/controls you want to use, see [all available lids here](./3-Lids.md). 4 + 5 + You can find the stls for all models in the `stls/` folder or get the print profile with [all lids and bins on makerworld](https://makerworld.com/en/models/1834693-buttfinity-smart-gridfinity-buttons). 6 + 7 + You need one special bin for your microcontroller (a 1x1x5 bin with a special cutout for the microcontroller to snap into, currently there are bins for the ESP32 D1 mini, ESP8266 D1 mini and RP2040 Zero Mini), all other bins are basically normal 1x1x5 (or 2x1x5) gridfinity bins, just with some extra cutouts for the cables. 8 + 9 + Print one of the microcontroller bins and then the same amount of other bins minus one as you have 1x1 lids (and print a 2x1x5 bin for every 2x1 lid you want). 10 + 11 + You can optionally print a normal gridfinity baseplate if you want one or add magnets. 12 + 13 + There are also optional plugs for the outside of your assembled module, that can be used to fill the holes in the bins.
+71
docs/hardware/3-Lids.md
··· 1 + # Lids 2 + 3 + ## Switches 4 + 5 + ### MX key switches 6 + 7 + > [!NOTE] 8 + > the mx switch lids are too tall to be used as a lid for the bin containing the microcontroller. Either use a lid with a different sensor or a blank lid. 9 + 10 + #### 1x1 round mx switch 11 + 12 + ![round-mx-key](https://github.com/user-attachments/assets/0d917087-21ff-4c26-b0a9-f32d2f6f3d86) 13 + 14 + Use with mx-switch-round-cap-23mm. 15 + 16 + #### 1x1 square mx switch 17 + 18 + ![square-mx-switch](https://github.com/user-attachments/assets/1ea6a703-620f-4e8e-b87d-ada5feed8370) 19 + 20 + Use with mx-switch-square-cap-33x33mm. 21 + 22 + #### 1x1 2 mx switches 23 + 24 + ![two-mx-switches](https://github.com/user-attachments/assets/96080e49-99f1-488b-b090-8cc5584aa161) 25 + 26 + Use with mx-switch-square-cap-15x33mm. 27 + 28 + #### 1x1 4 mx switches 29 + 30 + ![four-mx-keys](https://github.com/user-attachments/assets/66227468-aff2-439b-9f2a-dfe1a6d98079) 31 + 32 + Use with mx-switch-square-cap-15x15mm. 33 + 34 + #### 2x1 8 mx switches 35 + 36 + ![eight-mx-switches](https://github.com/user-attachments/assets/3c29489d-aed7-4dfd-9d7b-b15f0b13cd93) 37 + 38 + Use with mx-switch-square-cap-15x15mm. 39 + 40 + ### Self-locking 8x8mm switch 41 + 42 + #### 1x1 round self-locking switch 43 + 44 + ![round-lock-switch](https://github.com/user-attachments/assets/2db9126a-7a15-454f-b495-049386368cd5) 45 + 46 + 47 + Use with switch-lock-round-cap-23mm. 48 + 49 + ### Rotary encoder 50 + 51 + #### 1x1 rotary encoder 52 + 53 + ![rotary-encoder](https://github.com/user-attachments/assets/71e3282d-cf01-481a-a143-e656c34fc811) 54 + 55 + Use with rotary-encoder-cap-15mm. 56 + 57 + #### 1x1 4 rotary encoders 58 + 59 + ![four-rotary-encoders](https://github.com/user-attachments/assets/a92af47c-9342-4e72-b5de-7dede6285f84) 60 + 61 + Use with rotary-encoder-cap-15mm. 62 + 63 + ### Slider potentiometer 64 + 65 + Use with slider-cap-18mm. 66 + 67 + #### 2x1 75mm slider potentiometer 68 + 69 + ![slider](https://github.com/user-attachments/assets/e280cec2-2faa-49ae-88bf-b97bb8a23d37) 70 + 71 + Use with slider-cap-18mm.
+7
docs/hardware/4-wiring.md
··· 1 + # Wiring 2 + 3 + The idea is to solder pin headers to your microcontroller and buttons/sensors. 4 + 5 + All buttons/sensors and the microcontroller can then easily be connected and disconnected again with jumper cables. 6 + 7 + As an alternative you can also solder jumper cables (ending in a female header) straight onto your buttons/sensors.
+9
docs/hardware/5-creating-your-own-lids-bins.md
··· 1 + # Creating your own lids/bins 2 + 3 + ## Bins 4 + 5 + If you have a microcontroller you want to use that doesn't yet have a bin, you can create your own by using the openscad base file `./models/bins/buttfinity-bin-base.scad`, simply add some cutouts for your microcontroller and export as stl (see `./models/bins/buttfinity-bin-esp32.scad` for an example). 6 + 7 + ## Lids 8 + 9 + If you have a sensor or button you want to use that doesn't yet have a lid, you can create your own by using the openscad base file `./models/lids/lid-module.scad`, add some cutouts for your sensor or button and export as stl (see `./models/lids/switches/buttfinity-1x1-1-round-mx-switch-lid.scad` for an example).
+47
docs/software/1-install-esphome.md
··· 1 + # Installing ESPHome 2 + 3 + > [!NOTE] 4 + > If you don't have Home Assistant and just want to use Buttfinity as a BLE keyboard, instead of step 1, follow [the instructions here](./4-installing-without-homeassistant.md). 5 + 6 + 7 + 1. Add ESPHome to your Home Assistant by clicking [this link](https://my.home-assistant.io/redirect/supervisor_addon/?addon=5c53de3b_esphome&repository_url=https%3A%2F%2Fgithub.com%2Fesphome%2Fhome-assistant-addon) and clicking "Install". 8 + 9 + Then in ESPHome Device Builder: 10 + 11 + 2. Click "New Device" 12 + 13 + 3. Click "Continue" 14 + 15 + 4. Enter a name for your device and enter your Wifi name and password. 16 + 17 + 5. Select "ESP32" or "ESP8266" as the board (depending on your microcontroller) 18 + 19 + 6. Click "Skip" when asked to install to your device. 20 + 21 + 7. A new device should appear in the list, click "Edit" and you should see the config for your device. 22 + 23 + 8. If you have an ESP32, change line 5-8 to: 24 + 25 + ```yaml 26 + esp32: 27 + board: wemos_d1_mini32 28 + framework: 29 + type: arduino 30 + ``` 31 + 32 + If you have an ESP8266, change line 5-6 to: 33 + 34 + ```yaml 35 + esp8266: 36 + board: d1_mini 37 + ``` 38 + 39 + 9. Click "Install" in the top right corner and select "Manual Download". 40 + 41 + 10. Wait a few minutes until it's done compiling, then select "Factory Format (Previously Modern)" as the version you want to download. 42 + 43 + 11. Open [ESPHome Web](https://web.esphome.io/) and click "Add Device" in the top right corner, connect your microcontroller to your computer, click "Connect", select your device. 44 + 45 + 12. Click "Install" and add the project you downloaded from the ESPHome Device Builder and wait until it's done installing. 46 + 47 + 13. From now on you can flash you microcontroller wirelessly in the ESPHome Device Builder, you can either [add buttons to connect to Home Assistant](./3-add-buttons-to-homeassistant.md) there or [use it as a BLE keyboard](./2-using-as-ble-keyboard.md)
+38
docs/software/2-using-as-ble-keyboard.md
··· 1 + # Using as a BLE keyboard 2 + 3 + > [!IMPORTANT] 4 + > This only works with the ESP32 version, both ESP8266 and RP2040 are not supported, as they don't have bluetooth. 5 + 6 + Turn your Buttfinity module into a BLE keyboard by adding the following to you ESPHome config (in ESPHome Device Builder click "Edit"). 7 + 8 + ```yaml 9 + external_components: 10 + - source: github://dmamontov/esphome-blekeyboard 11 + 12 + ble_keyboard: 13 + id: my_ble_keyboard 14 + name: "Buttfinity BLE Keyboard" 15 + manufacturer_id: "Buttfinity" 16 + reconnect: true 17 + battery_level: 50 18 + buttons: true 19 + ``` 20 + 21 + Now you can add buttons to your Buttfinity that will send keystrokes to your computer like this (you might have to change the pin): 22 + 23 + ```yaml 24 + # type "hello world" when button is pressed 25 + binary_sensor: 26 + - platform: gpio 27 + pin: 28 + number: GPIO22 29 + mode: INPUT_PULLUP 30 + inverted: true 31 + name: "Button" 32 + on_press: 33 + - ble_keyboard.print: 34 + id: my_ble_keyboard 35 + text: "hello world" 36 + ``` 37 + 38 + See [esphome-blekeyboard](https://github.com/dmamontov/esphome-blekeyboard) for more information.
+19
docs/software/3-add-buttons-to-homeassistant.md
··· 1 + # Adding buttons to Home Assistant 2 + 3 + Add buttons or similar to Home Assistant by adding sensors to you ESPHome config (in ESPHome Device Builder click "Edit"). 4 + 5 + Simple example for a button (you might have to change the pin): 6 + 7 + ```yaml 8 + binary_sensor: 9 + - platform: gpio 10 + pin: 11 + number: GPIO22 12 + mode: INPUT_PULLUP 13 + inverted: true 14 + name: "Button" 15 + ``` 16 + 17 + In Home Assistant you can then go to "Settings" -> "Devices & Services", where your ESP should appear. Add it and you should see your Button as a sensor. Add automations using that button doing whatever you want it to do. 18 + 19 + Other sensors work mostly the same, see [the ESPHome documentation](https://esphome.io/components/) for available sensors.
+28
docs/software/4-installing-without-homeassistant.md
··· 1 + # Installing ESPHome without Home Assistant 2 + 3 + If you don't have Home Assistant you can still use Buttfinity to control your computer (as a "fake" BLE keyboard). 4 + 5 + > [!IMPORTANT] 6 + > This only works with a ESP32 D1 Mini, ESP8266 does not work as a BLE keyboard. 7 + 8 + 1. Install [ESPHome Device Builder](https://esphome.io/guides/getting_started_command_line/#esphome-device-builder-docker) by: 9 + 10 + - Installing [Docker](https://docs.docker.com/get-started/get-docker/) if you don't have it yet 11 + 12 + - Running `ESPHome Device Builder` in a terminal: 13 + 14 + if you have a mac run: 15 + ```bash 16 + # MacOs 17 + docker run --rm -p 6052:6052 -e ESPHOME_DASHBOARD_USE_PING=true -v "${PWD}":/config -it ghcr.io/esphome/esphome 18 + ``` 19 + 20 + otherwise run: 21 + ```bash 22 + # On Docker, host networking mode is required for online status indicators 23 + docker run --rm --net=host -v "${PWD}":/config -it ghcr.io/esphome/esphome 24 + ``` 25 + 26 + 2. Open [`localhost:6052`](http://localhost:6052) in your browser and you should see the ESPHome dashboard. 27 + 28 + Next follow the instructions to [install ESPHome](./1-install-esphome.md) on your ESP32 D1 Mini, then the instructions to [simulate a BLE keyboard](./2-using-as-ble-keyboard.md).