modified notify page commands

This commit is contained in:
Johannes Braun
2022-03-20 15:31:12 +01:00
parent 818405fa73
commit 5d6f59df71
4 changed files with 11 additions and 1 deletions

View File

@@ -115,7 +115,7 @@ The following message can be used to update the content on the cardEntities Page
### popupNotify Page
`entityUpdateDetail,*internalName*,*tHeading*,*b1*,*b2*,*tText*`
`entityUpdateDetail,*internalName*,*tHeading*,*tHeadingColor*,*b1*,*tB1Color*,*b2*,*tB2Color*,*tText*,*tTextColor*`
### cardThermo Page

Binary file not shown.

Binary file not shown.

View File

@@ -92,6 +92,11 @@ class NsPanelLovelaceUI:
if msg[1] == "startup":
self.api.log("Handling startup event", level="DEBUG")
# grab version from screen
current_panel_version = int(msg[2])
self.api.log("Nextion Display reports version: %s; Checking for updates ...", current_panel_version)
# send date and time
self.update_time("")
self.update_date("")
@@ -567,3 +572,8 @@ class NsPanelLovelaceUI:
# reverse position for slider
pos = 100-pos
self.send_mqtt_msg(f"entityUpdateDetail,{pos}")
def send_message_page(self, id, heading, msg, b1, b2):
self.send_mqtt_msg(f"pageType,popupNotify")
self.send_mqtt_msg(f"entityUpdateDetail,{id},{heading},65535,{b2},65535,{b2},65535,{msg},65535")