From eddba39d4a92beb4364164e496c4ebbba8256dbe Mon Sep 17 00:00:00 2001 From: Edward Firmo Date: Fri, 11 Aug 2023 00:30:34 +0200 Subject: [PATCH] Create Alarm page --- ReleaseNotes.md | 2 - nspanel_eu.HMI | Bin 21307134 -> 21307134 bytes nspanel_eu_code/alarm.txt | 279 ++++++++++++++++++++++++++------------ 3 files changed, 195 insertions(+), 86 deletions(-) diff --git a/ReleaseNotes.md b/ReleaseNotes.md index 89082e2..fbe3d57 100644 --- a/ReleaseNotes.md +++ b/ReleaseNotes.md @@ -11,8 +11,6 @@ First of all, we wanna say a big thanks to all of you who starred this project i After a long wait since the latest big release, which we used to leave our desks for a while and enjoy some vacations time with our beloved ones, we are proud to introduce the version 4.0, which adds new screens and makes your panel more flexible and robust. -### -   ## Updating Since in this update lots of input to the blueprint changed, we highly recommend you review your settings and make sure all fields have the correct selection. We did our best to support your legacy settings and avoid breaking your system, but please double check your settings if you see something not working as expected. diff --git a/nspanel_eu.HMI b/nspanel_eu.HMI index 25ff329f8e2bce7d1c5888e171bbc293f1e053c4..ac66494c771abfbe6cd405de422b83aec596e55d 100644 GIT binary patch delta 6984 zcmeI0dwdkt702%+iAOBwznr(}}x$ zVjy44xUe?HkNjRfv{ocy9KP^KV^Mxzj?a$t)-T-DzhC!G1K)aa!2$2$v zpYi%KMu-*Ye16qjCPbt$uI(yBEavfRRlE@0BJ}a*ZbA$-=DeFE#3ROdQi>4K#{6kL zh3I08AMAy=@c0TmX%V7QyOI-~Uu6V;W*4Hu7#ClqP15F6_c!M#*O+q_4-%rgkrQjd+Y`-e-ZsS?@1ADP$;~sy_v7APogu^$W3ilB=J@3~LL4;`YAiIz?s-CljNeZ! z7UBbAJYt~`CyenGE*{hB?D9Kzo_3{0Q1Vdqe#J-Ujy#q|_E^srdcStrXbP-#_6r_4 z>*|t7&yG{KQp+0mj$r(FH8X;qee$DRIyy~_q13@1qUKFyHtLgK9!=hR)g0Q}vdE@v zp#}R&=F+19Zw+PKrKV75n!1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pkuNgmXl2jN}-_5y=t7@f62s uj;A@saE#>`$1$EGnqvY-497%{SdKUjE5{^`c#g>&2})ze+$l=cd;bQUv=9;i diff --git a/nspanel_eu_code/alarm.txt b/nspanel_eu_code/alarm.txt index fa3922e..a3f7116 100644 --- a/nspanel_eu_code/alarm.txt +++ b/nspanel_eu_code/alarm.txt @@ -18,37 +18,37 @@ Page alarm page home }else { - alarmsetting.txt="{\"page\": \"alarm\", \"component\": \"currentpage\", \"value\": \"pagechange\", \"entity\": \""+home.entity.txt+"\"}" + lastclick.txt="{\"page\": \"alarm\", \"component\": \"currentpage\", \"value\": \"pagechange\", \"entity\": \""+home.entity.txt+"\"}" printh 92 prints "nspanelevent",0 printh 00 - prints alarmsetting.txt,0 + prints lastclick.txt,0 printh 00 printh FF FF FF } Touch Press Event - alarmsetting.txt="{\"page\": \"alarm\", \"component\": \"touchevent\", \"value\": \"press\", \"entity\": \""+home.entity.txt+"\"}" + lastclick.txt="{\"page\": \"alarm\", \"component\": \"touchevent\", \"value\": \"press\", \"entity\": \""+home.entity.txt+"\"}" printh 92 prints "touchevent",0 printh 00 - prints alarmsetting.txt,0 + prints lastclick.txt,0 printh 00 printh FF FF FF Touch Release Event - alarmsetting.txt="{\"page\": \"alarm\", \"component\": \"touchevent\", \"value\": \"release\", \"entity\": \""+home.entity.txt+"\"}" + lastclick.txt="{\"page\": \"alarm\", \"component\": \"touchevent\", \"value\": \"release\", \"entity\": \""+home.entity.txt+"\"}" printh 92 prints "touchevent",0 printh 00 - prints alarmsetting.txt,0 + prints lastclick.txt,0 printh 00 printh FF FF FF Page Exit Event home.entity.txt="" -Variable (string) alarmsetting +Variable (string) lastclick Attributes ID : 7 Scope : local @@ -91,7 +91,7 @@ Text icon_state Text bt_home_text Attributes - ID : 14 + ID : 11 Scope : local Dragging : 0 Send Component ID : disabled @@ -101,7 +101,7 @@ Text bt_home_text Text bt_home_bri Attributes - ID : 15 + ID : 12 Scope : local Dragging : 0 Send Component ID : disabled @@ -109,19 +109,9 @@ Text bt_home_bri Text : Max. Text Size : 4 -Text bt_home_icon - Attributes - ID : 16 - Scope : local - Dragging : 0 - Send Component ID : disabled - Associated Keyboard: none - Text :  - Max. Text Size : 10 - Text bt_away_text Attributes - ID : 19 + ID : 14 Scope : local Dragging : 0 Send Component ID : disabled @@ -131,7 +121,7 @@ Text bt_away_text Text bt_away_bri Attributes - ID : 20 + ID : 15 Scope : local Dragging : 0 Send Component ID : disabled @@ -139,19 +129,9 @@ Text bt_away_bri Text : Max. Text Size : 4 -Text bt_away_icon - Attributes - ID : 21 - Scope : local - Dragging : 0 - Send Component ID : disabled - Associated Keyboard: none - Text :  - Max. Text Size : 10 - Text bt_night_text Attributes - ID : 24 + ID : 17 Scope : local Dragging : 0 Send Component ID : disabled @@ -161,7 +141,7 @@ Text bt_night_text Text bt_night_bri Attributes - ID : 25 + ID : 18 Scope : local Dragging : 0 Send Component ID : disabled @@ -169,14 +149,124 @@ Text bt_night_bri Text : Max. Text Size : 4 -Text bt_night_icon +Text bt_vacat_text + Attributes + ID : 20 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : Vacaation + Max. Text Size : 10 + +Text bt_vacat_bri + Attributes + ID : 21 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 4 + +Text bt_bypass_text + Attributes + ID : 23 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : Bypass + Max. Text Size : 10 + +Text bt_bypass_bri + Attributes + ID : 24 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 4 + +Text bt_disarm_text Attributes ID : 26 Scope : local Dragging : 0 Send Component ID : disabled Associated Keyboard: none - Text :  + Text : Disarm + Max. Text Size : 10 + +Text bt_disarm_bri + Attributes + ID : 27 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 4 + +Text bt_home_icon + Attributes + ID : 28 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 10 + +Text bt_away_icon + Attributes + ID : 29 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 10 + +Text bt_night_icon + Attributes + ID : 30 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 10 + +Text bt_vacat_icon + Attributes + ID : 31 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 10 + +Text bt_bypass_icon + Attributes + ID : 32 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : + Max. Text Size : 10 + +Text bt_disarm_icon + Attributes + ID : 33 + Scope : local + Dragging : 0 + Send Component ID : disabled + Associated Keyboard: none + Text : Max. Text Size : 10 Picture alarm_exit @@ -188,54 +278,45 @@ Picture alarm_exit Picture bt_home_pic Attributes - ID : 13 + ID : 10 Scope : local Dragging : 0 Send Component ID: disabled Picture bt_away_pic Attributes - ID : 18 + ID : 13 Scope : local Dragging : 0 Send Component ID: disabled Picture bt_night_pic Attributes - ID : 23 + ID : 16 Scope : local Dragging : 0 Send Component ID: disabled -Dual-state Button bt_disarm +Picture bt_vacat_pic Attributes - ID : 10 + ID : 19 Scope : local Dragging : 0 Send Component ID: disabled - State : unpressed - Text : Disarm - Max. Text Size : 10 -Dual-state Button bt_vacations +Picture bt_bypass_pic Attributes - ID : 11 + ID : 22 Scope : local Dragging : 0 Send Component ID: disabled - State : unpressed - Text : Vacations - Max. Text Size : 10 -Dual-state Button bt_bypass +Picture bt_disarm_pic Attributes - ID : 12 + ID : 25 Scope : local Dragging : 0 Send Component ID: disabled - State : unpressed - Text : Bypass - Max. Text Size : 10 Hotspot alarm_back Attributes @@ -265,73 +346,103 @@ Hotspot alarm_back Hotspot bt_home Attributes - ID : 17 + ID : 34 Scope : local Dragging : 0 - Send Component ID: on press and release + Send Component ID: disabled Events - Touch Press Event - printh 92 - prints "nspanelevent",0 - printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_home\", \"value\": \"press\"}",0 - printh 00 - printh FF FF FF - Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"home\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" printh 92 - prints "nspanelevent",0 + prints "localevent",0 printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_home\", \"value\": \"release\"}",0 + prints lastclick.txt,0 printh 00 printh FF FF FF Hotspot bt_away Attributes - ID : 22 + ID : 35 Scope : local Dragging : 0 - Send Component ID: on press and release + Send Component ID: disabled Events - Touch Press Event - printh 92 - prints "nspanelevent",0 - printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_away\", \"value\": \"press\"}",0 - printh 00 - printh FF FF FF - Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"away\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" printh 92 - prints "nspanelevent",0 + prints "localevent",0 printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_away\", \"value\": \"release\"}",0 + prints lastclick.txt,0 printh 00 printh FF FF FF Hotspot bt_night Attributes - ID : 27 + ID : 36 Scope : local Dragging : 0 - Send Component ID: on press and release + Send Component ID: disabled Events - Touch Press Event + Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"night\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" printh 92 - prints "nspanelevent",0 + prints "localevent",0 printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_night\", \"value\": \"press\"}",0 + prints lastclick.txt,0 printh 00 printh FF FF FF +Hotspot bt_vacat + Attributes + ID : 37 + Scope : local + Dragging : 0 + Send Component ID: disabled + + Events Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"vacation\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" printh 92 - prints "nspanelevent",0 + prints "localevent",0 printh 00 - prints "{\"page\": \"alarm\", \"component\": \"button_night\", \"value\": \"release\"}",0 + prints lastclick.txt,0 + printh 00 + printh FF FF FF + +Hotspot bt_bypass + Attributes + ID : 38 + Scope : local + Dragging : 0 + Send Component ID: disabled + + Events + Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"bypass\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" + printh 92 + prints "localevent",0 + printh 00 + prints lastclick.txt,0 + printh 00 + printh FF FF FF + +Hotspot bt_disarm + Attributes + ID : 39 + Scope : local + Dragging : 0 + Send Component ID: disabled + + Events + Touch Release Event + lastclick.txt="{\"domain\": \"alarm\", \"key\": \"disarm\", \"value\": \"click\", \"entity\": \""+home.entity.txt+"\"}" + printh 92 + prints "localevent",0 + printh 00 + prints lastclick.txt,0 printh 00 printh FF FF FF