WiFi enabled IoT button based on ESP8266 - intended to be used with Node-Notifier
This is very early software, please tread carefully and at your own risk
Other documents:
- Clone or download and extract this repository (see releases)
- Rename the file
config.h.template
toconfig.h
and open it with a text editor - Set your WiFi settings in
config.h
(make sure to adequately protect this file) - Start the desktop client and copy its IP address
- Open the file
ESP-Notifier.ino
in the Arduino IDE - Install your ESP board in the IDE (follow this guide)
- Install the library ArduinoJson in the IDE
- Edit settings at the top of this file (like the server IP address)
- Upload the sketch with the Arduino IDE (Ctrl + U)
- Follow the example build or the schematic
Follow this schematic to build the base model of ESP-Notifier:
I used an ESP8266EX development board but this should work on any ESP dev board,
once GPIO pin mappings are changed accordingly in the .ino file.
The resistor's value is approximate.
The blue diamond shape indicates the points where I used headers to make the button and power supply detachable.
To see the original schematic without these markers, click here.
- ESP8266EX development board (you can also use the non-EX ESP but it's larger)
- a 4.7kΩ resistor
- about 3x4cm of perforated circuit board, matching the size of the ESP dev board
- female and male headers
- a momentary push button (pretty sure you're looking for an SPST type switch)
- a 5v power supply with at least 500mA (like an old phone charger)
-
Install the firmware on the ESP (follow the setup guide).
-
Place the resistor on the perforated board, between the ESP's GPIO pin you've chosen (14 aka D5 by default) and
the G or GND pin of the ESP, to act as a pull-down resistor for the switch.
In my example, the resistor is physically sandwiched between the dev board and the perforated board, so the whole thing stays as compact as possible.
-
Hook up the momentary switch between the ESP's GPIO pin you've chosen (default 14 aka D5) and the 3.3V pin of the ESP development board.
If you don't use a development board, you can also probably use the 5V / VV pin.
-
Use the female and male headers to make the button and power wires detachable (optional).
Power headers should be hooked up to the ESP dev board's pins VV or VIN and GND or G.
Button headers are hooked up between chosen GPIO pin (default 14 aka D5) and 3V3 or alternatively the 5V source from the power supply.
-
Hook up the 5V power supply to the VV or VIN pin (+) and the GND or G pin (-) of the ESP dev board.
-
Hook up the button to the headers or directly to the pins described in step 4.
-
Check if it works by pressing the button :)
If something didn't work out for you, please hook up the ESP dev board to your PC, open the serial monitor in the Arduino IDE and check what's going wrong.
If you still need help, feel free to join my Discord server to ask me:
ESP-Notifier's firmware is licensed under the MIT License
This is very early software, please tread carefully and at your own risk.
Also make sure you adequately protect the config.h
file, as it contains your WiFi password.
Made with ❤️ by Sv443
If you like ESP-Notifier please consider supporting me