The HA SwitchPlate is an LCD touchscreen you can mount into a standard "work box" in place of a light switch. It connects to your WiFi to send MQTT messages to your home automation system in response to user interactions on the screen. Buttons and text displayed on the screen can be updated by incoming MQTT messages from your home automation system or other devices on your network.
This project utilizes a Nextion 2.4" LCD Touchscreen display mounted in a standard-sized single-gang workbox as a touchscreen panel for home control and information display. An ESP8266-based microcontroller provides WiFi connectivity and system control. The project has been developed to integrate with Home Assistant but should be compatible with any other MQTT-enabled automation platform such as OpenHAB, Domoticz, Node-Red, Wink, SmartThings, Vera, HomeKit, etc.
The Arduino code for the ESP8266 provides a generic gateway between MQTT and the Nextion control language. A basic Nextion HMI display file has been included with several pages of various layouts to provide user controls or to present information in response to MQTT messages sent to the device.
To build a simple version of this project you will only need the LCD panel and the WeMos D1 Mini, 4 jumper wires, and a USB cable to power both devices.
A complete build that's ready to install will require the following components:
- Nextion 2.4" LCD Touchscreen display
- WeMos D1 Mini ESP8266 WiFi microcontroller
- 3D printed switch plate
- 3D printed rear cover
- 5V Power supply
- PCB
- Rubber grommet
- Two M2 self-tapping 6MM screws (or just any 4-6mm M2 machine screws)
- 6" each of white and black 300V 18AWG stranded power cables (I just stripped some wire out of a power cord)
- Four 20mm M2 flathead screws and four heat-set threaded inserts to fasten things together (feel free to improvise here)
The end result is a highly-customized touchscreen solution for controlling your home, mounted in the wall in a functional and attractive enclosure.
Check out the documentation to get started building your own HA SwitchPlate.