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

Calling out for help, nothing I’m trying thus far seems to catch this behavior with the new breaking changes in 2021.04.

Allright, calls for help have gone unanswered but I have an ugly solution that appears to work. The repo has been updated with all impacted blueprints changed to deal with this new behavior, while still working with the pre-2021.04 behavior.

I have no idea if this approach is going to work in October when this behavior is set to change yet again.

Have I mentioned how much I love breaking changes?

edit: welp - still some errors, continuing to troubleshoot.

edit2: errors resolved, github updated again.

1 Like

Thanks, it’s partially working again! There is still an issue with the lovelace card generation being incomplete but it looks like it has to do with not all the entities being created by the Core Functionality blueprint.

Invalid entity ID at position 4: null
type: entities
title: HASP hasp_plate_04
show_header_toggle: false
state_color: true
entities:
  - entity: number.hasp_plate_04_active_page
  - type: divider
  - entity: light.hasp_plate_04_backlight
    secondary_info: brightness
  - type: divider
  - entity: null
    icon: 'mdi:palette'
    name: Selected Foreground Color
    secondary_info: brightness
  - entity: null
    icon: 'mdi:palette'
    name: Selected Background Color
    secondary_info: brightness
  - entity: null
    icon: 'mdi:palette'
    name: Unselected Foreground Color
    secondary_info: brightness
  - entity: null
    icon: 'mdi:palette'
    name: Unselected Background Color
    secondary_info: brightness
  - type: divider
footer:
  type: buttons
  entities:
    - entity: sensor.hasp_plate_04_sensor
      name: Blueprints
      icon: 'mdi:palette-swatch'
      tap_action:
        action: navigate
        navigation_path: /config/blueprint/dashboard
    - entity: sensor.hasp_plate_04_sensor
      name: Automations
      icon: 'mdi:robot'
      tap_action:
        action: navigate
        navigation_path: /config/automation/dashboard
    - entity: sensor.hasp_plate_04_sensor
      name: HASP Admin
      icon: 'mdi:cellphone-text'
      tap_action:
        action: url
        url_path: 'http://192.168.100.140

That does appear to be the problem. At the bottom of the core blueprints you have deployed, enable “First-time HASP setup or reset”, click Save, then hit “RUN ACTIONS”. That should create the missing parts for you (which didn’t work the first time due to the issues above).

Thanks that took care of it. Is there a race condition on the initial setup between the parallel paths? I noticed there was a delay on the lovelace card creation.

There are a few delays in the blueprint to allow things like the HASPone device reboot to complete in time. Glad to hear it worked out!

1 Like

Im new to Hasplate… can someone show me how to fix the problem im facing… mqtt connects on the 1st upload of the bin file to my d1 mini lite… however if i restart or unplug and replug the d1 mini… its not connecting anymore to mqtt… and wants me to input again the mqtt username and pass to the webgui… but after inputting the right credentials, mqtt never connect again unless i re upload the bin file to the d1 mini lite… im always stuck on “Configure MQTT:” screen on the nextion display…

heres the error on mosquitto broker logs
1618169133: New connection from 172.30.32.1 on port 1883.
1618169133: Socket error on client , disconnecting.

Might be a bad flash. Try following this guide (particularly, the “erase flash” bit) and see if maybe that helps you out.

Check out this on github GitHub - HASwitchPlate/openHASP: HomeAutomation Switchplate based on lvgl for STM32F407, ESP32 & ESP8266
got 2 wt32-sco1 3.5 plates up and running with this code just waiting for gpios to be integrated then going full in.

2 Likes

Thank you very much. That sorted it. I had tried re-flashing a few times but not wiping first.

i tried reflasing again… using the provided link… yes wipe all data with the lastest bin file… mqtt connects for the 1st time but after i reset the d1 mini… it says “configure mqtt” again… then never connects to the mosquito broker.

im using d1 mini lite… does it make any difference? i know the d1 mini lite has less flash memory… maybe it doesn’t have enough memory to save my mqtt settings after restart. or i could be wrong?

That may very well be the case, the BOM has been pretty carefully selected for the features this project uses. Can you get a hold of a standard D1 mini?

i ordered the standard d1 mini yesterday… it would take a week for it get deliver… by the way im from philippines and im enjoying this project… :slight_smile:

im lucky to find a nodemcu lying around and tried to flash again… but this time with success! im using a nextion 3.5 basic… i also modify the hmi files and make it a little bit larger resolution to fit the 3.5 display… the problem now is im having a hard time positioning the icons… by the way my button height is 94… if that can help sort things out… thanks again luma… this is really cool!

Hey luma… i was wondering how can i put icon buttons like this with your ha switch plate? my simple goal is when i press the icon the color change… and even if i turn ON a light on a physical switch… the icons on the nextion will update its status and change its color too…

any idea how can i achieve this? thanks!

Based on your description, I think the Display Toggle blueprint would be just the trick. You can mix icons in with your text by copying icons from here and then pasting the result in alongside any text you want displayed.

1 Like

Could you open a new thread for this. Openhasp is a different (although complementary) project. I am interested in those devises and some pics would be great!

would the icon change color too? for example black light bulb for OFF status then yellow light bulb icon for ON status? as per testing i can change the background color… but not the icon color…

Or is there a way that i can just upload a Picture for OFF state and another Picture for ON state?

Possible, but will take substantially more effort. For pictures, you’re going to need to edit the HMI project in the Nextino editor, add your photos, and then place them into the project. You’d be diving into the deep end on that one, but it is doable.