wifibutton
This project involves creating a physical WiFi button using Arduino and an Ethernet adapter W5x00 to toggle the WiFi on an OpenWRT router or acces
wifibutton
Ethernet connected physical wifi button for OpenWRT using Arduino and ENC28J60 or official Arduino Ethernet shield or WIZnet W5x00 adapter
What is this about?
If you want to switch on and off the wifi on your OpenWRT router/access point but:
- do not have a switch on the router
- the router is located at an difficult to access location
- you want to have the button in a different location than the router Then, this might be for you.
It's a button and status LED connected to an Arduino, which connects to your LAN by means of an ethernet adapter. It uses the LAN to connect to your router on which the wifitoggler.sh is constantly running. Pressing the button will send a toggle command to the wifitoggler script running on the router, which will turn on or off wifi. The Arduino is regularly querying the state of the wifi on the router and uses the LED to show the same. If the last status update is too long ago, the Arduino will start and keep blinking the LED.
What is this NOT about?
- If you are the "wifi always on" guy, you are probably not interested in this
- If you are using an off-the-shelf router not running OpenWRT (or similar), this will not work
- If you want to switch wifi on or off from a location where there is no Ethernet
Hardware setup
Hardware required to build
- Arduino
- ENC28J60 or W5x00 based ethernet adapter. Note that for the official Arduino ethernet shields or other W5100 based adapters, you need to switch the library
- Push button
- 2 LEDs with resistors (1 RGB LED built into the push button would be great)