HA SwitchPlate HASPone: DIY In-Wall Touchscreen Home Assistant Controller

This is amazing. Can’t wait for this.

This looks great! I like the thermometers more than the fire/snowflake.

1 Like

What about a page to control a ceiling fan? Top button turns the light on/off. Then 4 smaller buttons in a square to turn the fan off, low, medium, high?

Like this?

That’s the one. Where do I get it for my HASP? :smiley: I already have one for HA.

Well since you’ve asked so nicely…

Anyone want to beta test v0.40?

I feel like I’ve nailed down the new features and the demo automations to utilize them. There have been a HUGE number of changes to the project since the last release, which means I’ve fixed some bugs and probably made some new ones. Given all the new stuff, for this cycle I want to give some intrepid users the opportunity to test the new release out before officially publishing the release.

Device firmware

Open the web interface on your HASP and navigate to the firmware update page. Paste in the following URLs to update the ESP8266 and LCD firmware. The order shouldn’t matter. The LCD firmware is now nearly 10x bigger than it used to be (yay fonts!), so expect it to take 10x longer to apply. If you have access to the SD card the process is a lot faster.

Beta ESP8266 firmware URL: http://haswitchplate.com/update/dev/HASwitchPlate.ino.d1_mini.bin
Beta LCD firmware URL: http://haswitchplate.com/update/dev/HASwitchPlate.tft

HASP HA package

The packages have seen major changes, and that includes changing the names of some of the existing files and collapsing some files together. HASP v0.40 will not require updating your automations to work, but if you want the new automations I’m going to recommend completely replacing you existing packages due to the large number of changes incoming. This will wipe out any customizations you have made!

To update, run the following command and select “R” to replace your existing device packages:

bash <(wget -qO- -o /dev/null https://raw.githubusercontent.com/aderusha/HASwitchPlate/dev/Home_Assistant/deployhasp.sh)

“Alternative” install users (venv, hassbian, etc) will want to sudo su -s /bin/bash homeassistant first. Standard installs (`HassOS’, Docker, etc) can just run the script.

Next Steps

If you do give this beta a shot, let me know how it goes for you! The HASwitchPlate Discord chat will probably the best place to handle this so we can work through any problems interactively.

1 Like

New fonts and icons vs old:

1 Like

Much more betterer!

Looks fantastical!

In all seriousness though, I like what the icons add to the whole display.

They do look nice, although without trying it, I can’t say whether the text on the date might be a bit small.

Hey @luma, great job with this.

I have got it setup as described. I did have to search back through your notes to find the right font from a screenshot above but once i cracked that, it was all good.

A couple of questions if i can.

  1. Would it also be possible to get a copy of the nexiton hmi file you used? Is there any instructions with regards to adding the new font in other sizes etc? I can not see the font to add.

  2. I have setup the HA Lovelace with the suggested additons and this has show a new tab. However seeing your screenshots it appears you have a lot more options? Also i see references to adding buttons to the nexiton via HA or is this for a future development or is something missing as i suspect?

Thanks for your help and for this project. They have been great fun and look amazing.

Ross

Thanks!

For the moment you’ll find those in the dev branch of the project repo.

That’s still just me playing with various options and demoing some of the features. When the deployhasp.sh script is run a common set of devices are created which serve no purpose other than to demonstrate the features. For example, I create “fake” lights, HVAC, alarm panel, and fan controller here. The end user would need to replace calls to these demo devices with controls for their own lights, and HVAC, and alarm panel, etc.

Most of what you see in those screenshots above is me adding the “fake” device being controlled into the UI so that one can see what’s happening as I interact w/ the control being demonstrated.

I’m not 100% sure of the context of this one. The overall UI (the pages, the placement of control objects like buttons, etc) is done in the Nextion editor and flashed to the screen. At run time, Home Assistant automations interact with the controls flashed to the screen. I’ve included examples of both things (so, a Nextion HMI with a bunch of buttons and whatever along with HA automations which “do things” with those controls), but you are free to go and edit either part as needed for your own use. However, the controls are “cooked” into the image and (for the most part) cannot be created or changed at run time.

Glad to hear it, it’s been a really fun project for me and I continue to be surprised and delighted when other people find it interesting or useful.

Thanks @luma
Thats exactly what i was looking for as i can make minor tweaks in the hmi file.
The icons have really changed things for me as using the nexiton picc previously and it was becoming very complicated. This allows me to set some basic templates and select the icons wihtout the need of many different hmi files (i have 10 of these up around the house all with different rules, including brightness of the display which i never evn thought of previously.

Sorry having worked on this project over the past few months without the need to reach (good docs) i have always had little questions which have kind of been half answered before which i wanted to ask.

I know you have covered this before but do you think there is a simple way to add heating and thermostat support. I have a couple of places where i have i have them next to the devices on a second wemos but would like to save the hardware and run them in one unit.

This has got to be my favourite HA project to date and a project which keeps giving. I will let you know if i face any issues but on a quick test i have just done now, seems everything is working great.

Thank you so much again.

Ross

If you’ve deployed the dev release for v0.40, check out page 9 for HVAC controls. Is that what you’re after? Or are you talking about using the Wemos to directly control the HVAC system itself via relays or whatever?

Is it possible to use a video stored in the HMI compile as a screen saver?

In principle yes, but the only Nextion models which support video playback are the “Intelligent” series, which start at 4.3" and thus won’t fit into this project.

If you’re planning on building your own enclosure, I would suspect the software components of this project would still work.

@luma
Are there MQTT commands to make use of the exposed GPIO? I’m thinking for sound feedback on button presses/alarm entry/exit warnings etc

0.4 looks great btw, looking forward to trying it out!

@luma
I’m testing the v0.40 and it’s amazing! thank you very much! There’s a way to set 24h clock format in the package file for the second screen?
Thank you very much!

P.S. I also don’t see the thermometer icon in the status page

Well, thanks to @benmprojects - exactly that thing has been added to the arduino firmware and will ship in the 0.40 version.

Here you can find the relevant automations for setting the clock time on start and then updating the time every minute.

In both cases you’ll find a line with this:

"{{(now().strftime(''%I'')|int)~now().strftime('':%M'')}}"

If you check an strftime reference you’ll find that %I in that string above will return the current hour in 12-hour format. Change that to %H and you’ll get the time in 24-hour format. Be sure to change %I to %H in both of the automations!

Any chance you could post a debug log of what happens when you press the button where the thermometer should be? The button press activity should trigger an automation which will place the thermometer, so maybe we can track down what isn’t happening if we can look at what is happening.

Thanks @benmprojects and @luma I’ll check it out!