1557 Commits

Author SHA1 Message Date
Edward Firmo
d71a1e1fe8 Change slider focus with click on temperature values 2024-01-08 16:04:03 +01:00
Edward Firmo
cded65a9ec Lint 2024-01-08 15:49:13 +01:00
Edward Firmo
f24ba9739d Lint 2024-01-08 15:40:33 +01:00
Edward Firmo
86acccc36b Updated install 2024-01-08 15:37:15 +01:00
Edward Firmo
cfb8352f85 Lint 2024-01-08 12:39:03 +01:00
Edward Firmo
a056106a9f Lint 2024-01-08 12:35:59 +01:00
Edward Firmo
eff58b978a Test against released ESPHome 2024-01-08 10:28:19 +01:00
Edward Firmo
649bc9ff0d Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2024-01-08 10:26:23 +01:00
Edward Firmo
c50a6cc5e4 Lint 2024-01-08 10:26:14 +01:00
Edward Firmo
c8be47b2e5 Delete nspanel_esphome_prebuilt.bin 2024-01-08 10:24:02 +01:00
Edward Firmo
940477b1a9 Bump version to "4.2beta.1" 2024-01-08 10:23:20 +01:00
Edward Firmo
6ddac2d53f Text improvements 2024-01-08 10:15:42 +01:00
Edward Firmo
b304be171d Send both target_temp_high and target_temp_low when calling set_temperature service with range
Solves #1551
Solves #1554
Solves #1542
2024-01-07 22:41:33 +01:00
Edward Firmo
1e65a7ef05 Lint 2024-01-07 01:42:41 +01:00
Edward Firmo
4590c9e1c7 Rebuild climate sliders
Solves #1459
Solves #1510
Solves #1531
Solves #1542
Solves #1547
2024-01-07 01:33:58 +01:00
Edward Firmo
d17206c57d Set slider to be controlled by +/-
Solves #1548
2024-01-07 00:16:56 +01:00
Edward Firmo
10b323c2d6 Lint 2024-01-06 20:26:01 +01:00
Edward Firmo
88d84a8bbd Lint 2024-01-06 20:20:49 +01:00
Edward Firmo
8c4c06b067 Lint 2024-01-06 20:14:54 +01:00
Edward Firmo
6f5ebab2ed Lint 2024-01-06 20:09:31 +01:00
Edward Firmo
2422400a28 Lint 2024-01-06 20:03:14 +01:00
Edward Firmo
c77758b0f2 Uploading to Nextion 2024-01-06 15:49:04 +01:00
Edward Firmo
ef434eb3b6 Integrating your panel to Home Assistant 2024-01-06 14:04:48 +01:00
Edward Firmo
11deb78613 Add instructions for when the buttons are not available
Solves #1494
2024-01-06 08:51:12 +01:00
Edward Firmo
56be238c65 Lint 2024-01-06 08:42:02 +01:00
Edward Firmo
df1434fd34 Inform the change API Encryption breaks connection with HA
Solves #1540
2024-01-06 08:33:48 +01:00
Edward Firmo
27ca231442 Lint 2024-01-06 01:15:03 +01:00
Edward Firmo
8b2ed460b6 Lint 2024-01-06 01:11:40 +01:00
Edward Firmo
e86919afec Lint 2024-01-06 01:09:23 +01:00
Edward Firmo
9a8ff1159b Standardize heater_relay on docs
Solves #1541
2024-01-06 00:44:29 +01:00
Edward Firmo
fd3b67288c Add instruction on how-to open pages from Home Assistant
Solves #1471
Solves #1522
2024-01-05 22:47:51 +01:00
Edward Firmo
68d921c1ee Fix page name on long_press of buttons pages
Solves #1535
Solves #1534
Solves #1511
2024-01-05 13:30:19 +01:00
Edward Firmo
a259d354b3 Lint 2024-01-05 12:25:00 +01:00
Edward Firmo
02b7420798 Lint 2024-01-05 12:23:00 +01:00
Edward Firmo
5470794a17 Lint 2024-01-05 12:20:26 +01:00
Edward Firmo
f410a205e9 Lint 2024-01-05 12:18:29 +01:00
Edward Firmo
706c600c5c Lint 2024-01-05 12:10:11 +01:00
Edward Firmo
bed6d63c7a Lint 2024-01-05 12:01:21 +01:00
Edward Firmo
f77657fabb Lint 2024-01-05 11:53:50 +01:00
Edward Firmo
d4949d16d7 Lint 2024-01-05 11:51:29 +01:00
Edward Firmo
9686a62619 Lint 2024-01-05 11:49:42 +01:00
Edward Firmo
1896e4fc68 Lint 2024-01-05 11:44:19 +01:00
Edward Firmo
f12d4c1eea Lint 2024-01-05 11:41:56 +01:00
Edward Firmo
d235ddb4ac Lint 2024-01-05 11:35:07 +01:00
Edward Firmo
4d540a8b94 Lint 2024-01-05 11:33:34 +01:00
Edward Firmo
daa9142f7f Lint 2024-01-05 11:27:52 +01:00
Edward Firmo
a617a84dc7 Lint 2024-01-05 11:24:32 +01:00
Edward Firmo
c0ffb0896c Lint 2024-01-05 11:21:57 +01:00
Edward Firmo
03d04fcd6b Markdown links 2024-01-05 11:16:12 +01:00
Edward Firmo
75c2ff88b7 Run only when a -md file changes 2024-01-05 11:14:25 +01:00
Edward Firmo
3b1a704b36 Exceptions 2024-01-05 11:11:01 +01:00
Edward Firmo
c35808b560 Remove docs in German 2024-01-05 11:06:39 +01:00
Edward Firmo
9c0958dc51 Lint 2024-01-05 10:59:55 +01:00
Edward Firmo
de3ec8e3d9 Lint 2024-01-05 10:54:53 +01:00
Edward Firmo
f69b48df52 Lint 2024-01-05 10:50:55 +01:00
Edward Firmo
371803dcf3 Markdown links 2024-01-05 10:45:50 +01:00
Edward Firmo
bcc8794b19 Lint 2024-01-05 10:35:35 +01:00
Edward Firmo
c3b11eb581 Lint 2024-01-05 10:33:14 +01:00
Edward Firmo
ddbe7d9723 Lint 2024-01-05 10:29:36 +01:00
Edward Firmo
216f6f3102 Markdown links 2024-01-05 10:27:05 +01:00
Edward Firmo
db8e204fa6 Update validate_markdown.yml 2024-01-05 10:20:59 +01:00
Edward Firmo
afea2518ce Create config file 2024-01-05 10:19:16 +01:00
Edward Firmo
484fc4ba8c Update validate_markdown.yml 2024-01-05 10:13:25 +01:00
Edward Firmo
d158a801ad Update validate_markdown.yml 2024-01-05 10:11:21 +01:00
Edward Firmo
5268e214a3 Lint 2024-01-05 10:07:09 +01:00
Edward Firmo
71e33527a5 Lint 2024-01-05 10:05:38 +01:00
Edward Firmo
671145a56b Lint 2024-01-05 10:03:03 +01:00
Edward Firmo
65dc1cdf25 Lint 2024-01-05 09:59:24 +01:00
Edward Firmo
e766b8ccb9 Lint 2024-01-05 09:46:38 +01:00
Edward Firmo
bba6eb2aa6 Lint 2024-01-05 09:37:12 +01:00
Edward Firmo
ad2edfd905 Markdown lint 2024-01-05 09:30:42 +01:00
Edward Firmo
716845bd0b Markdown lint 2024-01-05 09:28:10 +01:00
Edward Firmo
8e70389fc4 Update README.md 2024-01-05 09:23:44 +01:00
Edward Firmo
c08c133a15 Revert "Use yaml for rules"
This reverts commit 70e6a88638.
2024-01-05 09:17:49 +01:00
Edward Firmo
70e6a88638 Use yaml for rules 2024-01-05 09:16:41 +01:00
Edward Firmo
469a84492c Update .markdownlint.jsonc 2024-01-05 09:14:32 +01:00
Edward Firmo
099f530947 Update validate_markdown.yml 2024-01-05 09:09:28 +01:00
Edward Firmo
f6b400aafa Update validate_markdown.yml 2024-01-05 09:08:23 +01:00
Edward Firmo
dae5d5b574 Update link to config file 2024-01-05 09:04:26 +01:00
Edward Firmo
f0661f0a6c Update validate_markdown.yml 2024-01-05 08:57:12 +01:00
Edward Firmo
8f200fbd0a Update validate_markdown.yml 2024-01-05 08:39:18 +01:00
Edward Firmo
195105e1f6 Update validate_markdown.yml 2024-01-05 08:37:47 +01:00
Edward Firmo
0cc4c4fddb Update validate_markdown.yml 2024-01-05 08:36:23 +01:00
Edward Firmo
d099d45eae Update validate_markdown.yml 2024-01-05 08:32:04 +01:00
Edward Firmo
b5115df38e Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2024-01-05 08:26:07 +01:00
Edward Firmo
797698ed4f Update Markdown validations 2024-01-05 08:25:57 +01:00
Edward Firmo
0d4c2a012b Merge pull request #1537 from tikismoke/patch-1
DOC explain relay fallback mode
2024-01-05 07:49:44 +01:00
Edward Firmo
763693c2ca Validate markdown 2024-01-05 07:48:47 +01:00
Edward Firmo
bc6be10462 Update ReleaseNotes.md 2024-01-05 07:32:14 +01:00
Edward Firmo
cbb08dc747 A bit of rewording and adding reference to the issue
Solves #1349
2024-01-05 07:20:03 +01:00
tikismoke
c4c65ebf34 Update customization.md 2024-01-05 05:04:26 +01:00
Edward Firmo
622279c732 Update install.md 2024-01-05 02:44:00 +01:00
Edward Firmo
76738b6c61 Update install.md 2024-01-05 02:43:08 +01:00
Edward Firmo
173fb22fd7 Update install.md 2024-01-05 02:39:42 +01:00
Edward Firmo
8de24eafa1 Update install.md 2024-01-05 02:16:56 +01:00
Edward Firmo
d3388f2f01 Update install.md 2024-01-05 02:16:03 +01:00
Edward Firmo
4416605d85 That is not that important 2024-01-05 01:49:42 +01:00
Edward Firmo
f28f4b59d6 Replacing highlights with blockquotes 2024-01-05 01:47:51 +01:00
Edward Firmo
ded74c787f Migrating highlights to blockquotes 2024-01-05 01:39:23 +01:00
Edward Firmo
3916649e73 Update install.md 2024-01-05 01:21:04 +01:00
Edward Firmo
c293b3b2ec Update install.md 2024-01-05 01:20:05 +01:00
Edward Firmo
ca47631472 Updated intallation instructions (partial) 2024-01-05 00:53:09 +01:00
Edward Firmo
e19520e7df Update CJK fonts
Based on new fonts from #1532
2024-01-04 23:24:02 +01:00
Edward Firmo
37f2606aed Remove redundant refresh calls
Solves #1529
2024-01-04 23:02:48 +01:00
Edward Firmo
f77c7efbd6 Fix buttons positions on US Land models
Solves #1533
2024-01-04 21:49:15 +01:00
Edward Firmo
0cc3e4fe6d Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2024-01-04 21:36:02 +01:00
Edward Firmo
b620f543a2 Add charsets to the repo 2024-01-04 21:35:48 +01:00
Edward Firmo
32b29f140f Merge pull request #1532 from bluefoxlee/dev
Update CJK fonts and T.Chinese translation
2024-01-04 21:34:55 +01:00
bluefoxlee
0467fed532 Merge branch 'Blackymas:dev' into dev 2024-01-05 03:28:08 +08:00
Edward Firmo
24eb593a29 Update install.md 2024-01-04 20:27:54 +01:00
bluefoxlee
57e2106baa Update CJK fonts
- Add HKSCS most command characters (548)
- Add fullwidth punctuation marks
- Adjust font typeface/size
2024-01-05 03:27:21 +08:00
Edward Firmo
8cbe6181f1 Update install.md 2024-01-04 20:27:05 +01:00
bluefoxlee
d694867474 Update T.Chinese translation
Very minor update.
2024-01-05 03:21:14 +08:00
Edward Firmo
f178c45d16 Update install.md 2024-01-04 20:15:59 +01:00
Edward Firmo
348763d4d6 Update installation instructions
This still draft
2024-01-04 20:02:41 +01:00
Edward Firmo
9f4b571ddf Update buttons on climate page
Solves #1515
2024-01-04 15:40:53 +01:00
Edward Firmo
77a2ab7c46 Do not update climate entity when page home is refreshed
Solves #1530
2024-01-04 15:33:06 +01:00
Edward Firmo
fe124dfe9c Handles HVAC mode auto
Solves #1459
2024-01-04 10:58:19 +01:00
Edward Firmo
8f46a44cca Store TFT file to resist power cycle 2024-01-04 10:53:06 +01:00
Edward Firmo
7414d116fd New installation manual (draft) 2024-01-04 10:51:33 +01:00
Edward Firmo
602bc03d02 Change TFT selector's saving on power cycle 2024-01-04 02:50:29 +01:00
Edward Firmo
e0d821a7ed Prevent repeated report settings in a sequence 2024-01-04 01:35:19 +01:00
Edward Firmo
795e23aba6 Support single temperature when range is null
Solves #1510
2024-01-04 01:24:58 +01:00
Edward Firmo
4979fe856e Update nspanel_esphome_prebuilt.bin 2024-01-03 23:54:29 +01:00
Edward Firmo
beae026a0b Rebuilt nspanel_us files
Solves #1509
2024-01-03 23:52:40 +01:00
Edward Firmo
3ba64b6108 Add SSID to wifi change instructions
Solves #1476
2024-01-03 23:28:59 +01:00
Edward Firmo
ffa34d67bd Rebuilt nspanel_CJK_eu.hmi
Solves #1513
The TFT was also re-generated, but has no difference to the previous one.
2024-01-03 23:19:11 +01:00
Edward Firmo
5be3692ab6 Remember wake-up page after power cycle
Solves #1520
2024-01-03 23:10:22 +01:00
Edward Firmo
10eed8723e Refining release notes 2024-01-03 22:13:17 +01:00
Edward Firmo
1afbb79402 Update ReleaseNotes.md 2024-01-03 21:47:14 +01:00
Edward Firmo
289eb8e395 Fix links 2024-01-03 20:32:20 +01:00
Edward Firmo
30ed450a4f TFT upload selectors 2024-01-03 20:16:33 +01:00
Edward Firmo
00d8cc9c94 Publish prebuilt yaml 2024-01-03 00:11:49 +01:00
Edward Firmo
cb4edd2a0f Add instrutions to change Wi-Fi password
Solves #1177
Solves #1476
2024-01-02 22:42:11 +01:00
Edward Firmo
04ea3398f9 Create nspanel_esphome_prebuilt.bin 2024-01-02 17:27:02 +01:00
Edward Firmo
295ee0e81e Set correct brightness on sleep
Solves #1492
2024-01-02 16:35:39 +01:00
Edward Firmo
adca6a7039 Prepares for pre-build 2024-01-02 16:34:24 +01:00
Edward Firmo
9c755d453a Fix reference to custom buttons on climate page
Solves #1481
2024-01-02 15:41:41 +01:00
Edward Firmo
a1fa64fdfb Fix attribute name hvac_modes 2024-01-02 14:43:37 +01:00
Edward Firmo
522c8bb8cc Yamllint 2024-01-02 14:38:16 +01:00
Edward Firmo
4ab62f817d Fix supported features engine for climate 2024-01-02 14:37:42 +01:00
Edward Firmo
e98e2612bf Fix new component names on climate page 2024-01-02 14:37:05 +01:00
Edward Firmo
e45d07cfd7 Show heat_cool icon when dual climate add-on installed 2024-01-02 13:54:32 +01:00
Edward Firmo
07fda78fdc yamllint 2024-01-02 13:45:31 +01:00
Edward Firmo
64f4399382 Fallback to legacy upload tft
To support Lovelace UI tft installed
2024-01-02 13:39:59 +01:00
Edward Firmo
98fc65debd Improve clarity on changes to icons
Solves #1504
2024-01-02 12:38:15 +01:00
Edward Firmo
7cf66890fd Yamllint 2024-01-01 22:57:53 +01:00
Edward Firmo
e3509453cd Clean-up commented code 2024-01-01 22:55:10 +01:00
Edward Firmo
944f3bf221 Fix call to set_climate with new parameters 2024-01-01 22:48:13 +01:00
Edward Firmo
a89a54bbac Fix blueprint generating invalid automation 2024-01-01 22:16:40 +01:00
Edward Firmo
f09021d859 Dual target climate page
- Solves #909
- Partially solves #1486
- Solves #1481
- Solves #1459
- Solves #1006
- Solves #1106
2024-01-01 22:04:51 +01:00
Edward Firmo
35b0c23be8 Refresh pages when new settings comes 2023-12-31 22:00:16 +01:00
Edward Firmo
d32bf23ebe Screensaver time support %p not present
Solves #1492
2023-12-31 13:38:38 +01:00
Edward Firmo
e02ee95198 Rebuilt Upload TFT
Rebuilt again, now based on the ESPHome's Nextion component instead of local code.
Still not there yet, specially when Lovelace UI tft is installed, but hopefully this solves #1383 and solves #1491.
2023-12-30 01:59:51 +01:00
Edward Firmo
05ab9a8664 Reduces invalid_cooldown to 100ms
Solves #1479
2023-12-28 12:27:46 +01:00
Edward Firmo
33a0a34938 Reorg substitutions
Makes easier custom passwords.
2023-12-28 12:27:00 +01:00
Edward Firmo
00640bd360 Add queue_size to nextion_status 2023-12-28 12:14:20 +01:00
Edward Firmo
e361284c4c Add Nextion queue info to Watchdog logs 2023-12-28 11:32:44 +01:00
Edward Firmo
a49a8fc7ba Add substitution for invalid_cooldown
Solves #1479
2023-12-28 10:34:19 +01:00
Edward Firmo
501855e777 Custom buttons icon size
Solves #1480
2023-12-28 04:37:02 +01:00
Edward Firmo
ad08c45352 Translations - Korean
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1447#discussioncomment-7961280
2023-12-28 03:31:38 +01:00
Edward Firmo
d7d249308a Reboot with Wi-Fi timeout 2023-12-28 02:16:21 +01:00
Edward Firmo
a929d88dc4 Update translations - Korean
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1447#discussioncomment-7961236
2023-12-28 02:03:54 +01:00
Edward Firmo
faed4a9111 Added entities pages
Need the borders (panel) in the pictures
2023-12-28 00:13:06 +01:00
Edward Firmo
73fba3b449 Use climate defaults from HA 2023-12-27 23:03:45 +01:00
Edward Firmo
18abbaf506 Watchdog to log baud rate 2023-12-27 22:22:18 +01:00
Edward Firmo
7fb322d4d8 New baud rate selector 2023-12-27 19:36:58 +01:00
Edward Firmo
2528d3506e Baud rate as a select control 2023-12-27 18:39:55 +01:00
Edward Firmo
60a56aade2 Selectable baud rate 2023-12-27 18:38:27 +01:00
Edward Firmo
801fc83986 Removed lovelace_custom_command
It was not in use
2023-12-27 18:18:37 +01:00
Edward Firmo
27bdc3272b Fix string value is None for dictionary value @ data['code_format']
Potentially solves #1462
2023-12-27 18:08:46 +01:00
Edward Firmo
c15179b215 Improving watchdog 2023-12-27 17:52:24 +01:00
Edward Firmo
357572d401 Extend watchdog to add-ons 2023-12-27 14:26:47 +01:00
Edward Firmo
4ad5457b0f ESPHome Watchdog
This implements a watchdog script with complementing the scripts `on_setup` and `refresh_wifi_icon` to be checking the components every minute and taking proper actions (when possible).
Solves #1464
2023-12-27 13:57:16 +01:00
Edward Firmo
29fface258 Simplifies reboot calls 2023-12-26 01:55:18 +01:00
Edward Firmo
ee76e3bd87 Turn-off Nextion on shutdown 2023-12-24 17:05:47 +01:00
Edward Firmo
c5c04ae262 Bump version to 4.2dev.2 2023-12-23 00:30:40 +01:00
Edward Firmo
c708b37b76 Add universal icons to buttons 2023-12-23 00:21:56 +01:00
Edward Firmo
eef2053a23 Fix translations - French
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7930760
2023-12-22 21:49:40 +01:00
Edward Firmo
4621e73ec9 Icons are always forced 2023-12-22 21:19:41 +01:00
Edward Firmo
4b70d69397 Update fonts
Based on #1453
Helps with #1359
2023-12-22 21:14:53 +01:00
Edward Firmo
f251935ec6 Fix hw button indicator on Home page
Solves #1458
2023-12-22 20:11:47 +01:00
Edward Firmo
2dba0277f3 Fix harware buttons not working 2023-12-22 19:53:31 +01:00
Edward Firmo
bc2b9e8d04 Add icons for all domains
Solves #1461
2023-12-22 19:38:51 +01:00
Edward Firmo
c5155ceafa Merge pull request #1455 from Floppe/entlabels
Fix entity pages labels,
2023-12-22 15:38:45 +01:00
Edward Firmo
fa85b8129a Remove #DEBUG tag 2023-12-22 15:23:15 +01:00
Edward Firmo
0f94c3e3d3 Move fix to the shared code
So it applies globally
2023-12-22 15:22:01 +01:00
Edward Firmo
12d3ef937e Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-12-22 12:25:09 +01:00
Edward Firmo
666b1a2214 Comment out Lovelace UI commands
It was a nice UI, but wasn't helping with the TFT upload.
2023-12-22 12:25:02 +01:00
Edward Firmo
379dbfbed7 Merge pull request #1453 from bluefoxlee/dev
Update T.Chinese translation and Zi fonts.
2023-12-22 09:07:23 +01:00
Joachim Wickman
48c4cf9a89 Fix entity pages labels, was blank before. 2023-12-22 09:53:24 +02:00
bluefoxlee
8da2360798 Update Zi fonts 2023-12-22 08:47:42 +08:00
bluefoxlee
143b61bfe1 Update T.Chinese Translation 2023-12-22 08:38:58 +08:00
Edward Firmo
26d3d12236 Fix invalid reference to icon_color_rgb
Solves #963
2023-12-22 00:03:58 +01:00
Edward Firmo
2a0968e786 Fix num param update_msg 2023-12-21 23:59:16 +01:00
Edward Firmo
4f645903b2 Upload TFT improvements for Lovelace UI
Solve #1331
2023-12-21 21:41:53 +01:00
Edward Firmo
38489aa117 yamllint 2023-12-21 02:36:58 +01:00
Edward Firmo
e01b298e05 Translations to Japanese
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6002461
2023-12-21 02:23:08 +01:00
Edward Firmo
e8d41675ae Support to Korean
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6064294
2023-12-21 02:13:27 +01:00
Edward Firmo
3f5e75ab45 ESPHome min version 2023.12.0 2023-12-21 01:44:44 +01:00
Edward Firmo
096b932daa Remove DEBUG code 2023-12-20 21:13:38 +01:00
Edward Firmo
bf60bb50ae Increased meridiem length
Solves #1359
2023-12-20 21:08:56 +01:00
Edward Firmo
8569a1b85b Fix button bar position
Solves #1459
2023-12-20 20:59:52 +01:00
Edward Firmo
040477a8c3 Fix icons mapping
Solves #1359
2023-12-20 20:55:59 +01:00
Edward Firmo
ce0035cd76 Update instructions for Lovelace UI users
Solves #1331
2023-12-20 12:49:34 +01:00
Edward Firmo
af9e081643 Splitting global_settings service
Looks like ESPHome didn't like the service calls with so many parameters.
2023-12-20 11:33:16 +01:00
Edward Firmo
cfa16bc8e2 Display time on screensaver page
Solves #1065
Solves #1439
2023-12-20 09:48:10 +01:00
Edward Firmo
fd0edd28f6 Bump version to 4.2dev.1 2023-12-19 23:02:23 +01:00
Edward Firmo
f3dc79a66f Update derived TFT files 2023-12-19 22:55:24 +01:00
Edward Firmo
2646e89a25 Update zh-tw translations
https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1359#issuecomment-1863492589
2023-12-19 22:47:52 +01:00
Edward Firmo
65c3761ff8 Add text field to screensaver
Supports #1065
Supports #1439
2023-12-19 22:15:44 +01:00
Edward Firmo
ced41b50e3 Enhanced timeout flexibility for Sleep, Page fallback, and Dimming settings
Solves #1438
2023-12-19 21:42:48 +01:00
Edward Firmo
0164de9aaa Update ReleaseNotes.md 2023-12-19 16:29:35 +01:00
Edward Firmo
0210488fe9 yamllint 2023-12-19 16:21:46 +01:00
Edward Firmo
482fe16e75 Add meridiem to translations
Solves #1359
2023-12-19 16:19:37 +01:00
Edward Firmo
a7c5533121 Clean-up add-ons engine 2023-12-19 11:55:22 +01:00
Edward Firmo
3ff0c394ce Remove script.service_call_climate
To make things simpler
2023-12-19 10:55:27 +01:00
Edward Firmo
1b13be1eaa Sort scripts by name
To make it easier to find things
2023-12-19 10:49:17 +01:00
Edward Firmo
88a49b00e4 Use back_page_id on screensaver page
Let's simplify things!
2023-12-19 10:25:07 +01:00
Edward Firmo
052fc9551c Change back_page_id
Reduces a bit the memory in TFT
Simplify the process
Open space for more pages to be used
Not visible by users
2023-12-19 09:59:42 +01:00
Edward Firmo
32d969ed3e Renamed wifi component
To distinct from `wifi_default`
2023-12-19 02:57:27 +01:00
Edward Firmo
9f570eddd7 push-button--momentary-switch 2023-12-19 02:40:17 +01:00
Edward Firmo
a6466b3c75 Push button / Momentary switch 2023-12-19 02:38:43 +01:00
Edward Firmo
a2727e77f4 Update deep_sleep instructions
Based on changes introduced by esphome/esphome#5666
2023-12-19 02:28:02 +01:00
Edward Firmo
626550a082 Add upload blank tft button to advanced package 2023-12-19 02:23:43 +01:00
Edward Firmo
41a4be4bb5 Removing trailing spaces 2023-12-19 02:05:35 +01:00
Edward Firmo
7baff2c54c Add blueprint not detected icon on home page
Helps with #1436
2023-12-19 02:01:36 +01:00
Edward Firmo
647fe27bc0 Change mode on preset home 2023-12-18 23:25:12 +01:00
Edward Firmo
6e55c61032 Implements target_low and target_high substitutions
Solves #1418
2023-12-18 23:22:36 +01:00
Edward Firmo
5877af3493 Add climate dual to validations 2023-12-18 22:45:27 +01:00
Edward Firmo
346897ac94 Initial support to addon_climate_dual 2023-12-18 22:38:32 +01:00
Edward Firmo
e8e483a92a yamllint 2023-12-18 17:54:09 +01:00
Edward Firmo
9d68ecb5ab yamllint 2023-12-18 17:52:17 +01:00
Edward Firmo
a84c428ab8 yamllint 2023-12-18 17:48:45 +01:00
Edward Firmo
98d3a9189c yamllint 2023-12-18 17:42:45 +01:00
Edward Firmo
25567fa381 Alarm page cannot be used as wake-up page
Solves #1435
2023-12-18 16:02:29 +01:00
Edward Firmo
03f7315ab8 REmove alarm from wakeup list
With new support to multiple alarms, we don't know which one to open.
Solves #1435
2023-12-18 16:00:33 +01:00
Edward Firmo
540a27e7cc Forbidden very long lines 2023-12-18 15:44:15 +01:00
Edward Firmo
4f8a69d2e7 yamllint 2023-12-18 15:42:51 +01:00
Edward Firmo
75c9246c5e yamllint 2023-12-18 15:40:13 +01:00
Edward Firmo
83c641deef yamllint 2023-12-18 15:28:42 +01:00
Edward Firmo
286e98ecef yamllint 2023-12-18 15:16:00 +01:00
Edward Firmo
d432a88a8e yamllint 2023-12-18 15:08:49 +01:00
Edward Firmo
bbbbb6b967 Yamllint 2023-12-18 15:03:26 +01:00
Edward Firmo
ffd657db9f yamllint 2023-12-18 14:58:33 +01:00
Edward Firmo
aa56ae21d5 yamllint 2023-12-18 14:48:46 +01:00
Edward Firmo
d5ea5318e0 yamllint 2023-12-18 14:43:33 +01:00
Edward Firmo
1a4dbb2b55 yamllint 2023-12-18 14:37:05 +01:00
Edward Firmo
8204c40a05 yamlint 2023-12-18 14:34:45 +01:00
Edward Firmo
540227aff8 yamllint 2023-12-18 14:26:35 +01:00
Edward Firmo
98eacf5bf5 comments-indentation yamllint 2023-12-18 14:16:11 +01:00
Edward Firmo
a608348424 Use yamllint default
More strict rules
2023-12-18 14:14:30 +01:00
Edward Firmo
e812a4e738 Fix indentation on services 2023-12-18 13:56:35 +01:00
Edward Firmo
dda34e021c Advanced mode no longer enforces esp-idf 2023-12-18 13:40:50 +01:00
Edward Firmo
b086ccc16d Support to Fahrenheit with esp-idf 2023-12-18 13:21:19 +01:00
Edward Firmo
a1e488c72f yaml lint 2023-12-18 12:58:25 +01:00
Edward Firmo
0e8736586b yaml lint 2023-12-18 12:57:07 +01:00
Edward Firmo
773de2bd51 Support internal temperature in Fahrenheit 2023-12-18 12:44:16 +01:00
Edward Firmo
c97be551c0 Enhanced control for automation entities on buttons
Solves #1291
Solves #810
Solves #1249
Solves #1291
Solves #320
Solves #331
2023-12-18 12:11:57 +01:00
Edward Firmo
b38829ae32 Add swipe control to screensaver page
Solves #665
2023-12-18 03:59:17 +01:00
Edward Firmo
e45e848501 Chips can be inverted
Solves #1365
2023-12-18 03:28:19 +01:00
Edward Firmo
9bac2c1ca8 Added support to climate on the hardware buttons
Possibly solves #1295
2023-12-18 03:15:33 +01:00
Edward Firmo
9146147438 Home page chips now supports covers
Solves #932
2023-12-18 03:05:59 +01:00
Edward Firmo
68158d96a3 Add support to remote
Solves #1434
2023-12-18 02:59:30 +01:00
Edward Firmo
85febce168 Add support to remote
Solves #1434
2023-12-18 02:58:44 +01:00
Edward Firmo
07d5f63d7c Move hw button label assignment to boot sequence
Partially solves #1409
2023-12-18 00:26:23 +01:00
Edward Firmo
e9fcc39470 Replicate latest changes 2023-12-17 23:57:35 +01:00
Edward Firmo
a3b55e341f Stop timers before upload tft 2023-12-17 23:41:18 +01:00
Edward Firmo
5f1c289f5b Fix missing ; 2023-12-17 23:01:25 +01:00
Edward Firmo
b5c8069e21 Support to alarm entities everywhere
Solves #1109
2023-12-17 22:52:30 +01:00
Edward Firmo
278baa44f9 Home page chips support to alarm 2023-12-17 22:24:49 +01:00
Edward Firmo
eb28c98da9 Review breaking changes
For improved clarity
2023-12-17 22:05:57 +01:00
Edward Firmo
857cda0552 Jump to wakeup page if blueprint isn't responding
Solves #1432
2023-12-17 21:43:14 +01:00
Edward Firmo
5999a984ba Replace bt_alarm by custom button07
Solves #1109
2023-12-17 21:33:39 +01:00
Edward Firmo
d5c7f7dc4f Try a reset first 2023-12-17 17:59:21 +01:00
Edward Firmo
b7e4a46476 Move en-docs to docs folder 2023-12-17 17:57:12 +01:00
Edward Firmo
3483f4e411 Upload baud rate selectable as substitution
Solves #1430 (or the next time something similar is found).
2023-12-17 15:15:03 +01:00
Edward Firmo
5c0eb29f21 Move on_touch logs to VERBOSE 2023-12-17 12:50:38 +01:00
Edward Firmo
a2dc5913fa Move page constructors to TFT
To reduce comms between ESPHome and Nextion, which could help with some sync issues found with 921600 bps.
2023-12-17 12:44:12 +01:00
Edward Firmo
bd99afa14b change Nextion2Text to utf-8
Using this now: https://github.com/MMMZZZZ/Nextion2Text/issues/14#issuecomment-1688084921
2023-12-17 11:01:59 +01:00
Edward Firmo
1b14e70df0 Change char encoding to utf-8
From iso-8859-1
2023-12-17 08:32:21 +01:00
Edward Firmo
d6c9d97d08 Add exit_reparse_on_start
New feature from ESPHome 2023.12.0
2023-12-16 23:25:57 +01:00
Edward Firmo
975bbb08a1 Moved CJK TFT files to advanced folder
Still to be decided if this will be supported as a normal installation, as there's no documentation indicating this files and it can cause confusion.
2023-12-16 23:05:44 +01:00
Edward Firmo
b495fc75f0 Updating error_initializing.md
Solves #1256
2023-12-16 22:47:52 +01:00
Edward Firmo
8eaec1682e Update blueprint.md
Solves #1256
2023-12-16 21:35:13 +01:00
Edward Firmo
22ed24a058 Update blueprint.md 2023-12-16 21:31:46 +01:00
Edward Firmo
884bef9774 Standardize suggested yaml between docs
Supports #1256
2023-12-16 20:36:55 +01:00
Edward Firmo
a070626ee1 Support to Chinese (Taiwan) and prepared for other CJK languages
Adds to #1359
2023-12-16 20:21:17 +01:00
Edward Firmo
f644adbb1b Sets charset variable to CJK
Adds to #1359
2023-12-16 20:05:34 +01:00
Edward Firmo
f1cf3aa3f2 Creating CJK TFT files
Solves #1359
2023-12-16 20:02:51 +01:00
Edward Firmo
d29c6382f7 Home page values update with same engine as chips
Solves #963
2023-12-16 19:43:36 +01:00
Edward Firmo
17115e09cc Selectable icon size on button pages
Solves #960
2023-12-16 18:48:34 +01:00
Edward Firmo
c8d805e174 Add zh-tw to the language list
Solves #1413 (blueprint only)
2023-12-16 09:53:50 +01:00
Edward Firmo
54638c619c Remove touchevent sensor
It was replaced by new `on_touch` trigger from Nextion component
2023-12-16 08:41:58 +01:00
Edward Firmo
6239149ec6 Don't send None as friendly name 2023-12-16 00:57:08 +01:00
Edward Firmo
31ff6b4716 Add log on touch event 2023-12-16 00:28:42 +01:00
Edward Firmo
36cad5ee4c Send component ID on touch 2023-12-16 00:21:24 +01:00
Edward Firmo
dc305d210c New on_touch event from Nextion component 2023-12-16 00:17:38 +01:00
Edward Firmo
f445be86ab Target validations to ESPHome beta 2023-12-15 23:45:48 +01:00
Edward Firmo
15d5b4cf17 Log if display is detected 2023-12-15 23:42:38 +01:00
Edward Firmo
ee98aed55d Bump min ESPHome to 2023.12.0b1
To take advantage of Nextion component improvements.
2023-12-15 23:32:01 +01:00
Edward Firmo
07cff9da83 Store display charset on ESPHome
Supports #1359
2023-12-15 23:18:18 +01:00
Edward Firmo
0cbb0b248a Send charset info on boot
Supports #1359
2023-12-15 22:30:38 +01:00
Edward Firmo
a864feec10 Add CJK source files
Supports #1359
2023-12-15 22:15:03 +01:00
Edward Firmo
f81c170e2c Update Howto to new format 2023-12-15 21:57:35 +01:00
Edward Firmo
39670e378f Updated instructions for Upload TFT troubleshooting 2023-12-15 21:36:57 +01:00
Edward Firmo
6e3edc96ac Increase txt_maxl for entity pages
Preparing to support additional languages.
Solves #1419
2023-12-15 10:33:40 +01:00
Edward Firmo
983f3d86a7 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-12-15 10:04:30 +01:00
Edward Firmo
4a45b8966a Link to page boot 2023-12-15 10:04:18 +01:00
Edward Firmo
972dba5774 Remove deep_sleep test 2023-12-14 15:58:51 +01:00
Edward Firmo
ff46e167df Remove deep_sleep from customizations tests
Please look at https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/955#issuecomment-1855395411
Related to #955
2023-12-14 10:02:20 +01:00
Edward Firmo
12a119e20e Rearrange custom buttons on page Home
To be closer to what was before
2023-12-14 09:14:22 +01:00
Edward Firmo
671b1127ec Move DE docs to repo
These docs won't be maintained from now.
2023-12-11 23:34:01 +01:00
Edward Firmo
6c23adcf6c Moving docs to repo 2023-12-11 23:28:39 +01:00
Edward Firmo
eadedd1401 Default baud rate for advanced mode is back to 115200 bps 2023-12-11 17:36:01 +01:00
Edward Firmo
f282f0203f The Wi-Fi power save mode is back to "NONE" as default 2023-12-11 17:34:33 +01:00
Edward Firmo
dd014127df Add heap info to upload logs 2023-12-11 14:01:52 +01:00
Edward Firmo
0ef83e9ba8 Climate 2-setpoints preparation 2023-12-11 13:57:36 +01:00
Edward Firmo
77bd6addc4 Climate 2-setpoints preparation 2023-12-11 13:56:54 +01:00
Edward Firmo
970f65092a Update detailed page connected to home custom buttons
Solves #1394
2023-12-08 15:04:45 +01:00
Edward Firmo
d06a15f132 Trimming home page 2023-12-08 14:24:19 +01:00
Edward Firmo
2794bf3c6b Home page trimming 2023-12-08 13:24:22 +01:00
Edward Firmo
0fe251f881 Rebuilt US land from EU model 2023-12-08 13:16:10 +01:00
Edward Firmo
6bc57455ea Reorg home page EU models 2023-12-08 12:53:01 +01:00
Edward Firmo
74ed612c15 Changed to 6 custom buttons on home page 2023-12-08 11:42:13 +01:00
Edward Firmo
f480869992 Hard coded target_temperature step
#This is hard coded for now as ESPHome isn't supporting a substitution here. In contact with support.
2023-12-08 10:57:21 +01:00
Edward Firmo
022baa8727 Update README.md 2023-12-08 10:18:44 +01:00
Edward Firmo
6af9994c0c Delete CONTRIBUTING.md
It wasn't adding any value.
2023-12-08 09:57:12 +01:00
Edward Firmo
89e566c932 set current temperature precision to 0.1
Solves #1388
2023-12-08 09:20:45 +01:00
Edward Firmo
cf79e467b3 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-12-08 09:10:50 +01:00
Edward Firmo
db814c1ab0 Link to sorted milestones 2023-12-08 09:10:44 +01:00
Edward Firmo
1b3ccfb2db Use Milestones is substitution to Roadmap
Roadmap is too far ahead
2023-12-08 08:47:11 +01:00
Edward Firmo
4f0b3728cb Add screenshot 2023-12-08 03:20:35 +01:00
Edward Firmo
83972256ed Outdoor temperature selectable font size 2023-12-08 03:18:48 +01:00
Edward Firmo
336698cb72 Additional custom button on Home page
Solves #1257
2023-12-08 02:13:55 +01:00
Edward Firmo
ceb669dfc8 Implements Update TFT display URL select
To make it easier to update new displays.
2023-12-07 15:44:14 +01:00
Edward Firmo
588de3bc03 Bump ESPHome minimum required version to 2023.11
Solves #1395
2023-12-07 14:59:20 +01:00
Edward Firmo
cd34f1885c Remove trailing spaces 2023-12-07 08:49:12 +01:00
Edward Firmo
61d061d69e Fix file reference on validation 2023-12-07 08:47:07 +01:00
Edward Firmo
07304a2dcc Don't use not released features 2023-12-07 08:15:12 +01:00
Edward Firmo
ae6ad884f7 Repo reorg 2023-12-07 08:12:38 +01:00
Edward Firmo
65408e3a44 Repo reorg 2023-12-07 07:42:01 +01:00
Edward Firmo
5780b7208a Remove reference to DEV component 2023-12-07 07:26:17 +01:00
Edward Firmo
8541b221ad Merge pull request #1392 from Blackymas/beta
Merge latest changes into DEV
2023-12-07 01:45:49 +01:00
Edward Firmo
a94d3a19c8 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into beta 2023-12-07 01:37:57 +01:00
Edward Firmo
c94a8d5f9a Additional UI log 2023-12-07 01:18:30 +01:00
Edward Firmo
34d9432651 Code clean-up 2023-12-07 00:57:03 +01:00
Edward Firmo
be1c8a264e Do not test IDF v5 2023-12-05 18:08:01 +01:00
Edward Firmo
f6d8d069cc Upload TFT UI on the panel 2023-12-05 18:06:55 +01:00
Edward Firmo
2909ce6cc8 Upload TFT UI on panel 2023-12-05 18:03:34 +01:00
Edward Firmo
ba6f0264a6 This file will be moved to advanced folder soon
To avoid a breaking change
2023-12-05 17:14:49 +01:00
Edward Firmo
15e1976715 Remove extra line 2023-12-05 17:10:59 +01:00
Edward Firmo
88bb6ff176 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into beta 2023-12-05 16:59:01 +01:00
Edward Firmo
cbdc47170f TFT Upload routine clean-up
Solves #1378
Solves #1383
2023-12-05 16:58:54 +01:00
Edward Firmo
5cb2a193c6 Fix file path 2023-12-04 23:15:11 +01:00
Edward Firmo
cf4d0f9393 Try update at 921600bps first 2023-12-04 22:49:44 +01:00
Edward Firmo
a0a17bcfa1 Shortening boot sequence a bit
As baud rate wouldn't change anymore
2023-12-04 22:45:42 +01:00
Edward Firmo
ae40f651be Set advanced baud rate to 115200
Users reported issues on #1358
2023-12-04 22:38:25 +01:00
Edward Firmo
3df926cfc1 Fix path 2023-12-04 22:35:39 +01:00
Edward Firmo
304233218a Fix relative path on workflows 2023-12-04 22:33:21 +01:00
Edward Firmo
642c680cae Fix test relative folders 2023-12-04 22:24:01 +01:00
Edward Firmo
da4b64ed95 Reorg files
To make it easier for users
2023-12-04 22:19:03 +01:00
Edward Firmo
0565f5f522 Redistribute tree 2023-12-04 18:52:02 +01:00
Edward Firmo
7d5b2b8d30 Remove manual line break from page's title
Solves #1367
2023-12-04 16:19:25 +01:00
Edward Firmo
019a882fe9 Bump version to 4.1.4 2023-12-04 16:05:26 +01:00
Edward Firmo
978df5ad75 Merge pull request #1375 from Blackymas/beta
Align branchs
2023-12-04 14:27:31 +01:00
Edward Firmo
02b94979b3 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into beta 2023-12-04 13:36:49 +01:00
Edward Firmo
c1a513610b Manual line break on multiline text with \r
Solves #1367
2023-12-04 09:30:18 +01:00
Edward Firmo
961b2c3f4d Supports new weather.get_forecasts
Solves #1377
2023-12-04 09:07:54 +01:00
Edward Firmo
bdd1726328 Merge pull request #1372 from Blackymas/beta
v4.1.3 - Bug fixing
2023-12-03 17:06:24 +01:00
Edward Firmo
f37ae5b1ce Fix climate page not updating properly 2023-12-03 16:24:12 +01:00
Edward Firmo
6a957a9099 Fix climate page not updating properly
Fixes #1284
Probably fixes #1351
2023-12-03 16:19:53 +01:00
Edward Firmo
f7de15d369 Remove tft_url reference
This is not available until ESPHome 2023.12
Partially covers issue #1330
2023-12-03 15:31:35 +01:00
Edward Firmo
b5ca2c8b60 Fix light icon color on buttons 2023-12-03 15:29:06 +01:00
Edward Firmo
4be2a84315 Fix light icon color on buttons
Solves #1356
2023-12-03 13:41:00 +01:00
Edward Firmo
647c56920e IDF v5 compatibility 2023-12-03 13:26:44 +01:00
Edward Firmo
f1c5ae505e Change temperature correction mode to box
To make it easier to adjust.
Improves #1369
2023-12-01 15:19:08 +01:00
Edward Firmo
6f857e6077 Don't show thermostat chip when auto
Solves #1265
2023-12-01 10:07:05 +01:00
Edward Firmo
b975869e1f Change baud rate manually 2023-11-30 21:46:00 +01:00
Edward Firmo
29e0e4b8ce Stop all when uploading tft 2023-11-30 21:44:43 +01:00
Edward Firmo
2c4a366d7b Change baud rate on click
Click on the baud rate info to switch between 115200 and 921600bps
2023-11-30 20:06:55 +01:00
Edward Firmo
cc10cfe0c5 Keep baud rate after connection 2023-11-30 20:02:58 +01:00
Edward Firmo
98187fe4a4 Clean-up code 2023-11-30 19:50:57 +01:00
Edward Firmo
19e4e9d5b6 Turn on screen after turn off 2023-11-30 14:11:36 +01:00
Edward Firmo
72ab301a2a Publish Nextion is off during upload TFT 2023-11-30 13:05:16 +01:00
Edward Firmo
67706293d3 Remove test blank button 2023-11-30 12:52:19 +01:00
Edward Firmo
99616d4e79 Don't exit reparse if is setup 2023-11-30 11:38:39 +01:00
Edward Firmo
bc677e6c21 Drop support to idf v5 2023-11-30 11:17:26 +01:00
Edward Firmo
309da77301 Don't use exit reparse from component 2023-11-30 09:22:10 +01:00
Edward Firmo
849e75bb6c Upload TFT remove dependency to from ESPHome Nextion component
Let's wait for those to be released before start using it.
2023-11-30 07:56:15 +01:00
Edward Firmo
9de99bcca2 Give Nextion more time at boot 2023-11-30 07:11:04 +01:00
Edward Firmo
7caac2e62c Don't update button if page changed
Solves #1358

It might be a bit slower to change between button pages now, as the blueprint checks for the page before sending to ESPHome and this one also checks before sending to Nextion, but it reduces a lot the chances of `Nextion reported variable name invalid!` and broken buttons on quick page changes.
2023-11-29 16:25:42 +01:00
Edward Firmo
1126fa03b4 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-11-28 23:26:04 +01:00
Edward Firmo
8469c5e6da Update nspanel_blueprint.yaml 2023-11-28 23:25:44 +01:00
Edward Firmo
5e9abec9dd Merge pull request #1355 from sylvinus/patch-1
Fix small typo in nspanel_blueprint.yaml
2023-11-28 22:45:15 +01:00
Edward Firmo
2b9283b336 Merge branch 'dev' into patch-1 2023-11-28 21:17:04 +01:00
Sylvain Zimmer
90a073bb39 Fix small typo in nspanel_blueprint.yaml 2023-11-28 20:35:49 +01:00
Edward Firmo
f357a58b9e Merge pull request #1347 from Blackymas/beta
v4.1.2 - Bug fixes and small enhancements
2023-11-28 16:54:05 +01:00
Edward Firmo
55f254e7a2 Revert "Remove esp-idf"
This reverts commit 58d86aeb86.
2023-11-28 16:09:39 +01:00
Edward Firmo
58d86aeb86 Remove esp-idf 2023-11-28 15:32:13 +01:00
Edward Firmo
53b3d131b6 Removed support to IDF 2023-11-28 15:29:42 +01:00
Edward Firmo
ec35a07f52 Fix call to older upload_tft() 2023-11-28 14:46:16 +01:00
Edward Firmo
d81a15195b Fix Nextion not communicating with ESPHome 2023.11.6 2023-11-28 14:42:19 +01:00
Edward Firmo
58cffafefc Remove is_detected 2023-11-28 14:36:36 +01:00
Edward Firmo
58b82b8a30 Remove reference to PR5683 2023-11-28 14:35:16 +01:00
Edward Firmo
629bf0aad1 Replace page announcement
Using "sendme" in replace to text sensor "currentpage".
2023-11-27 20:34:40 +01:00
Edward Firmo
a60ad3abd3 Fix display as a light
As per #1348
2023-11-27 19:05:36 +01:00
Edward Firmo
66c80a490b Icons standardization 2023-11-27 17:14:30 +01:00
Edward Firmo
657512a470 Bump version to 4.1.3dev 2023-11-27 16:23:23 +01:00
Edward Firmo
239406053f New entity anchor 2023-11-27 16:21:39 +01:00
Edward Firmo
93050ae34b Validate beta only on demand
To reduce number of unnecessary runs (when no beta is available)
2023-11-27 11:15:36 +01:00
Edward Firmo
da357eed7a Merge pull request #1342 from Blackymas/dev
v4.1.2 beta
2023-11-27 10:54:11 +01:00
Edward Firmo
ee50d69f03 custom buttons icons not updating on Home page 2023-11-27 10:15:53 +01:00
Edward Firmo
06f145a11c Fix custom buttons not updating
Solves #1343
2023-11-26 17:53:32 +01:00
Edward Firmo
819ba1fe04 Bump version to 4.1.2 2023-11-26 14:58:17 +01:00
Edward Firmo
4965c4ce59 Fallback to legacy forecast (attributes based) when new method (service based) fails. 2023-11-26 10:55:41 +01:00
Edward Firmo
adf356ae33 Fallback to old forecast model when new fails
Solves #1259
Solves #1335
2023-11-26 10:38:53 +01:00
Edward Firmo
c4543a73af Send component ID on page home
This will be used later with new touch detection routine
2023-11-26 10:32:01 +01:00
Edward Firmo
5f688a6949 Don't show thermostat chip when state is auto and no action is available 2023-11-26 10:03:59 +01:00
Edward Firmo
d93199968d Change chip color when "auto" 2023-11-26 09:55:54 +01:00
Edward Firmo
c7f9fb09a0 Don't show thermostat chip when auto
Solves #1265
2023-11-26 09:37:32 +01:00
Edward Firmo
20e8694566 Code clean-up 2023-11-26 08:42:47 +01:00
Edward Firmo
60b14d5315 add page_names array 2023-11-25 17:49:22 +01:00
Edward Firmo
48c5453f0a Add compatibility to IDF v5 2023-11-25 17:30:10 +01:00
Edward Firmo
8f3fc8c081 Merge pull request #1334 from bkbartk/dev
Update ReleaseNotes.md
2023-11-24 21:47:40 +01:00
Edward Firmo
578c38c418 Update ReleaseNotes.md 2023-11-24 21:47:13 +01:00
bkbartk
cb945041be Update ReleaseNotes.md 2023-11-24 21:25:52 +01:00
Edward Firmo
4096c1cf67 Merge pull request #1333 from bkbartk/dev
fix button picture fallback
2023-11-24 21:19:36 +01:00
bkbartk
0ecc8ac016 fix button picture fallback
when localfallback is enabled,
and the switch is turned off
relay_1-> state = off(false)
so the action won't be applied and it takes a second for the HA automation to update the icon.

so this check should not be here, it should only for fallback and then choose 1/0 based on the state.

remark(I cannot test off to on atm as my custom change then opens the detail page, but I have no reason to think this won't work)
2023-11-24 21:13:23 +01:00
Edward Firmo
0a3b201ee7 Merge pull request #1327 from bkbartk/dev
make screen power available in HA
2023-11-24 20:49:22 +01:00
Edward Firmo
0584b07275 Remove unnecessary code 2023-11-24 18:39:35 +01:00
Edward Firmo
dc6bc5d04f Revert back comments 2023-11-24 18:35:35 +01:00
Edward Firmo
8b5d7bfb05 Move "Nextion display - Power" to Diagnostic and disabled 2023-11-24 18:33:55 +01:00
Edward Firmo
18078ca1c0 Rename switch to "Nextion display - Power" 2023-11-24 18:33:09 +01:00
Edward Firmo
feacca7391 Wait for display setup when turning on 2023-11-24 18:22:03 +01:00
Edward Firmo
c6141b97f6 Set display not available when power off 2023-11-24 17:24:59 +01:00
Edward Firmo
be37fc3941 New switch "Screen Power" 2023-11-24 17:23:09 +01:00
bkbartk
3f9f0c00de make screen power available
sorry,

I'm stubborn, but I sometimes prefer this over the 15 sec press
2023-11-24 09:08:00 +01:00
Edward Firmo
fc4ff29533 Fix description for climate custom buttons
Solves #1267
2023-11-23 19:18:42 +01:00
Edward Firmo
12d5d88204 Add ppt with screenshots 2023-11-23 19:17:47 +01:00
Edward Firmo
47927abc8e Climate custom preset
Solves #1286
2023-11-23 16:42:59 +01:00
Edward Firmo
a34992c61e Fix calls to climate control 2023-11-23 15:29:30 +01:00
Edward Firmo
a0bc982d69 Fix scheduler conflict 2023-11-23 14:24:14 +01:00
Edward Firmo
7dcce35087 Resize pics 2023-11-23 14:16:54 +01:00
Edward Firmo
16d2906ff6 Added new screen shots with panel's frame 2023-11-23 13:52:18 +01:00
Edward Firmo
dba0aa2ee2 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-11-23 11:45:12 +01:00
Edward Firmo
c9947bc42c Create manuals_screenshots.md 2023-11-23 11:45:02 +01:00
Edward Firmo
3db5b990ce Update page settings
Solves #1322
2023-11-23 11:44:53 +01:00
Edward Firmo
04057654f9 Use ip for sntp server 2023-11-23 10:04:54 +01:00
Edward Firmo
960157cace Remove fast_connect from test 2023-11-23 09:15:10 +01:00
Edward Firmo
ec3024d132 Use a valid encryption key 2023-11-22 23:53:53 +01:00
Edward Firmo
bddfe706de Add dummy secrets file for testing 2023-11-22 23:32:47 +01:00
Edward Firmo
0199e867a8 Call the device as "panel" on inputs
To improve clarity.
Solves #1296
2023-11-22 23:11:57 +01:00
Edward Firmo
786f7795ed Close Notification page when cleared 2023-11-22 21:12:27 +01:00
Edward Firmo
9ff6e42e8e Add option to wake-up to Climate page
Solves #1321
2023-11-22 21:08:05 +01:00
Edward Firmo
0bdbb6e736 Add customizations to tests 2023-11-22 20:55:55 +01:00
Edward Firmo
6dcf47f4db Fix light icon color not being used for buttons
Solves #1317
2023-11-22 20:34:23 +01:00
Edward Firmo
b259b34768 Current temperature, not target
Solves #1298
2023-11-18 00:58:58 +01:00
Edward Firmo
a1d0343352 Merge pull request #1292 from Blackymas/beta
v4.1.1: UI Enhancements and Reintroduction of `play_rtttl` Service
2023-11-17 10:09:03 +01:00
Edward Firmo
88d047201e Merge pull request #1290 from Blackymas/dev
v4.1.1 beta
2023-11-17 08:14:48 +01:00
Edward Firmo
37e7ff8498 Bump TFT version to 4.1.1 2023-11-17 08:05:29 +01:00
Edward Firmo
67d8d941ba Merge pull request #1276 from bkbartk/dev 2023-11-15 20:29:54 +01:00
bkbartk
17b11937c3 Icons on homePAge 2023-11-15 20:08:00 +01:00
Edward Firmo
5184ed6ccb PR file specific 2023-11-15 05:02:59 +01:00
Edward Firmo
8e9c536b7c PR file specific 2023-11-15 05:01:43 +01:00
Edward Firmo
f0a684d7e1 PR file specific 2023-11-15 05:00:02 +01:00
Edward Firmo
2bfb7c7aab PR file specific 2023-11-15 04:58:46 +01:00
Edward Firmo
cbbc24636c No runs with PRs 2023-11-15 04:54:15 +01:00
Edward Firmo
118e6874cd No runs with PRs 2023-11-15 04:53:39 +01:00
Edward Firmo
543005bd37 No runs with PRs 2023-11-15 04:52:49 +01:00
Edward Firmo
ce68bb730e Merge pull request #1269 from bkbartk/dev
Dev
2023-11-15 04:50:12 +01:00
bkbartk
78aa2ee84b icons on overviewpages 2023-11-14 20:47:31 +00:00
Edward Firmo
f349f19550 Merge pull request #1268 from bkbartk/dev
climate fix
2023-11-14 21:37:29 +01:00
Edward Firmo
f9ff2edcd6 Display target temperature on buttons even when climate is off 2023-11-14 20:41:24 +01:00
Edward Firmo
9268961556 Bump version to 4.1.1 2023-11-14 20:31:51 +01:00
bkbartk
5e5c1726ed climate fix 2023-11-14 19:17:13 +00:00
Edward Firmo
7bf9e333c5 v4.1.1 patch
v4.1.1 patch
2023-11-14 07:58:29 +01:00
Edward Firmo
2656b1709e Merge branch 'beta' into dev 2023-11-14 07:44:25 +01:00
Edward Firmo
36d1ea7a05 Stop fallback to Home when Notification or Confirm shown 2023-11-14 07:41:08 +01:00
Edward Firmo
6025da2850 Stop fallback to Home when notification is shown
Solves #1261
2023-11-14 07:38:46 +01:00
Edward Firmo
bd14d7aa42 Bump version to 4.1.1 2023-11-14 07:28:37 +01:00
Edward Firmo
84edfcb8ea Add esphome.xxxxx_play_rtttl back to core
Solves #1262
2023-11-14 07:26:34 +01:00
Edward Firmo
bf96235054 Update README.md 2023-11-14 07:12:25 +01:00
Edward Firmo
0578c961a1 Update README.md 2023-11-14 07:10:00 +01:00
Edward Firmo
61a62ba452 Merge pull request #1254 from Blackymas/beta
v4.1 release
2023-11-12 16:28:35 +01:00
Edward Firmo
86a35de57c Remove build tests on beta environment 2023-11-12 10:00:40 +01:00
Edward Firmo
528c0814fb Bump version to 4.1
Ready for release
2023-11-12 10:00:40 +01:00
Edward Firmo
848db89b1a No need to reload PR every time 2023-11-12 10:00:40 +01:00
Edward Firmo
1f5a7c3a5f Fix naming 2023-11-12 10:00:40 +01:00
Edward Firmo
45a8f7f61e Add tests on ESPHome beta (temporarily) 2023-11-12 10:00:40 +01:00
Edward Firmo
e2f8a62f44 Remove references to bluetooth
It isn't stable enough.
2023-11-12 10:00:40 +01:00
Edward Firmo
9e24d2d4db Reorg things 2023-11-12 10:00:40 +01:00
Edward Firmo
c93f32837d Don't run on push 2023-11-12 10:00:40 +01:00
Edward Firmo
42db0b8502 Trigger on push 2023-11-12 10:00:40 +01:00
Edward Firmo
7d2fde6e03 Add scheduled 2023-11-12 10:00:40 +01:00
Edward Firmo
7d73841907 Create validate_esphome_beta.yml 2023-11-12 10:00:40 +01:00
Edward Firmo
e68d542ad2 Remove build tests on beta environment 2023-11-12 09:53:56 +01:00
Edward Firmo
bab945b242 Bump version to 4.1
Ready for release
2023-11-12 09:35:36 +01:00
Edward Firmo
7cac47d279 No need to reload PR every time 2023-11-12 08:15:42 +01:00
Edward Firmo
b9e23bf855 Fix naming 2023-11-12 07:42:28 +01:00
Edward Firmo
a0f749d4ab Add tests on ESPHome beta (temporarily) 2023-11-12 07:40:43 +01:00
Edward Firmo
a466d04810 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-11-12 07:27:49 +01:00
Edward Firmo
42ef838819 Remove references to bluetooth
It isn't stable enough.
2023-11-12 07:23:01 +01:00
Edward Firmo
7f9fd4c819 Reorg things 2023-11-11 23:48:40 +01:00
Edward Firmo
06ac511ae6 Don't run on push 2023-11-11 14:45:46 +01:00
Edward Firmo
d6cc901937 Trigger on push 2023-11-11 14:28:04 +01:00
Edward Firmo
40282b2e14 Add scheduled 2023-11-11 14:21:10 +01:00
Edward Firmo
55b9b9728b Create validate_esphome_beta.yml 2023-11-11 14:14:55 +01:00
Edward Firmo
d549f79aba Merge pull request #1250 from Blackymas/dev
v4.1b1
2023-11-11 11:59:49 +01:00
Edward Firmo
cef5191233 v4.1 - Easier TFT transfer 2023-11-11 11:39:22 +01:00
Edward Firmo
ba2df603c3 Bump version to 4.1b1
For beta testing
2023-11-11 11:24:09 +01:00
Edward Firmo
6f4ef58d2b Button to trigger automation
Changing behavior on button for automation from enabling/disabling to trigger the automation.
Solves #1249
2023-11-11 11:19:25 +01:00
Edward Firmo
7b4f6ac9f0 Remove old Upload TFT code
It was not in use
2023-11-11 10:20:51 +01:00
Edward Firmo
c8cf7b8046 Change parameter of display_wrapped_text
To add compatibility to ESPHome 2023.11

Solves #1247
2023-11-11 10:19:04 +01:00
Edward Firmo
035ebd64dc change notification_show parameter to message
For compatibility with ESPHome 2023.11.

Solves #1247
2023-11-11 10:13:17 +01:00
Edward Firmo
1857be65c2 Review on_boot script 2023-11-10 18:55:20 +01:00
Edward Firmo
69a13a9745 Hide brightness when button is off
Solves #1246
2023-11-10 18:52:57 +01:00
Edward Firmo
25efb93877 Removed service upload_tft
Please use this instead:
```yaml
service: esphome.xxxxx_upload_tft_url
data:
  url: "default"
```
2023-11-10 14:21:56 +01:00
Edward Firmo
889aa4fd43 Handle boot with blank tft 2023-11-10 12:30:43 +01:00
Edward Firmo
eb3a643f76 New blank tft 2023-11-10 12:05:59 +01:00
Edward Firmo
da37740ef3 Change baud_rate without restart 2023-11-10 11:31:08 +01:00
Edward Firmo
9d06a7f55a Set UART to 921600 bps 2023-11-10 10:44:29 +01:00
Edward Firmo
649c891881 Remove service show_all
To clean-up a bit the list of services.
2023-11-10 09:48:27 +01:00
Edward Firmo
860cc815fb Support for snowy-rainy from Met.no
Fixes #1245
2023-11-10 09:27:14 +01:00
Edward Firmo
e03922ef13 Button - Light - Icon follows the light rgb color
- Helps with #1184
- Helps with #935
2023-11-10 07:24:40 +01:00
Edward Firmo
ea89da4cc6 Show decimal case on button climate 2023-11-10 07:02:58 +01:00
Edward Firmo
3c3542c7d0 Add esp-idf to advanced package 2023-11-10 06:42:55 +01:00
Edward Firmo
0299014ca1 Short click to open Climate and Media Player 2023-11-10 06:38:21 +01:00
Edward Firmo
f209be7487 Home - Custom buttons - Update only when needed
Solves #1244
2023-11-09 23:49:03 +01:00
Edward Firmo
a8199ee756 Show all buttons for Music Assistant player group
Solves #1232
Solves #1221
2023-11-09 22:39:02 +01:00
Edward Firmo
dab2bb9c55 Selectable chips size 2023-11-09 21:15:48 +01:00
Edward Firmo
732109ed1f Crop image for back buttons
Helps with #1134
2023-11-09 19:49:00 +01:00
Edward Firmo
ad34c51d9d support to weather forecast service
Solves #1050
2023-11-09 19:35:05 +01:00
Edward Firmo
2616e4d5d1 Disable logger via UART
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1240#discussion-5829722
2023-11-09 16:56:33 +01:00
Edward Firmo
e4e4c3f468 Sort components 2023-11-09 15:53:41 +01:00
Edward Firmo
a59ff2495c Transparent icons & text
Makes icons and text transparent when possible.
This helps with #1134
2023-11-09 15:50:12 +01:00
Edward Firmo
63903f6d1c Buttons with Media Player or Climate will always open detailed page
There's no toggle for those entities.

Solves #1220
2023-11-09 12:58:19 +01:00
Edward Firmo
d2f4e01d30 Show alarm state even when action is not supported
There are "read only" alarms with 0 as supported features but users still wanna see the current state.

Probably solves #1146
2023-11-09 10:56:51 +01:00
Edward Firmo
d7a0aa0c04 Split service global_settings
Could be that IDF framework limits the parameters of a service in some way? To be investigated.

Hopefully this solves #1243
2023-11-09 10:29:22 +01:00
Edward Firmo
0db04942d6 Fix update of detailed page when other entity got updated
- Solves #1225
- Solves #1235
- Solves #1242
2023-11-09 09:59:02 +01:00
Edward Firmo
44ab4adc43 Revert calls to color
This is break compatibility with IDF v5.
2023-11-09 01:01:59 +01:00
Edward Firmo
e439953fdb Fix parameter name on send_command_value 2023-11-08 23:44:53 +01:00
Edward Firmo
dbc61f9ecb Use new Upload TFT for Arduino 2023-11-08 13:32:56 +01:00
Edward Firmo
6ecf19e935 Roll back embedded color565 2023-11-07 21:56:25 +01:00
Edward Firmo
c56f482516 User embedded color565 conversion 2023-11-07 21:51:41 +01:00
Edward Firmo
65f33e40d5 New sensor detailed_entity_id 2023-11-07 21:45:32 +01:00
Edward Firmo
0660ef0228 Fix string comparison 2023-11-07 21:43:34 +01:00
Edward Firmo
137539e85c Fix publish_state for new sensor 2023-11-07 21:42:26 +01:00
Edward Firmo
f0394bb5bc Ad sensor detailed_entity_id 2023-11-07 21:39:44 +01:00
Edward Firmo
bc93bc523f Change send_command_value params 2023-11-07 21:23:28 +01:00
Edward Firmo
85ca25069d Code clean-up 2023-11-07 16:10:30 +01:00
Edward Firmo
24d2ff71b2 web_server replaced by json
It takes less memory and provides the libraries needed for this project.
2023-11-07 14:15:47 +01:00
Edward Firmo
c838216c1f Fix for esp-idf types 2023-11-07 13:10:34 +01:00
Edward Firmo
eb03d33edd Support to idf v5 2023-11-07 12:35:06 +01:00
Edward Firmo
3dea13c354 Add test for idf v5 2023-11-07 09:28:28 +01:00
Edward Firmo
e9ba75b967 Add test for idf v5 2023-11-07 09:26:38 +01:00
Edward Firmo
9d32e0d027 Delay to send brightness to ESPHome
Solves #1229
2023-11-06 21:04:37 +01:00
Edward Firmo
31560787e3 Default code_arm_required is true
A per default: https://developers.home-assistant.io/docs/core/entity/alarm-control-panel/

Solves #1193
2023-11-06 20:38:53 +01:00
Edward Firmo
6b9a6dc97f Add framework info to TFT 2023-11-06 20:33:13 +01:00
Edward Firmo
5060947d16 Change idf validation to climate cool 2023-11-06 08:58:38 +01:00
Edward Firmo
e434667ad3 Fix link to idf file 2023-11-06 08:49:53 +01:00
Edward Firmo
e3a6368efa Improved name of esp-idf & bluetooth test 2023-11-06 08:21:47 +01:00
Edward Firmo
f85f87f3e6 Add bluetooth proxy to esp-idf test 2023-11-06 08:19:58 +01:00
Edward Firmo
ce814af3d3 Change framework back to default
As users should flash with serial to change framework
2023-11-06 08:16:45 +01:00
Edward Firmo
039e5e56b7 Add "Actions" 2023-11-06 01:00:12 +01:00
Edward Firmo
b679693203 Clean up names 2023-11-06 00:35:11 +01:00
Edward Firmo
c45ce32742 Allows change to the baud rate 2023-11-06 00:28:24 +01:00
Edward Firmo
8f128ac6b5 Wait for TFT version on boot sequence
This should be reviewed after https://github.com/esphome/esphome/pull/5673 is released.
2023-11-05 20:16:10 +01:00
Edward Firmo
8184ada7a1 Improved boot sequence
Restart with hw button 10s hold - Helps with #1224
Restart Nextion if not connected to ESPHome after 30s - Helps with #1224
Prepare for future support to 921600bps
2023-11-05 09:32:22 +01:00
Edward Firmo
0a26861444 Code clean-up 2023-11-03 21:10:42 +01:00
Edward Firmo
fdc8b81fd0 Exit reparse on boot 2023-11-03 19:40:57 +01:00
Edward Firmo
94db496d30 Bring back exit reparse button
Tests failed
2023-11-03 18:12:40 +01:00
Edward Firmo
5a782bbe45 Retry when Upload TFT fails 2023-11-03 18:05:43 +01:00
Edward Firmo
a80a2b7985 Add checkout to each action 2023-11-03 17:48:28 +01:00
Edward Firmo
53e4dd7b81 Fix dependencies on build_advanced 2023-11-03 17:45:35 +01:00
Edward Firmo
955a7fbd8b Remove "Exit reparse" button
It's functionality is now embedded in the Upload TFT calls.
2023-11-03 17:43:06 +01:00
Edward Firmo
9fa172ef36 Advanced validation of ESPHome 2023-11-03 17:40:43 +01:00
Edward Firmo
ffce653d16 Fix reference to external components 2023-11-03 17:14:20 +01:00
Edward Firmo
852ba63038 Use pr5667 for Nextion 2023-11-03 15:26:00 +01:00
Edward Firmo
58132cb189 Fix reference to tft_size_
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1213#issuecomment-1791035711
2023-11-02 17:55:42 +01:00
Edward Firmo
e96329f976 Handle https error nicely 2023-11-02 12:03:16 +01:00
Edward Firmo
88cf4af2a7 Add validation with arduino framework
Just to make sure we don't break support to that framework, as we might want to migrate back in the future or some user might wanna use that.
2023-11-01 22:03:21 +01:00
Edward Firmo
fce2c5e4be Set framework esp-idf by default 2023-11-01 21:29:06 +01:00
Edward Firmo
b105d83b12 Persistent http client 2023-11-01 21:22:58 +01:00
Edward Firmo
25cf9f1bb9 Update nspanel_esphome_addon_upload_tft.yaml 2023-11-01 13:31:41 +01:00
Edward Firmo
88f287aa0d Upload TFT ESP-IDF - Cleaning logs 2023-11-01 10:04:42 +01:00
Edward Firmo
34142c510f Upload TFT for ESP-IDF
Still pending some clean-up, but I would say this is a working version.
2023-11-01 09:35:51 +01:00
Edward Firmo
4701885a59 Increase QRcode length to 75 chars
Solves #1210
Solves #303
2023-11-01 08:02:03 +01:00
Edward Firmo
09275f1414 esp-idf upload tft
Still a bit buggy, but this is probably the first working version of an esp-idf upload TFT to be published.
I will work more on this, but wanna have this commit as a reference.
2023-10-31 22:48:36 +01:00
Edward Firmo
bfc18fd307 Reduce number of unnecessary executions
Currently, many triggers will start the automation and then later if a condition is not true (like a page is not visible) the automation won't be doing anything. However, each of those "false" executions will generate an entry at Logbook, which might get spammed for large systems.

Probably solves #1205
Probably helps with #1203

This also reduce the date update from every minute to every hour and handle the situation where multiple panels are updated simultaneously in a event of an automation reload, which could cause performance issues for large systems.
2023-10-31 09:12:46 +01:00
Edward Firmo
92d7fd429a Reverted back icon size 48
The removal of this font reduced the file size with impact to the UI. The reduced file size didn't made a significant impact to the TFT Upload, so reverting this.
2023-10-21 20:22:34 +02:00
Edward Firmo
007a25bb94 Split set_brightness 2023-10-21 20:12:35 +02:00
Edward Firmo
d27dc1eb4f Send embedded climate friendly_name on boot
Solves #1171
2023-10-20 10:19:09 +02:00
Edward Firmo
661e2ba8c5 Long press to open settings regardless of supported_features
Solves #1142
2023-10-20 09:17:05 +02:00
Edward Firmo
5fcb1e0785 Fix incorrect preset when addon climate cool 2023-10-19 15:57:27 +02:00
Edward Firmo
2a526f3cea Moving docs to the Wiki area 2023-10-19 15:51:40 +02:00
Edward Firmo
ff917d663e Improved split of addon climate files
To make it easier to maintain
2023-10-19 15:44:06 +02:00
Edward Firmo
8bf2b9e4cc Fix indoor temp icon when embedded temperature is used
Solves #1179
2023-10-18 14:38:02 +02:00
Edward Firmo
5446400eee Round target temp limits based on step
Solves #1150
2023-10-18 14:10:10 +02:00
Edward Firmo
0f8c2f87be Fix reference to addon climate base 2023-10-18 12:40:18 +02:00
Edward Firmo
9aba74877e Fix operator error with IP address in ESPHome 2023.10 2023-10-18 11:30:16 +02:00
Edward Firmo
137229a3ca Merge pull request #1180 from Floppe/wider_info
More wider value fields so '12.34c/kWh' fits
2023-10-18 10:03:41 +02:00
Edward Firmo
af15ec6b79 Splitting addon climate 2023-10-18 10:00:40 +02:00
Edward Firmo
280f090a67 Replicated change to US landscape 2023-10-18 09:28:19 +02:00
Joachim Wickman
8bdfe1855d More wider value fields so '12.43c/kWh' fits 2023-10-17 13:55:11 +03:00
Edward Firmo
62e755042c Removed advanced from base package 2023-10-17 09:19:55 +02:00
Edward Firmo
a2fab582d5 Removed upload_tft from core 2023-10-17 09:03:54 +02:00
Edward Firmo
b1b88e75e4 Splitting files 2023-10-17 08:52:55 +02:00
Edward Firmo
4daf567f44 Revert back to arduino
It failed tests
2023-10-16 11:59:38 +02:00
Edward Firmo
6e57a2a316 esp-idf framework
Saves memory, between other benefits.
2023-10-16 11:00:50 +02:00
Edward Firmo
c9ff45f2b9 Pages constructors on scripts
This will simplify the calls for new add-ons.
2023-10-16 10:58:47 +02:00
Edward Firmo
d89aa90d12 Fix log message 2023-10-13 22:46:10 +02:00
Edward Firmo
d9325787a0 Split ESPHome validations 2023-10-13 22:43:22 +02:00
Edward Firmo
5a0c04dc69 Remove trailing spaces 2023-10-13 22:26:12 +02:00
Edward Firmo
95f321d590 Mapping to dos 2023-10-13 22:24:00 +02:00
Edward Firmo
ef7b1520ff Update validate_esphome.yml 2023-10-13 22:21:29 +02:00
Edward Firmo
7f0657ae8f Clean up upload_tft 2023-10-13 22:17:01 +02:00
Edward Firmo
35394d5d22 Standardizing logs calls 2023-10-13 15:41:01 +02:00
Edward Firmo
4d90adc36d Merge pull request #1176 from misery/main
Add whitespace to fix typo
2023-10-13 15:20:51 +02:00
Edward Firmo
471684ad8c Merge branch 'dev' into main 2023-10-13 15:19:03 +02:00
Edward Firmo
f7bf764458 Update ReleaseNotes.md 2023-10-13 15:17:15 +02:00
Edward Firmo
de4bd9dcdd Create ReleaseNotes.md 2023-10-13 15:17:05 +02:00
Edward Firmo
a1f1a8a31d upload_tft support to esp-idf
Still needing some code clean-up
2023-10-13 15:06:28 +02:00
André Klitzing
44b7eee5ee Add whitespace to fix typo
Otherwise if someone copy+paste this it will throw this error.
ERROR Error while reading config: Invalid YAML syntax:

mapping values are not allowed here
  in "nspanel.yaml", line 25, column 13:
2023-10-13 14:13:14 +02:00
Edward Firmo
6e4e4aff7e Fix reference to addon_climate_cool 2023-10-13 11:14:50 +02:00
Edward Firmo
7ba1265d55 Add build tests
This will build ESPHome with multiple combinations of packages to make sure nothing is broken.
2023-10-13 11:03:12 +02:00
Edward Firmo
297107da28 Fix directory mapping 2023-10-13 10:51:23 +02:00
Edward Firmo
0336390a8e Fix directory reference 2023-10-13 10:49:00 +02:00
Edward Firmo
b575e77563 Update validate_esphome.yml 2023-10-13 10:45:40 +02:00
Edward Firmo
3a165886c8 Update validate_esphome.yml 2023-10-13 09:39:36 +02:00
Edward Firmo
6ba3706458 Update validate_esphome.yml 2023-10-13 09:37:06 +02:00
Edward Firmo
0b6cf684dc Moving test files 2023-10-13 09:31:40 +02:00
Edward Firmo
290140524e Use default power save mode
Just because is not needed to specify this and the default mode (LIGHT) should be enough.
2023-10-13 09:23:46 +02:00
Edward Firmo
ce2fefa5b3 Remove pre-built
I'm removing this at it is getting too complex and will require github tokens to copy the build files. Instead I will focus in solving the problems making hard to build.
2023-10-12 11:35:15 +02:00
Edward Firmo
03395131d8 Add build to ESPHome validation 2023-10-12 10:35:51 +02:00
Edward Firmo
15cc5b9486 Removed improv BLE
Due to lack of memory
2023-10-12 10:04:48 +02:00
Edward Firmo
f255df3af2 Power save mode LIGHT 2023-10-12 09:56:05 +02:00
Edward Firmo
b11baf8860 Update nspanel_esphome_prebuilt.yaml 2023-10-12 09:49:38 +02:00
Edward Firmo
954699e87f Update nspanel_esphome_prebuilt.yaml 2023-10-12 09:46:30 +02:00
Edward Firmo
1af0894820 Update to latest checkout 2023-10-12 09:42:51 +02:00
Edward Firmo
f3a17959be Add dummy SSID 2023-10-12 09:39:44 +02:00
Edward Firmo
effc26672f Fill required substitutions 2023-10-12 09:36:57 +02:00
Edward Firmo
2b16753f6b Update nspanel_esphome_prebuilt.yaml 2023-10-12 09:33:46 +02:00
Edward Firmo
ff57a39d24 Add empty line at the end 2023-10-11 12:44:57 +02:00
Edward Firmo
f635e76154 Use esphome/build-action@v1.8.0 2023-10-11 12:43:21 +02:00
Edward Firmo
119b4a6eb3 Check-out to dev first 2023-10-11 12:41:46 +02:00
Edward Firmo
73aeec2edb Change ref to dev 2023-10-11 12:06:40 +02:00
Edward Firmo
d5a73a0a60 Adds advanced components to built in 2023-10-11 11:54:08 +02:00
Edward Firmo
c703b832e2 Add advanced files to validations 2023-10-11 11:47:01 +02:00
Edward Firmo
b92d6d459a ESPHome pre-built binary
Add a pre-built binary for users with trouble compiling with ESPHome or users who don´t wanna play with ESPHome at all.
2023-10-11 11:40:04 +02:00
Edward Firmo
597b1b2abd Use exit reparse mode from Nextion library
This is part of the preparation for esp-idf framework
2023-10-06 10:49:32 +02:00
Edward Firmo
725797b5fa Updates when home page is not visible
To keep consistency with outdoor temp
2023-10-06 10:32:24 +02:00
Edward Firmo
5a9f1c1c31 Updates outdoor temp when home page is not visible
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1065#issuecomment-1750074885
2023-10-06 10:29:29 +02:00
Edward Firmo
b591944a76 Sleep & Wake-up buttons 2023-10-05 15:42:03 +02:00
Edward Firmo
93194d0f8f Prepares for esp-idf
I haven't decided for `esp-idf` framework yet, but wanna play a bit as it looks to be saving some memory, so I want to prepare the system to support both frameworks (together with `arduino`).
2023-10-05 09:32:36 +02:00
Edward Firmo
303f5361ec Move non critical components to nspanel_esphome_advanced
To free up some memory on ESPHome.
2023-10-04 10:15:46 +02:00
Edward Firmo
189b3e7dcd Fix filter on current_page 2023-10-03 19:12:09 +02:00
Edward Firmo
d7116c0c68 Removed unnecessary call to bt_notific
`notification` page is loaded right after that.
2023-10-03 14:56:48 +02:00
Edward Firmo
742e2a243d Update home page when notification changes
Solves #1136
2023-10-03 14:37:46 +02:00
Edward Firmo
b6a5ea76c0 Removed remaining time call 2023-10-03 07:45:52 +02:00
Edward Firmo
a7aafdb348 Limit max chunk_size to 32768
To leave more heap memory available.
It might slow down a bit the transfers.
2023-10-03 00:06:35 +02:00
Edward Firmo
dff7e39b07 Thanks to sairon
We rebuilt the tft upload inspired by his implementation of Nextion library.
2023-10-02 22:32:29 +02:00
Edward Firmo
e0a7cd903b After boot check-up
Check for display availability after boot and, if not available, power cycle Nextion
2023-10-02 19:19:02 +02:00
Edward Firmo
985d6b5161 Fix invalid call to page var 2023-10-02 15:03:20 +02:00
Edward Firmo
83fccfe83b Rebuilt currentpage engine 2023-10-02 14:45:34 +02:00
Edward Firmo
201428da47 Rebuilt upload_tft and replaced fonts 2023-10-01 15:05:36 +02:00
Edward Firmo
4830b58b13 Bump v4.0.3dev 2023-09-30 16:05:16 +02:00
Edward Firmo
fa04f50c9d Remove font 10
I've removed this font to reduce TFT file size, however we can add this back later by creating a new font with only the icons needed for:

Font 10 (NotoSans-Regular + MDI, h 48):

settings:
bt_reboot
bt_sleep

cover:
cover_open
cover_close
cover_stop

notification:
bt_accept
bt_clear

fan:
button_up
button_down
button_on
button_off

confirm:
bt_accept
bt_clear
2023-09-30 16:02:17 +02:00
Edward Firmo
f9a24fc43e Translations - Czech
Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7127350
2023-09-30 15:48:37 +02:00
Edward Firmo
9283b4561d Change notification engine for current page missing 2023-09-30 15:41:12 +02:00
Edward Firmo
421dc71274 Merge pull request #1114 from Blackymas/beta
v4.0.2 patch release
2023-09-27 11:59:29 +02:00
Edward Firmo
5ea3036921 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into beta 2023-09-27 11:50:54 +02:00
Edward Firmo
0f9c691717 Merge branch 'main' of https://github.com/Blackymas/NSPanel_HA_Blueprint into beta 2023-09-27 11:50:22 +02:00
Edward Firmo
853b7d9885 Merge pull request #1113 from Blackymas/dev
v4.0.2 patch release
2023-09-27 11:48:34 +02:00
Edward Firmo
f2c6900d7e Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-27 11:44:50 +02:00
Edward Firmo
112e52f3d4 v4.0.2 patch release 2023-09-27 11:39:38 +02:00
Edward Firmo
f72a1038cd Removed unnecessary refresh of relay's chips
Solves #1068
2023-09-27 08:55:48 +02:00
Edward Firmo
4c738bbc51 Use UTC for date in weather forecast
Probably solves #1105
2023-09-26 22:23:19 +02:00
Edward Firmo
d355002da3 Update ReleaseNotes.md 2023-09-26 20:13:52 +02:00
Edward Firmo
09630570e6 Fix link of button02 on buttonpage03
Solves #1108
2023-09-26 19:59:25 +02:00
Edward Firmo
be6df9bb30 Added compile_process_limit 2023-09-26 18:13:01 +02:00
Edward Firmo
210ee0c70e Rebuild service calls for short press on buttons
I believe this can solve #1063
2023-09-26 16:43:07 +02:00
Edward Firmo
63d37695e4 v4.0.1 patch release (#1097)
* v4.0 - Alarm and Media player pages, Climate add-ons and a more robust panel (#1033)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* v4.0 Release Candidate 2 (#1044)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* Bump version to 4.0beta (#1045)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* v4.0 beta 2 (#1053)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>

* v4.0 release (#1054)

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>

* Beta testing v4.0.1 (#1089)

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

* Chpego patch 1 (#1059)

* Update nspanel_blueprint.yaml

fix some typo

* Update nspanel_blueprint.yaml

* Update README.md

* Update nspanel_blueprint.yaml

* Update nspanel_blueprint.yaml

* Started Release Notes for v4.1

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Prevents media player crash with `media_position_updated_at`

Prevents media player crashing when called before `media_position_updated_at` is able to provide a value.

I believe this solves #1062.

* timezone

* Settings page translations - Dutch

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7073055

* Typo

* Removed `display_current_brightness`

I've removed this sensor as it was spamming the logs and taking memory without providing real benefit.

* Ignore different patch versions

Change the versioning control to major and minor only, ignoring differences on the patch version.

So components with different patch versions should be able to work with each other as soon the major and minor versions are the same.
This same logic was implemented on the blueprint before the 4.0 release.

* Code clean-up

* Flexible time format selected

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1083#issuecomment-1732228103

* Removed obsolete thermostat page pic

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1076#discussioncomment-7085967

* Add date format for Finnish

* Fix `buttonpage03` long press pointing to page 2

* Fix mute volume not working

Solves #1079 items 2 and 3

* Reset sleep timer when brightness settings changes

Solves #1087

Also removes limit to 10char on "Brightness" on Settings page.

* Bump version to `4.0.1dev`

* Update ReleaseNotes.md

Preparing for patch release.

* Review translations - Finish

Solves #1083

* Update ReleaseNotes.md

* Remove trailing space

* v4.0.1beta

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
Co-authored-by: chpego <38792705+chpego@users.noreply.github.com>

* v4.0.1 patch release (#1096)

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

* Chpego patch 1 (#1059)

* Update nspanel_blueprint.yaml

fix some typo

* Update nspanel_blueprint.yaml

* Update README.md

* Update nspanel_blueprint.yaml

* Update nspanel_blueprint.yaml

* Started Release Notes for v4.1

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Prevents media player crash with `media_position_updated_at`

Prevents media player crashing when called before `media_position_updated_at` is able to provide a value.

I believe this solves #1062.

* timezone

* Settings page translations - Dutch

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7073055

* Typo

* Removed `display_current_brightness`

I've removed this sensor as it was spamming the logs and taking memory without providing real benefit.

* Ignore different patch versions

Change the versioning control to major and minor only, ignoring differences on the patch version.

So components with different patch versions should be able to work with each other as soon the major and minor versions are the same.
This same logic was implemented on the blueprint before the 4.0 release.

* Code clean-up

* Flexible time format selected

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1083#issuecomment-1732228103

* Removed obsolete thermostat page pic

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1076#discussioncomment-7085967

* Add date format for Finnish

* Fix `buttonpage03` long press pointing to page 2

* Fix mute volume not working

Solves #1079 items 2 and 3

* Reset sleep timer when brightness settings changes

Solves #1087

Also removes limit to 10char on "Brightness" on Settings page.

* Bump version to `4.0.1dev`

* Update ReleaseNotes.md

Preparing for patch release.

* Review translations - Finish

Solves #1083

* Update ReleaseNotes.md

* Remove trailing space

* v4.0.1beta

* v4.0.1 patch release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
Co-authored-by: chpego <38792705+chpego@users.noreply.github.com>

* Delete ReleaseNotes.md

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
Co-authored-by: chpego <38792705+chpego@users.noreply.github.com>
2023-09-25 13:52:05 +02:00
Edward Firmo
c0396766ac Delete ReleaseNotes.md 2023-09-25 13:46:10 +02:00
Edward Firmo
bf56ecdcff Merge branch 'main' into beta 2023-09-25 13:44:53 +02:00
Edward Firmo
e61efba78c Merge branch 'main' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-25 13:42:53 +02:00
Edward Firmo
26f67d7792 v4.0.1 patch release (#1096)
* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

* Chpego patch 1 (#1059)

* Update nspanel_blueprint.yaml

fix some typo

* Update nspanel_blueprint.yaml

* Update README.md

* Update nspanel_blueprint.yaml

* Update nspanel_blueprint.yaml

* Started Release Notes for v4.1

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Prevents media player crash with `media_position_updated_at`

Prevents media player crashing when called before `media_position_updated_at` is able to provide a value.

I believe this solves #1062.

* timezone

* Settings page translations - Dutch

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7073055

* Typo

* Removed `display_current_brightness`

I've removed this sensor as it was spamming the logs and taking memory without providing real benefit.

* Ignore different patch versions

Change the versioning control to major and minor only, ignoring differences on the patch version.

So components with different patch versions should be able to work with each other as soon the major and minor versions are the same.
This same logic was implemented on the blueprint before the 4.0 release.

* Code clean-up

* Flexible time format selected

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1083#issuecomment-1732228103

* Removed obsolete thermostat page pic

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1076#discussioncomment-7085967

* Add date format for Finnish

* Fix `buttonpage03` long press pointing to page 2

* Fix mute volume not working

Solves #1079 items 2 and 3

* Reset sleep timer when brightness settings changes

Solves #1087

Also removes limit to 10char on "Brightness" on Settings page.

* Bump version to `4.0.1dev`

* Update ReleaseNotes.md

Preparing for patch release.

* Review translations - Finish

Solves #1083

* Update ReleaseNotes.md

* Remove trailing space

* v4.0.1beta

* v4.0.1 patch release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
Co-authored-by: chpego <38792705+chpego@users.noreply.github.com>
2023-09-25 13:38:38 +02:00
Edward Firmo
eaea820658 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-25 13:35:30 +02:00
Edward Firmo
a424c8c17b v4.0.1 patch release 2023-09-25 13:27:20 +02:00
Edward Firmo
a87fc341f2 Beta testing v4.0.1 (#1089)
* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

* Chpego patch 1 (#1059)

* Update nspanel_blueprint.yaml

fix some typo

* Update nspanel_blueprint.yaml

* Update README.md

* Update nspanel_blueprint.yaml

* Update nspanel_blueprint.yaml

* Started Release Notes for v4.1

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Prevents media player crash with `media_position_updated_at`

Prevents media player crashing when called before `media_position_updated_at` is able to provide a value.

I believe this solves #1062.

* timezone

* Settings page translations - Dutch

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7073055

* Typo

* Removed `display_current_brightness`

I've removed this sensor as it was spamming the logs and taking memory without providing real benefit.

* Ignore different patch versions

Change the versioning control to major and minor only, ignoring differences on the patch version.

So components with different patch versions should be able to work with each other as soon the major and minor versions are the same.
This same logic was implemented on the blueprint before the 4.0 release.

* Code clean-up

* Flexible time format selected

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1083#issuecomment-1732228103

* Removed obsolete thermostat page pic

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1076#discussioncomment-7085967

* Add date format for Finnish

* Fix `buttonpage03` long press pointing to page 2

* Fix mute volume not working

Solves #1079 items 2 and 3

* Reset sleep timer when brightness settings changes

Solves #1087

Also removes limit to 10char on "Brightness" on Settings page.

* Bump version to `4.0.1dev`

* Update ReleaseNotes.md

Preparing for patch release.

* Review translations - Finish

Solves #1083

* Update ReleaseNotes.md

* Remove trailing space

* v4.0.1beta

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
Co-authored-by: chpego <38792705+chpego@users.noreply.github.com>
2023-09-24 15:15:20 +02:00
Edward Firmo
b5d81026cd Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-24 15:14:28 +02:00
Edward Firmo
91a1cca29c v4.0.1beta 2023-09-24 15:09:04 +02:00
Edward Firmo
b3a335dedd Remove trailing space 2023-09-24 14:56:33 +02:00
Edward Firmo
b7cd36fbdf Update ReleaseNotes.md 2023-09-24 14:43:18 +02:00
Edward Firmo
610ba939fa Review translations - Finish
Solves #1083
2023-09-24 14:41:55 +02:00
Edward Firmo
84d7f71f59 Update ReleaseNotes.md
Preparing for patch release.
2023-09-24 09:17:02 +02:00
Edward Firmo
b3c0fe3dd0 Bump version to 4.0.1dev 2023-09-23 23:03:19 +02:00
Edward Firmo
327b40ecd8 Reset sleep timer when brightness settings changes
Solves #1087

Also removes limit to 10char on "Brightness" on Settings page.
2023-09-23 22:54:20 +02:00
Edward Firmo
12f6bd75b5 Fix mute volume not working
Solves #1079 items 2 and 3
2023-09-23 22:11:06 +02:00
Edward Firmo
bf05419946 Fix buttonpage03 long press pointing to page 2 2023-09-23 20:28:42 +02:00
Edward Firmo
4bdfca3b5f Add date format for Finnish 2023-09-23 15:15:22 +02:00
Edward Firmo
3029671d53 Removed obsolete thermostat page pic
Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1076#discussioncomment-7085967
2023-09-23 08:53:08 +02:00
Edward Firmo
e31362aac4 Flexible time format selected
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1083#issuecomment-1732228103
2023-09-23 08:43:09 +02:00
Edward Firmo
17c14e9ab0 Code clean-up 2023-09-22 11:17:35 +02:00
Edward Firmo
1065fe0568 Ignore different patch versions
Change the versioning control to major and minor only, ignoring differences on the patch version.

So components with different patch versions should be able to work with each other as soon the major and minor versions are the same.
This same logic was implemented on the blueprint before the 4.0 release.
2023-09-22 10:54:48 +02:00
Edward Firmo
6ad844a9d8 Removed display_current_brightness
I've removed this sensor as it was spamming the logs and taking memory without providing real benefit.
2023-09-22 10:14:44 +02:00
Edward Firmo
83baeaacf0 Typo 2023-09-22 09:59:17 +02:00
Edward Firmo
b8c2fb9971 Settings page translations - Dutch
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7073055
2023-09-21 20:23:30 +02:00
Edward Firmo
91a77ae201 timezone 2023-09-21 16:40:02 +02:00
Edward Firmo
b7e9f1b1e8 Prevents media player crash with media_position_updated_at
Prevents media player crashing when called before `media_position_updated_at` is able to provide a value.

I believe this solves #1062.
2023-09-21 09:14:40 +02:00
chpego
05dfd69cda Chpego patch 1 (#1059)
* Update nspanel_blueprint.yaml

fix some typo

* Update nspanel_blueprint.yaml

* Update README.md

* Update nspanel_blueprint.yaml

* Update nspanel_blueprint.yaml

* Started Release Notes for v4.1

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-09-20 22:43:48 +02:00
Edward Firmo
eda6852309 v4.0 release (#1055)
* v4.0 - Alarm and Media player pages, Climate add-ons and a more robust panel (#1033)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* v4.0 Release Candidate 2 (#1044)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* Bump version to 4.0beta (#1045)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>

* v4.0 beta 2 (#1053)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>

* v4.0 release (#1054)

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
2023-09-20 16:48:06 +02:00
Edward Firmo
1096efe312 v4.0 release (#1054)
* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

* v4.0 release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
2023-09-20 16:39:45 +02:00
Edward Firmo
2eefe6c8c6 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-20 16:38:41 +02:00
Edward Firmo
a42feafa8c v4.0 release 2023-09-20 16:33:48 +02:00
Edward Firmo
e8b6d155f7 v4.0 beta 2 (#1053)
* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

* Change version to 4.0dev

To differentiate from beta.

* Added missing translations (#1047)

* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Translations to Slovak on Settings page

* Refresh docs

* Update nspanel_blank.md

* Update nspanel_blank.md

* Add screensaver to `nspanel_blank.tft`

And build a new tft with latest firmware and url for instructions.

* Update nspanel_blank.md

* Fix to Slovenian translation

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796

* Settings page - Translations to French

From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452

* Alarm page - Translations to French

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479

* Add customization for display sleeping/awake

Probably solves #1035

* Customizations - Blank TFT button

Probably solves #1048

* Customizations - Deep sleep

Solves #955

* Customization - Deep sleep - Fix broken link

* Translations - Slovak

- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142

* New versioning - not implemented

* Bump version to `4.0b2`

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
Co-authored-by: Erik Larsson <erik1337.el@gmail.com>
2023-09-20 10:12:53 +02:00
Edward Firmo
06078396c9 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-20 10:12:07 +02:00
Edward Firmo
c375a93d8e Bump version to 4.0b2 2023-09-20 10:08:03 +02:00
Edward Firmo
4b66528894 New versioning - not implemented 2023-09-20 09:42:48 +02:00
Edward Firmo
d4d0e19d2f Translations - Slovak
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-7054153
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7054142
2023-09-20 09:32:15 +02:00
Edward Firmo
a1c4f065a2 Customization - Deep sleep - Fix broken link 2023-09-20 07:39:15 +02:00
Edward Firmo
44aa752e70 Customizations - Deep sleep
Solves #955
2023-09-20 07:36:01 +02:00
Edward Firmo
627e0b63e7 Customizations - Blank TFT button
Probably solves #1048
2023-09-19 20:55:07 +02:00
Edward Firmo
c747ea17d5 Add customization for display sleeping/awake
Probably solves #1035
2023-09-19 20:34:19 +02:00
Edward Firmo
be493eed1f Alarm page - Translations to French
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-7046479
2023-09-19 19:50:37 +02:00
Edward Firmo
aed0fbf45a Settings page - Translations to French
From https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7045452
2023-09-19 15:07:36 +02:00
Edward Firmo
4649924c04 Fix to Slovenian translation
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-7041796
2023-09-19 12:46:09 +02:00
Edward Firmo
25ff9a0267 Update nspanel_blank.md 2023-09-19 11:33:17 +02:00
Edward Firmo
1d4fafd7c5 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-19 11:30:22 +02:00
Edward Firmo
0af0d2fbaf Add screensaver to nspanel_blank.tft
And build a new tft with latest firmware and url for instructions.
2023-09-19 11:29:55 +02:00
Edward Firmo
67fb8f2eda Update nspanel_blank.md 2023-09-19 11:28:09 +02:00
Edward Firmo
2715d32d15 Update nspanel_blank.md 2023-09-19 11:26:34 +02:00
Edward Firmo
b215f1779d Refresh docs 2023-09-19 11:20:13 +02:00
Edward Firmo
d08bddd72e Translations to Slovak on Settings page 2023-09-19 08:24:15 +02:00
Erik Larsson
88f296c90e Added missing translations (#1047)
* Added missing translations

Added missing translations for the Swedish translation.

* Caption first char

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-09-18 23:34:15 +02:00
Edward Firmo
1a4cb27e01 Change version to 4.0dev
To differentiate from beta.
2023-09-18 18:01:42 +02:00
Edward Firmo
9c4aad8db0 Bump version to 4.0beta (#1045)
* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

* Bump version to 4.0beta

To reduce the chance of an obsolete file in use after the release.

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
2023-09-18 17:56:44 +02:00
Edward Firmo
6cbe43eb59 Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-18 17:55:04 +02:00
Edward Firmo
a653d47e3c Bump version to 4.0beta
To reduce the chance of an obsolete file in use after the release.
2023-09-18 17:51:47 +02:00
Edward Firmo
4a37de57e4 v4.0 Release Candidate 2 (#1044)
* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

* Prototyping `power` page

Thanks @Floppe for doing the design
#838

* Prototyping `power` page

* New sleep flow

* Removed trailing spaces

* Fix empty page climate

* Fix names on button pages

Fix names when a name is not provided in the blueprint settings.

* Fix call to sleep routine when timeout changes

Solves #1037

* Replace `confirm` var on buttons pages

Simpler and saves some memory.

* Clean-up

* Align the code for the 3 timers

* Extend domains supported by home page custom buttons

Based on #1034

* Fix error when btn_label is `None`

* Fix `Variable invalid` on buttons pages

* Fix constructor of Entity pages

* Fallback even when button is assigned to another entity

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844

* Add inputs for media player refresh time

* Adjustments to Media Player refresh interval default values

* Use panel's events to reset timers

Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153

* State based colors to home page custom buttons

* Fix alarm not changing status

Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039

* Missing `nspanel_us.tft`

* add `touchevents` to pages `media_player` and `confirm`

To avoid panel going back to Home page while user is playing with the page.
Solves #1040

* Media player minor layout changes

* Media player - Volume timer & icon size

Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10

* Media player roll back font 9 and timer 1s

* Don't send to Nextion obsolete volume settings

If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.

* Media player - Layout improvement

- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page

* Add touchevents to page climate

Possibly solves #995

* Resolve validation

* Correct playing time based on `updated_at` attribute

* Prepare for when attribute is not available

* Fix attribute `media_position`

* Fix time duration when HA isn't updating position

* Fix climate page not opening when offline

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067

* Clean-up release notes

* Clean up code

- Removed commented out lines
- Removed temporary logs

Getting prepared to release

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
2023-09-18 17:27:00 +02:00
Edward Firmo
5158fa86d3 Clean up code
- Removed commented out lines
- Removed temporary logs

Getting prepared to release
2023-09-18 17:25:37 +02:00
Edward Firmo
8f6ebd62e1 Clean-up release notes 2023-09-18 17:01:30 +02:00
Edward Firmo
ee5ccd0bff Fix climate page not opening when offline
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6834067
2023-09-18 16:39:22 +02:00
Edward Firmo
8859d8b229 Fix time duration when HA isn't updating position 2023-09-18 14:07:12 +02:00
Edward Firmo
61bf1fbcd7 Fix attribute media_position 2023-09-18 03:28:20 +02:00
Edward Firmo
88ed2ad2f6 Prepare for when attribute is not available 2023-09-18 02:52:34 +02:00
Edward Firmo
8c37001cfc Correct playing time based on updated_at attribute 2023-09-18 02:46:26 +02:00
Edward Firmo
0a1a0a811a Resolve validation 2023-09-18 02:37:53 +02:00
Edward Firmo
873eef75ca Merge branch 'beta' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-18 02:22:25 +02:00
Edward Firmo
8362447dac Add touchevents to page climate
Possibly solves #995
2023-09-17 20:20:19 +02:00
Edward Firmo
60c47ff82c Media player - Layout improvement
- Removed button "Stop"
- Increase touch area for buttons
- Redistributed buttons on page
2023-09-17 12:43:18 +02:00
Edward Firmo
581808a123 Don't send to Nextion obsolete volume settings
If the volume is the same as the last one sent to the screen, don't send again, so if changes are being made on the screen it didn't receive the update all the time, making the slider unresponsive.
2023-09-17 12:21:11 +02:00
Edward Firmo
189cbdd645 Media player roll back font 9 and timer 1s 2023-09-17 11:47:37 +02:00
Edward Firmo
c279dd7932 Media player - Volume timer & icon size
Volume timer changed from 1000 to 500ms
Icon change from font 9 to 10
2023-09-17 07:09:05 +02:00
Edward Firmo
f9872700d9 Media player minor layout changes 2023-09-17 06:58:37 +02:00
Edward Firmo
f705401896 add touchevents to pages media_player and confirm
To avoid panel going back to Home page while user is playing with the page.
Solves #1040
2023-09-16 14:28:05 +02:00
Edward Firmo
30a0404c4a Missing nspanel_us.tft 2023-09-16 14:12:33 +02:00
Edward Firmo
00d888817f Fix alarm not changing status
Do not clear `entity_id` when opening keyboard page, so the info can be used when sending commands.

Solves #1039
2023-09-16 14:05:22 +02:00
Edward Firmo
20b672085e State based colors to home page custom buttons 2023-09-16 13:15:23 +02:00
Edward Firmo
22ba572d75 Use panel's events to reset timers
Possibly solves #1040
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-7020153
2023-09-16 10:12:58 +02:00
Edward Firmo
aeb25f21ff Adjustments to Media Player refresh interval default values 2023-09-16 10:03:02 +02:00
Edward Firmo
c098ea4ecf Add inputs for media player refresh time 2023-09-16 01:21:04 +02:00
Edward Firmo
d4f9926079 Fallback even when button is assigned to another entity
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1013#issuecomment-1720107844
2023-09-15 21:17:23 +02:00
Edward Firmo
59b5687420 Fix constructor of Entity pages 2023-09-15 20:27:28 +02:00
Edward Firmo
813f0c4800 Fix Variable invalid on buttons pages 2023-09-15 20:07:14 +02:00
Edward Firmo
1e566ce990 Fix error when btn_label is None 2023-09-15 19:58:42 +02:00
Edward Firmo
cf2d6e7cb3 Extend domains supported by home page custom buttons
Based on #1034
2023-09-15 18:52:40 +02:00
Edward Firmo
450c5f161c Align the code for the 3 timers 2023-09-15 17:07:54 +02:00
Edward Firmo
b8294b63e0 Clean-up 2023-09-15 14:30:26 +02:00
Edward Firmo
21fb3fc395 Replace confirm var on buttons pages
Simpler and saves some memory.
2023-09-15 14:29:22 +02:00
Edward Firmo
dd2c360780 Fix call to sleep routine when timeout changes
Solves #1037
2023-09-15 10:20:37 +02:00
Edward Firmo
e8193c2bb7 Fix names on button pages
Fix names when a name is not provided in the blueprint settings.
2023-09-15 10:03:50 +02:00
Edward Firmo
76a9520557 Fix empty page climate 2023-09-15 09:46:27 +02:00
Edward Firmo
c2d94ce183 Removed trailing spaces 2023-09-15 00:24:14 +02:00
Edward Firmo
21e099bb5f New sleep flow 2023-09-14 23:59:27 +02:00
Edward Firmo
1597a2aaad Prototyping power page 2023-09-14 02:19:36 +02:00
Edward Firmo
29f9b24592 Prototyping power page
Thanks @Floppe for doing the design
#838
2023-09-14 02:18:19 +02:00
Edward Firmo
96ae6987cb v4.0 - Alarm and Media player pages, Climate add-ons and a more robust panel (#1033)
* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix issue with `restore_state` and ESPHome v2023.7.0 (#941)

Solves #939

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

* Improve version notification

* Disable restore `notification_unread`

This must be changed to a binary sensor in the future.

* Beta v4.0 (#1012)

* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>

* Fix Fan page button colors when opening

Solves #1017

* Translations (#1023)

* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Adjustments to settings page

* Fix entity info when calling detailed pages

Solves #1022

* Added `media_player` page (hidden)

* New "Confirm" pop-up

This also removes the sensor "NSPanel Event"

* Fix pages not updating values

Solves #1026

* Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`

* Fix logging for global_settings

It was logging wakeup_page, which is deprecated

* Improved version notification

* Removed trailing spaces

* Notification for `sensor.xxxxx_current_page` missing

This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.

* Simplify `touchevent` engine

The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".

* Media player first buttons actions

* Fix unknown service: `media_player.null`

* Media Player control

You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.

* Remove dimming timer for now

The funcionality isn't completed.

* Home page - Custom buttons

On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.

* Fix Media player missing parameters

Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573

* Prevents calls to `media_player.null`

* Remove `entity` info from pages on TFT

Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
Co-authored-by: w00zy <52609940+WZYProjects@users.noreply.github.com>
2023-09-14 00:33:40 +02:00
Edward Firmo
d1638863a4 Remove entity info from pages on TFT
Since v3.4, the info about entity_id shown was going all the way to Nextion and then sent back in the json return, however this requires a long (100-char) global var and the way it was implemented, it was one of those per settings page, as climate should be also recorded at the same time in case the embedded climate was installed.
This was taking too much memory, so I've moved this info to a global variable (string) in ESPHome.
There is now lots of space for code cleaning (and still pending to do the same with climate entity, as it could be only a bool to inform if embedded), but this brings the functionality.

This enabled the return to global for some components, so it probably solves #1031
2023-09-13 23:36:24 +02:00
Edward Firmo
a836462df1 Prevents calls to media_player.null 2023-09-13 17:57:01 +02:00
Edward Firmo
95e1bbc439 Fix Media player missing parameters
Possibly solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1030#discussioncomment-6984573
2023-09-13 08:28:02 +02:00
Edward Firmo
db86e701e4 Home page - Custom buttons
On the blueprint you can now set up to 3 buttons to be shown on Home page.
It will show the detailed settings page, so the entity must be compatible.
2023-09-13 00:01:43 +02:00
Edward Firmo
7ba90fe741 Remove dimming timer for now
The funcionality isn't completed.
2023-09-12 20:09:04 +02:00
Edward Firmo
81d16343a7 Media Player control
You will be able to add a Media Player entity to any of the buttons pages and with a long press you will see the media player page.
2023-09-12 20:06:58 +02:00
Edward Firmo
39a5fcf434 Fix unknown service: media_player.null 2023-09-11 23:49:00 +02:00
Edward Firmo
e1a078fea5 Media player first buttons actions 2023-09-11 23:21:57 +02:00
Edward Firmo
7452dfd2bb Simplify touchevent engine
The touch event is used only for the sleeping engine (it will be used for dimming later) and it was transferring all the json info with page name, component, entity, etc.
This was replaced by a simple random integer with no meaning other than "the screen was touched, reset the timer".
2023-09-11 12:17:10 +02:00
Edward Firmo
f1e3dc49e6 Notification for sensor.xxxxx_current_page missing
This might be a common issue for users migrating from v3.4 to v3.5.
This information is part of the release notes, but I believe it worth having a guide to support closely any user who miss that in the release notes.
2023-09-11 02:31:19 +02:00
Edward Firmo
8129e59250 Removed trailing spaces 2023-09-11 01:43:08 +02:00
Edward Firmo
beb123cd19 Improved version notification 2023-09-11 01:35:25 +02:00
Edward Firmo
605de42f67 Fix logging for global_settings
It was logging wakeup_page, which is deprecated
2023-09-10 22:51:26 +02:00
Edward Firmo
591c7aa69b Media player - Buttons
- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`
2023-09-10 22:37:36 +02:00
Edward Firmo
796968122b Fix pages not updating values
Solves #1026
2023-09-10 12:56:15 +02:00
Edward Firmo
6e65ea3d03 New "Confirm" pop-up
This also removes the sensor "NSPanel Event"
2023-09-10 02:48:28 +02:00
Edward Firmo
c1bdd7da54 Added media_player page (hidden) 2023-09-09 11:14:57 +02:00
Edward Firmo
b5bb42c68d Fix entity info when calling detailed pages
Solves #1022
2023-09-09 02:58:23 +02:00
Edward Firmo
5ed58d8f24 Adjustments to settings page 2023-09-08 20:29:08 +02:00
w00zy
3620113a71 Translations (#1023)
* Translations

* Update nspanel_blueprint.yaml

I've changed `brightness` for now as the new design isn't implemented yet, but that string is already in use with the current design.

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-09-08 08:28:27 +02:00
Edward Firmo
43803dab12 Merge branch 'beta' into dev 2023-09-08 03:20:34 +02:00
Edward Firmo
680d85f1bc Fix Fan page button colors when opening
Solves #1017
2023-09-08 03:01:31 +02:00
Edward Firmo
0af51083b2 Merge branch 'main' into beta 2023-09-08 02:41:15 +02:00
Edward Firmo
626aedb18a Beta v4.0 (#1012)
* Create ReleaseNotes.md (#879)

* Create ReleaseNotes.md

* sensor display precision

* Filter devices to esp32 only (#881)

* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list

* Sensor display precision (#880)

Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).

* New language selector (#882)

* New language selector

* Update ReleaseNotes.md

* Update ReleaseNotes.md

* Remove `settings_entity` (#887)

* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`

* Move `entity` variable to home page (#889)

* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Use `en` as fallback language (#891)

* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language

* Create `nspanel_us_land.tft` (#890)

* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

* Fix "Button confirmation page not working correctly"

Solves #883

* Supports weather forecast with `datetime` not string

This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893

* Wifi icon to indicate when API offline

This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon

* API status indication on the panel

* Limit light & cover to supported settings (#896)

* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings

* Update instructions.md

* Add Fan speed settings page (#897)

* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Fix name on confirmation page

Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501

* Select wake-up page (#898)

* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page

* Fan update engine

Change the fan update engine to follow the same patter as other settings pages.

* Update ReleaseNotes.md

* Adding vertical bars pics

* Panel offline mode (#900)

* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode

* "Jump to settings" on tft

Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.

* Exclude Nextion2Text

Exclude Nextion2Text

* Fix validation issue

* Time engine on ESPHome

* Time engine on ESPHome

* Notification page bigger hotspot

Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907

* Boot page retry comm

The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.

* Fix call to screen page

Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.

* Fix fan page `button_on`

Fixing rounding on that button.

* Fixed Fan page rounding

* Prevents boot sequence in other pages

* Physical relay local control

We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910

* Embedded climate (#917)

* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.

* Update ReleaseNotes.md

* Services back to the Blueprint

Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.

* Update ReleaseNotes.md

* support to hidden ssid (#908)

Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906

* Update nspanel_esphome.yaml

* Removed `restore_state`

There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939

* US model - Fan page - Redistribute icons

Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706

* Align `nspanel_us_land`

Apply all changes from EU to US_Land

* Fix relays chips

Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273

* Fix "invalid variable" for "api"

Fix error "Nextion invalid variable name" when setting `api`.

* Default embedded climate to relay_0

* Fix translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043

* Fix `set_temperature` for climate

Solves #957

* Fix `fan.turn_off` call

Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535

* Call a `fan.turn_off` when percentage is 0%

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756

* Fix call for fan stop button

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377

* Icons on ESPHome

Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.

* Updated translations - Spanish

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961

* Make home page sensor's icons consistent

Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963

* Updated translations - Slovenian

Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751

* dutch (#974)

* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Add-on support (#977)

Moved climate settings to an add-on.
Updated documentation.

* Fixed link to addon climate docs

* Fix change brightness when sleeping

Prevents the panel to change screen brightness when sleeping.

Solves #975

* Standardize HA service calls

* Bump version to `4.0 dev`

* Create customization.md

This will reduce the need for:
- #920
- #662
- #833

* Clean-up for customizations

Clean up ESPHome in order to make easier the use of customizations.

* Create Alarm page

* Add page Alarm

* Add Alarm docs

Update docs to reflect the current state (new features & changes)

* Creating "install.md" and update add-ons instructions

* Add Alarm page buttons pics

* Add link to Alarm on page Home

* Create Alarm page

* Alarm button font color

* Add `keyb_num` page

* Alarm Control Panel with PIN (#982)

Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718

* Fix alarm without pin not working

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977

* Alarm page UI

Fixed close button
Disabled buttons are darker

* Move Entities button to ESPHome

Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.

* Human readable Uptime (#986)

* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>

* Update alarm icon & color

* Revert `fast_connect` back to `false`

* Extended chars on buttons pages (#988)

Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987

* Removed `fast_connect`

* Support to `code_arm_required`

Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).

* Update alarm icon on home page

Refresh icon when alarm state changes.

* Fix alarm icon not updating on home page

* Home buttons new format - Alarm

Modernise the button Alarm flow on page Home to improve performance.

* Home buttons new format - Entities

Modernise the button "Entities" flow on page Home to improve performance.

* Home buttons new format - QRcode

Modernise the button "QRcode" flow on page Home to improve performance.

* Home buttons new format - Notification

Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.

* Adding screenshots

* Delete ReleaseNotes.md

Moved to the release

* New entity filter format

This new format was released with HA v2023.4 and the old one will be deprecated soon.

* Fix Alarm page bypass icon

* Bump version to 4.0

* Rename `addon_climate_heat`

* Simplify climate substitutions

* Add support for `addon_climate_cool`

* Removed `${verbose_log}`

Use logger level `VERBOSE` instead

* Fix script call

* Clean up general entities & fallback

Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.

* Phase out sensor `nspanel_event` (partially)

This sensor is being replaced by event calls.

* uptime sensors (#998)

* Create ReleaseNotes.md

* Fix Climate page when embedded climate

And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260

* Move brightness control to global var

Clean up page Home

* Alarm page translations - Finnish

https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262

* Exported pics

* Clean-up TFT

- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages

* Fixed background pics

- Entities pages
- Weather pages

* Standardize close button

* Add "Alarm" section

* Support to wake-up page on `wake_up_display` service

This changes the behavior of a service introduced by #734.

* Optimize `wake_up_display` service

* Fix icon font sizes 10 and 64

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`

* Fix Settings page element ids

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668

* Add translation keys for `settings` page

#1002

* Update settings page when brightness changes on HA

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796

* Clean-up page settings

* update docs (#1003)

* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>

* Clean-up Cover page

I'm preparing this page to have icons changing based on the device_class selected to a cover.

* Clean-up boot delay

* Enable `current_page` sensor by default

Otherwise the system won´t update values unless the page is reloaded.

* Use `current_page` in blueprint conditions

One more step towards the phase out of `nspanelevent`.

* Move `script.refresh_colors` to `service.global_settings`

As this is called from a single point, there's no meaning of having a separated script.

* Fix climate icon update

Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454

* Fix button show on climate page

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335

* Visual improvements on climate page

- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990

* Don't update values when page home is not visible

To reduce load on Home Assistant and the network

* Cleanup boot sequence

Move some functionalities to ESPHome

* Display internal sensor value when wifi is out

Before it was showing on home page only when API was out. This adds a test for WiFi.

* Fix `default_target_temperature`

It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727

* Adding ID to components missing it

* Renamed `wake_up_display` to `wake_up`

* Re-arrange commands list

* Add service `set_component_color`

Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`

* Fix button pages not showing

* Adjusted time for HW long click

* Fixed buttons on settings page

* Minor adjustments to page climate

And replace font 10 to size 48 (it was 64 since a few days ago).

* Updates to breaking changes list

* Page settings redesign

Clean up the UI of settings page.
Prepare for translations.

* Enable translations of Settings page

* Notification word-wrap

For EU and US_LAND only, for now.

* Notifications page rebuilt

- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.

* Word-wrap buttons pages

Taking advantage of the algorithm created for notifications.

* Word-wrap for Alarm page

* Version mismatch notication

* Fix ESPHome not starting with older TFT

* Rebuilt home page status bar update

* Updated translations - Italian

Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu

* Fix `Nextion reported variable name invalid!`

* Fix `Nextion variable invalid`

* Handle `embedded_indoor_temperature`

Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.

* Review temperature correction engine

* Fix display climate chip

* update `temp_nspanel` when correction changes

* Fix `Fan` page not open with long press HW button

Solves #1007

* Minor adjustments on settings page

* version 4.0 ready for release

* Clean-up docs

---------

Co-authored-by: bkbartk <bartkock@outlook.com>
Co-authored-by: w00zy <WZYProjects+github@gmail.com>
2023-09-08 02:35:50 +02:00
Edward Firmo
6f51c67828 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-07 22:51:41 +02:00
Edward Firmo
071ee7f39a Disable restore notification_unread
This must be changed to a binary sensor in the future.
2023-09-07 22:50:40 +02:00
Edward Firmo
205a8cee2f Merge branch 'beta' into dev 2023-09-07 22:47:22 +02:00
Edward Firmo
63905025bf Improve version notification 2023-09-07 18:28:35 +02:00
Edward Firmo
c632d32b87 Clean-up docs 2023-09-07 17:33:10 +02:00
Edward Firmo
4fe8633978 version 4.0 ready for release 2023-09-07 17:22:52 +02:00
Edward Firmo
fec2824464 Minor adjustments on settings page 2023-09-07 17:10:16 +02:00
Edward Firmo
8eaead0ef5 Fix Fan page not open with long press HW button
Solves #1007
2023-09-07 13:35:03 +02:00
Edward Firmo
c819bbec9c update temp_nspanel when correction changes 2023-09-07 08:49:20 +02:00
Edward Firmo
f8cf178440 Fix display climate chip 2023-09-07 08:27:54 +02:00
Edward Firmo
79f921e99c Review temperature correction engine 2023-09-07 02:01:39 +02:00
Edward Firmo
067c173995 Handle embedded_indoor_temperature
Internal temperature display will be handled locally (ESPHome) when no other sensor is selected.
2023-09-07 00:32:20 +02:00
Edward Firmo
f093126726 Fix Nextion variable invalid 2023-09-06 21:43:18 +02:00
Edward Firmo
086a30c18a Fix Nextion reported variable name invalid! 2023-09-06 21:29:08 +02:00
Edward Firmo
e505438203 Updated translations - Italian
Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/1002#discussioncomment-6926846

Thanks @MaiPiu
2023-09-06 20:19:13 +02:00
Edward Firmo
fcddc2778f Rebuilt home page status bar update 2023-09-06 16:12:53 +02:00
Edward Firmo
f0c72e663c Fix ESPHome not starting with older TFT 2023-09-06 02:48:16 +02:00
Edward Firmo
188f565409 Version mismatch notication 2023-09-06 02:32:52 +02:00
Edward Firmo
3a2da38c6f Word-wrap for Alarm page 2023-09-06 01:29:56 +02:00
Edward Firmo
4668073522 Word-wrap buttons pages
Taking advantage of the algorithm created for notifications.
2023-09-06 01:06:27 +02:00
Edward Firmo
066cd31616 Notifications page rebuilt
- Notification button processed on ESPHome (as all the info is there)
- Added word-wrap for main text
- Expanded text size
- Handling display mode (used to define the number of chars per line on Notifications)
- Versioning handling - As a consequence of the previous item.
2023-09-06 00:52:35 +02:00
Edward Firmo
1c1cf8e959 Notification word-wrap
For EU and US_LAND only, for now.
2023-09-05 00:40:10 +02:00
Edward Firmo
7097d9bf84 Enable translations of Settings page 2023-09-04 21:13:18 +02:00
Edward Firmo
7f6b5a7115 Page settings redesign
Clean up the UI of settings page.
Prepare for translations.
2023-09-04 17:55:04 +02:00
Edward Firmo
3523ad8756 Updates to breaking changes list 2023-09-04 14:57:45 +02:00
Edward Firmo
56f21880ba Minor adjustments to page climate
And replace font 10 to size 48 (it was 64 since a few days ago).
2023-09-04 14:40:56 +02:00
Edward Firmo
d3098a7f40 Fixed buttons on settings page 2023-09-04 12:23:46 +02:00
Edward Firmo
c2ecffd775 Adjusted time for HW long click 2023-09-04 12:20:02 +02:00
Edward Firmo
ba166ac55b Fix button pages not showing 2023-09-04 07:20:10 +02:00
Edward Firmo
d569956ff2 Add service set_component_color
Deprecates the following services:
- `send_command_font_color`
- `send_command_background_color`
2023-09-03 23:52:36 +02:00
Edward Firmo
1d43f75318 Re-arrange commands list 2023-09-03 21:28:27 +02:00
Edward Firmo
0518531f02 Renamed wake_up_display to wake_up 2023-09-03 21:25:49 +02:00
Edward Firmo
806883ca34 Adding ID to components missing it 2023-09-03 21:19:54 +02:00
Edward Firmo
20ef25ecb5 Fix default_target_temperature
It also updates the page home when thermostat status changes (for the chips).
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6897727
2023-09-03 18:26:02 +02:00
Edward Firmo
9563dba722 Display internal sensor value when wifi is out
Before it was showing on home page only when API was out. This adds a test for WiFi.
2023-09-03 18:01:47 +02:00
Edward Firmo
1dfd0e6f9a Cleanup boot sequence
Move some functionalities to ESPHome
2023-09-03 15:17:25 +02:00
Edward Firmo
45eef605ae Don't update values when page home is not visible
To reduce load on Home Assistant and the network
2023-09-03 12:05:15 +02:00
Edward Firmo
41c3b01769 Visual improvements on climate page
- Add friendly name when embedded - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891465
- Make disable icons a bit darker - Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6893440
- Add space for page title in EU an US Land versions
- Reset page timer when pressing/releasing on the slider - Partially solves #990
2023-09-03 11:47:00 +02:00
Edward Firmo
6c7afe5bfe Fix button show on climate page
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891335
2023-09-02 12:14:10 +02:00
Edward Firmo
5cc19470f7 Fix climate icon update
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6891454
2023-09-02 11:52:31 +02:00
Edward Firmo
cc9caa7017 Move script.refresh_colors to service.global_settings
As this is called from a single point, there's no meaning of having a separated script.
2023-09-02 10:57:14 +02:00
Edward Firmo
98da0d4c6e Use current_page in blueprint conditions
One more step towards the phase out of `nspanelevent`.
2023-09-02 02:04:28 +02:00
Edward Firmo
b134a37408 Enable current_page sensor by default
Otherwise the system won´t update values unless the page is reloaded.
2023-09-02 01:54:20 +02:00
Edward Firmo
ef130e4c15 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-09-02 01:41:06 +02:00
Edward Firmo
4d255c1df4 Clean-up boot delay 2023-09-02 01:40:48 +02:00
Edward Firmo
2e33d94955 Clean-up Cover page
I'm preparing this page to have icons changing based on the device_class selected to a cover.
2023-09-02 00:35:32 +02:00
w00zy
52dddb800c update docs (#1003)
* updated docs

* Update ReleaseNotes.md

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-09-02 00:19:15 +02:00
Edward Firmo
0a3babfbce Clean-up page settings 2023-09-01 20:27:56 +02:00
Edward Firmo
0265dd8826 Update settings page when brightness changes on HA
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702149796
2023-09-01 14:06:49 +02:00
Edward Firmo
f4f80f667b Add translation keys for settings page
#1002
2023-09-01 08:09:21 +02:00
Edward Firmo
3345394bb4 Fix Settings page element ids
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1702109668
2023-09-01 06:09:29 +02:00
Edward Firmo
836cd1a047 Fix icon font sizes 10 and 64
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/960#issuecomment-1701903604

And also remove all the unnecessary `wait_until`
2023-09-01 05:02:23 +02:00
Edward Firmo
ba5db23ae6 Optimize wake_up_display service 2023-08-31 20:08:29 +02:00
Edward Firmo
32b62adc96 Support to wake-up page on wake_up_display service
This changes the behavior of a service introduced by #734.
2023-08-31 19:59:59 +02:00
Edward Firmo
7642088db0 Add "Alarm" section 2023-08-31 18:59:18 +02:00
Edward Firmo
17072c4144 Standardize close button 2023-08-31 18:48:29 +02:00
Edward Firmo
204f66a9bf Fixed background pics
- Entities pages
- Weather pages
2023-08-31 15:38:05 +02:00
Edward Firmo
960c055fb5 Clean-up TFT
- Removed a bunch of unused pics
- Changed page indicator to new format (which will allow future development to hide unused pages)
- Standardized close button in most pages
2023-08-31 14:27:25 +02:00
Edward Firmo
646152d3e1 Exported pics 2023-08-30 20:48:27 +02:00
Edward Firmo
b134eaa88a Alarm page translations - Finnish
https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6857262
2023-08-30 15:12:03 +02:00
Edward Firmo
4748739155 Move brightness control to global var
Clean up page Home
2023-08-30 15:08:28 +02:00
Edward Firmo
f29eeda845 Fix Climate page when embedded climate
And also added a lot of logs which should be removed later as it takes from memory.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/995#discussioncomment-6835260
2023-08-29 11:55:50 +02:00
Edward Firmo
44f233fa26 Create ReleaseNotes.md 2023-08-29 10:56:06 +02:00
w00zy
b5614bb3d8 uptime sensors (#998) 2023-08-28 19:28:30 +02:00
Edward Firmo
97109f4ba5 Phase out sensor nspanel_event (partially)
This sensor is being replaced by event calls.
2023-08-27 19:53:14 +02:00
Edward Firmo
0f49eb2f8c Clean up general entities & fallback
Store inputs into variables only when needed.
Removed fallback mode - Replaced by ESPHome local control when the relay is assigned to the button in the blueprint.
2023-08-27 10:50:38 +02:00
Edward Firmo
46a4b6929e Fix script call 2023-08-25 22:23:01 +02:00
Edward Firmo
15b453c3ab Removed ${verbose_log}
Use logger level `VERBOSE` instead
2023-08-25 22:19:54 +02:00
Edward Firmo
8989a65f03 Add support for addon_climate_cool 2023-08-25 22:00:46 +02:00
Edward Firmo
62d297c8a5 Simplify climate substitutions 2023-08-25 21:34:23 +02:00
Edward Firmo
71250e3d92 Rename addon_climate_heat 2023-08-25 21:26:55 +02:00
Edward Firmo
ab99a48f0a Bump version to 4.0 2023-08-25 12:02:35 +02:00
Edward Firmo
49b9ebe128 Fix Alarm page bypass icon 2023-08-25 11:46:08 +02:00
Edward Firmo
1638e2e3af New entity filter format
This new format was released with HA v2023.4 and the old one will be deprecated soon.
2023-08-25 11:45:28 +02:00
Edward Firmo
99b8b0ac11 Delete ReleaseNotes.md
Moved to the release
2023-08-25 10:14:22 +02:00
Edward Firmo
9cfd27ebf1 Adding screenshots 2023-08-25 10:13:36 +02:00
Edward Firmo
a907ff5004 Home buttons new format - Notification
Modernise the button "Notification" flow on page Home to improve performance.

I haven't moved the code from the Blueprint to ESPHome yet, as I will leave this for when we rebuild the Notification flow in the near future (hopefully), so the performance gains may not be perceived now. Just aligning with other buttons format.
2023-08-24 10:18:42 +02:00
Edward Firmo
27fc5c3e89 Home buttons new format - QRcode
Modernise the button "QRcode" flow on page Home to improve performance.
2023-08-23 22:18:31 +02:00
Edward Firmo
1ad3d7ef4b Home buttons new format - Entities
Modernise the button "Entities" flow on page Home to improve performance.
2023-08-23 20:04:37 +02:00
Edward Firmo
f399d757e5 Home buttons new format - Alarm
Modernise the button Alarm flow on page Home to improve performance.
2023-08-23 10:54:56 +02:00
Edward Firmo
c389c5b20b Fix alarm icon not updating on home page 2023-08-23 08:25:48 +02:00
Edward Firmo
b83c513093 Update alarm icon on home page
Refresh icon when alarm state changes.
2023-08-22 20:02:58 +02:00
Edward Firmo
2edfeef095 Support to code_arm_required
Only shows the alarm PIN keyboard if a code is required for arming (or when disarming).
2023-08-22 08:45:39 +02:00
Edward Firmo
3975806078 Removed fast_connect 2023-08-22 00:47:25 +02:00
Edward Firmo
99759008c8 Extended chars on buttons pages (#988)
Replaces #740
Probably solves #664
Probably solves #738
Probably solves #987
2023-08-21 22:07:56 +02:00
Edward Firmo
e96e342975 Revert fast_connect back to false 2023-08-21 21:25:10 +02:00
Edward Firmo
a339ef3c8f Update alarm icon & color 2023-08-21 18:22:16 +02:00
w00zy
be9b189a61 Human readable Uptime (#986)
* Human readable Uptime

* Uptime from Frenck code

* Uptime with Frenck code

* Updated Human Readable Uptime

* Removed trailing spaces

* Renamed sensor to "Last started"

Sensor renamed
Update moved to the boot process
Clean-up

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
Co-authored-by: Edward Firmo <edward@costafirmo.com>
2023-08-21 15:32:29 +02:00
Edward Firmo
d8e181fdda Move Entities button to ESPHome
Move logic behind Entities button (Home page) from Blueprint to ESPHome in order to gain performance on creating home page.
2023-08-17 20:23:25 +02:00
Edward Firmo
ad8e7e09c3 Alarm page UI
Fixed close button
Disabled buttons are darker
2023-08-17 10:36:11 +02:00
Edward Firmo
10698fa666 Fix alarm without pin not working
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/930#issuecomment-1680981977
2023-08-16 22:38:11 +02:00
Edward Firmo
fcc0477593 Alarm Control Panel with PIN (#982)
Implements an Alarm Control Panel page on NSPanel.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/66
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/227
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/672
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4874612
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/64#issuecomment-1566204490
Partially solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718
2023-08-16 17:03:41 +02:00
Edward Firmo
cb0e2aaa4b Add keyb_num page 2023-08-16 13:19:41 +02:00
Edward Firmo
6964af008b Alarm button font color 2023-08-15 21:00:28 +02:00
Edward Firmo
a4b201a2fa Create Alarm page 2023-08-15 20:48:46 +02:00
Edward Firmo
326746552a Add link to Alarm on page Home 2023-08-15 16:56:36 +02:00
Edward Firmo
680a5439ff Add Alarm page buttons pics 2023-08-15 15:23:55 +02:00
Edward Firmo
9157854799 Creating "install.md" and update add-ons instructions 2023-08-14 12:05:24 +02:00
Edward Firmo
da6d8c1c5e Add Alarm docs
Update docs to reflect the current state (new features & changes)
2023-08-11 11:11:09 +02:00
Edward Firmo
186447109b Add page Alarm 2023-08-11 00:46:18 +02:00
Edward Firmo
eddba39d4a Create Alarm page 2023-08-11 00:30:34 +02:00
Edward Firmo
96b3a375b0 Clean-up for customizations
Clean up ESPHome in order to make easier the use of customizations.
2023-08-10 11:27:58 +02:00
Edward Firmo
028a8c4a6f Create customization.md
This will reduce the need for:
- #920
- #662
- #833
2023-08-10 11:26:16 +02:00
Edward Firmo
ebe1e7243e Bump version to 4.0 dev 2023-08-10 09:33:22 +02:00
Edward Firmo
1965bedf3a Standardize HA service calls 2023-08-10 00:08:45 +02:00
Edward Firmo
e98ca4c8d4 Fix change brightness when sleeping
Prevents the panel to change screen brightness when sleeping.

Solves #975
2023-08-09 23:53:36 +02:00
Edward Firmo
62bdb576ab Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-08-09 23:22:50 +02:00
Edward Firmo
9556262880 Fixed link to addon climate docs 2023-08-09 23:14:05 +02:00
Edward Firmo
f1456dba3a Add-on support (#977)
Moved climate settings to an add-on.
Updated documentation.
2023-08-09 19:00:09 +02:00
bkbartk
8650b0814c dutch (#974)
* small ducht translations

small ducht translations

* Dutch translations

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-08-09 12:28:49 +02:00
Edward Firmo
55f84b400d Updated translations - Slovenian
Based on:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6665723
-  https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/829#discussioncomment-6665751
2023-08-09 09:43:42 +02:00
Edward Firmo
4971b7518b Make home page sensor's icons consistent
Make icon selection consistent with chips where the entity's icon is used in case a icon is not set in the blueprint settings.

Solves #963
2023-08-04 13:29:40 +02:00
Edward Firmo
9979058faf Updated translations - Spanish
Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6548961
2023-08-04 13:21:05 +02:00
Edward Firmo
21822dae37 Icons on ESPHome
Move icons from TFT/HMI to ESPHome to prevent error on Nextion2Text.
2023-08-03 23:53:06 +02:00
Edward Firmo
f7fb050e1d Fix call for fan stop button
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6622377
2023-08-03 22:46:10 +02:00
Edward Firmo
7ad95a66d8 Call a fan.turn_off when percentage is 0%
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6621756
2023-08-03 22:36:03 +02:00
Edward Firmo
669ead9e79 Fix fan.turn_off call
Removed timer call from fan stop button.
This solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6494535
2023-08-02 10:27:39 +02:00
Edward Firmo
dc787c5b0d Fix set_temperature for climate
Solves #957
2023-08-02 10:02:25 +02:00
Edward Firmo
cab3404645 Fix translations - Italian
Based on https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/940#discussioncomment-6511043
2023-07-21 19:09:33 +02:00
Edward Firmo
9aa8421117 Fix issue with restore_state and ESPHome v2023.7.0 (#941) (#943)
Solves #939
2023-07-19 18:56:15 +02:00
Edward Firmo
496392a382 Fix issue with restore_state and ESPHome v2023.7.0 (#941)
Solves #939
2023-07-19 13:54:54 +02:00
Edward Firmo
6ed378b8e0 Default embedded climate to relay_0 2023-07-19 13:08:08 +02:00
Edward Firmo
d329d92713 Fix "invalid variable" for "api"
Fix error "Nextion invalid variable name" when setting `api`.
2023-07-19 12:50:06 +02:00
Edward Firmo
2594df56ad Fix relays chips
Fix relay status indication on chips.

Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/926#issuecomment-1627660273
2023-07-19 11:09:13 +02:00
Edward Firmo
66e028f950 Align nspanel_us_land
Apply all changes from EU to US_Land
2023-07-19 10:11:53 +02:00
Edward Firmo
637b7b0477 US model - Fan page - Redistribute icons
Redistributed icons on Fan page on US model in order to improve usability.

Based on feedback from https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/791#discussioncomment-6338706
2023-07-19 10:01:10 +02:00
Edward Firmo
7d607f9936 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-07-19 09:49:20 +02:00
Edward Firmo
e3efb4dbe5 Removed restore_state
There is some incomplete work related to alarms on this commit, but the focus here is to fix `restore_state` on ESPHome v2023.7.0.

This solves #939
2023-07-19 09:49:09 +02:00
Edward Firmo
cbf00fec5e Update nspanel_esphome.yaml 2023-07-15 00:26:13 +02:00
Edward Firmo
a118536f4a support to hidden ssid (#908)
Supports hidden ssid with the use of substitutions `wifi_hidden: "true"`.

This can be breaking change for users with custom/advanced wifi settings.

Solves #906
2023-07-15 00:22:47 +02:00
Edward Firmo
c2ab8caeff Update ReleaseNotes.md 2023-07-10 14:03:51 +02:00
Edward Firmo
7104cbf0e9 Services back to the Blueprint
Moving service calls back to the blueprint as latest HA requires user's permissions to call HA services from ESPHome.
This still have to be used for Alarm calls due to security concerns.
2023-07-10 13:55:55 +02:00
Edward Firmo
9c3ae7a4f5 Update ReleaseNotes.md 2023-07-08 10:33:16 +02:00
Edward Firmo
f25ca0934c Embedded climate (#917)
* Performance improvements

The main focus here was to reduce the number of calls between Home Assistant and ESPHome, moving logic as much as possible to TFT and ESPHome.
- Service calls moved to ESPHome (in preparation for Alarm Control Panel)
- Page change informed via event call instead of `nspanel_event` sensor (which still in use by other calls, but might be possible to remove in the future)

* Draft embedded climate

This adds an initial version of an embedded climate/thermostat (heating only for now) with support for local control even with Wi-Fi out.

Solves #646
Solves #263

* Update ReleaseNotes.md

* Fix climate slider

Fix for climate slider opening in an incorrect position and sending only the integer part of the new target temperature

* Moving home page to ESPHome

In progress...

* Fix translations - Dutch

* Embedded chip 3

Home page - Chip 3 will be controlled locally when embedded climate is enable.

* Fixed buttons bar

Fixed buttons bar managed on ESPHome when embedded climate is visible.
2023-07-08 09:34:09 +02:00
Edward Firmo
64659f3794 Physical relay local control
We are trying to make your panel as autonomous as possible by moving some of the controls from the Blueprint to ESPHome. This will reduce the load in your network and Home Assistant, but also will make a more reliable system capable to do it's core functionality even when the network is unavailable or Home Assistant is restarting.
With this version, the following engines have been moved to your panel (local control):
- Physical relay control (when hardware left button is connected to relay 1 or right button to relay 2)

Solves #910
2023-07-03 08:14:32 +02:00
Edward Firmo
58a4575ab9 Prevents boot sequence in other pages 2023-07-03 07:15:05 +02:00
Edward Firmo
661e51671a Fixed Fan page rounding 2023-07-03 01:45:36 +02:00
Edward Firmo
d1c1dc018b Fix fan page button_on
Fixing rounding on that button.
2023-07-03 01:43:47 +02:00
Edward Firmo
ba8257e958 Fix call to screen page
Fixes the call to screen page on US panel.
Reconciliate the US landscape model from EU model.
2023-07-03 01:16:28 +02:00
Edward Firmo
3a95d5916e Boot page retry comm
The boot page will retry communication with the blueprint once a minute to avoid the situation where that page is shown until the automation is reloaded.
2023-07-02 23:55:08 +02:00
Edward Firmo
1287ff69ac Notification page bigger hotspot
Added hotspots around the buttons (Accept & Clear) on Notification page to make easier to click on those.

Solves #907
2023-07-02 22:44:02 +02:00
Edward Firmo
157472ee67 Time engine on ESPHome 2023-07-01 14:09:45 +02:00
Edward Firmo
ec99b83817 Time engine on ESPHome 2023-07-01 14:04:42 +02:00
Edward Firmo
8f81311203 Fix validation issue 2023-07-01 10:53:11 +02:00
Edward Firmo
2f6463b30a Exclude Nextion2Text
Exclude Nextion2Text
2023-07-01 09:17:52 +02:00
Edward Firmo
491472a364 "Jump to settings" on tft
Moved "Jump to settings page" routine from ESPHome to TFT in order to reduce complexity.
2023-07-01 09:14:35 +02:00
Edward Firmo
3aca4c64d2 Panel offline mode (#900)
* Panel offline mode

Introduces "offline mode" for the panel, which will be used later with a fallback climate.

Pages that are depending on the blueprint (buttons pages, entity pages, settings pages, etc) won't be shown when the API is disconnected.

* Panel offline mode

* Panel offline mode

* Panel offline mode

* Panel offline mode
2023-06-30 12:24:25 +02:00
Edward Firmo
ec48fbd335 Adding vertical bars pics 2023-06-30 11:20:26 +02:00
Edward Firmo
3b5fefe9fc Update ReleaseNotes.md 2023-06-30 02:45:28 +02:00
Edward Firmo
d018756673 Fan update engine
Change the fan update engine to follow the same patter as other settings pages.
2023-06-30 01:09:10 +02:00
Edward Firmo
ef7f3f1fa8 Select wake-up page (#898)
* Select wake-up page

Users will be able to select the wake-up page on the blueprint inputs.
This selected page will be shown after a boot (after the boot page) and with a touch in the screen when on screen saver page.
After showing this wake-up page, all the previous behavior for closing the page (with a click or after a timeout) will be the same.

Solves #576 
Solves #612 
Solves #801 
Probably improves for https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5715670

* Select wake-up page
2023-06-30 01:07:44 +02:00
Edward Firmo
fe3c1ebda1 Fix name on confirmation page
Fix the entity name on the confirmation page.

The new order is:
1. Name set on the blueprint settings
2. Entity's `friendly_name` attribute
3. Entity's `name` attribute
4. Entity's `entity_id`

Solves #501
2023-06-29 17:20:16 +02:00
Edward Firmo
f483a52242 Add Fan speed settings page (#897)
* Add Fan speed settings page

Add an initial fan speed control page for fans supporting speed control.
Add speed (%) info in the buttons pages.

Solves #404 
Solves #791 
Solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/718#discussioncomment-5786106

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page

* Add Fan speed settings page
2023-06-29 17:11:49 +02:00
Edward Firmo
822157f2e6 Update instructions.md 2023-06-29 14:18:08 +02:00
Edward Firmo
2d2b11f4fc Limit light & cover to supported settings (#896)
* Limit light to supported settings

When showing light settings, only the supported features will be shown for each light.

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

* Limit light to supported settings

This partially solves #635

* Limits covers to supported settings

Only show cover settings when `set_position` is supported.

This solves #635

* Limits covers to supported settings
2023-06-29 08:29:16 +02:00
Edward Firmo
9c6bcc07ae API status indication on the panel 2023-06-27 18:34:34 +02:00
Edward Firmo
5ff5d35833 Wifi icon to indicate when API offline
This changes the behavior of Wifi icon:

How it was before:
- Wifi icon was visible only when the wifi was connected, nothing was shown when wifi was not connected.

How it is now:
- Wifi icon will have 3 states:
 - Wifi & API connected: Gray wifi icon
 - Wifi disconnected: Red wifi-off icon
 - Wifi connected, but API disconnected (HA is out?): Red api-off icon
2023-06-27 17:42:23 +02:00
Edward Firmo
6dd6397fde Supports weather forecast with datetime not string
This adds support to weather integrations where the `datetime` field under `forecast` attribute is provided as a `datetime` type.
This was seen on Météo-France, while all other weather integrations tested so far used a `text` field for `datetime`.

This solves #893
2023-06-27 15:26:50 +02:00
Edward Firmo
26e41f0fc2 Fix "Button confirmation page not working correctly"
Solves #883
2023-06-27 08:55:58 +02:00
Edward Firmo
33539e8bbd Create nspanel_us_land.tft (#890)
* Create `nspanel_us_land.tft'

Add `nspanel_us_land.tft' for US panel on landscape mode, fixing the offset on the touch screen when using `nspanel_eu.tft` into a US panel.
Hides the hardware buttons labels, as Nextion cannot support rotated text.

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`

solves #390
solves #432
solves https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/299#discussioncomment-4933716

* Created `nspanel_us_land.tft`

* Created `nspanel_us_land.tft`
2023-06-26 20:21:14 +02:00
Edward Firmo
fe7c7ead18 Use en as fallback language (#891)
* Use `en` as fallback language

Uses English if a non valid language is selected (like when using legacy language selection).

* Use `en` as fallback language
2023-06-24 13:46:10 +02:00
Edward Firmo
2f44dd1d7c Move entity variable to home page (#889)
* Move `entity` variable to home page

This will enable future development of a fallback climate

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page

* Move `entity` variable to home page
2023-06-23 01:26:35 +02:00
Edward Firmo
c211d3f435 Remove settings_entity (#887)
* Remove `settings_entity`

- Bump version to 3.5_dev
- Removed references to pictures removed from TFT
- Removed code related to closing settings pages
- Removed trigger `settings_entity`

* Removed `set_settings_entity` service

- Bump version to 3.5_dev
- Removed `set_settings_entity` service - BREAKING CHANGE
- Removed `settings_entity` text-sensor - BREAKING CHANGE
- Added service `open_entity_settings_page` - BREAKING CHANGE

* Removed `settings_entity`

- Bump version to 3.5_dev
- Removed old climate page (climate_backup)
- Removed pics related to old climate page (ids 16-47, 80-83, 95-96 and 125(US only))
- Enforces brightness on any page change (this allows wake-up on settings page with long press on physical buttons) - Pending removing code from Blueprint
- Added `entity` variable on pages `climate`, `lightsettings` and `coversettings`
- Added `entity` info to `nspanelevent` on pages `climate`, `lightsettings` and `coversettings`
- Added `back_page` variable on pages `climate`, `lightsettings` and `coversettings` (default: home)
- Moving to TFT close page logic on pages `climate`, `lightsettings` and `coversettings` - Pending changes on Blueprint and ESPHome
- Standardized name for `page_label` on pages `climate`, `lightsettings` and `coversettings`
- Standardized settings page names: `climate`, `cover` and `light` (Removed `settings` from page name)

* Removed `settings_entity`

* Removed `settings_entity`

* Removed `settings_entity`
2023-06-22 14:16:47 +02:00
Edward Firmo
10da9a65c6 Update ReleaseNotes.md 2023-06-20 15:26:16 +02:00
Edward Firmo
47daf651e6 New language selector (#882)
* New language selector

* Update ReleaseNotes.md
2023-06-20 15:19:06 +02:00
Edward Firmo
f0b52a9e4d Sensor display precision (#880)
Now the values shown in your panel will follow the [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision) provided by Home Assistant.
=> If you have problems with a value exceeding the available space in your panel, please reduce the number of decimals using Home Assistant [sensor display precision](https://www.home-assistant.io/blog/2023/03/01/release-20233/#sensor-display-precision).
2023-06-20 12:45:07 +02:00
Edward Firmo
ae98178075 Filter devices to esp32 only (#881)
* Filter devices to esp32 only

Show only ESP32 devices when selecting the panel

* Filtered device list
2023-06-20 12:44:44 +02:00
Edward Firmo
36286bc457 Create ReleaseNotes.md (#879)
* Create ReleaseNotes.md

* sensor display precision
2023-06-19 19:56:36 +02:00
Blackymas
a47d8c3fbb v.3.4 - New climate page and some bug fixes
v.3.4 - New climate page and some bug fixes
2023-06-18 21:54:53 +02:00
Blackymas
2b62a770f7 v3.4 - New Climate Page and some bug fixes
v3.4 - New Climate Page and some bug fixes
2023-06-18 21:52:41 +02:00
Edward Firmo
e2c17c8716 Remove inputs for chip3 (Climate) (#874)
Removed all inputs related to customization of chip03 (Climate entity) and instead will follow the same icons and colors used by page climate, with a thermometer replacing the fire icon for heating.
2023-06-18 08:11:30 +02:00
Edward Firmo
0bce4c79b3 Change icon for heat in hvac_action 2023-06-15 17:02:37 +02:00
Edward Firmo
913dc39156 Update nspanel_blueprint.yaml 2023-06-15 10:10:25 +02:00
Edward Firmo
d722e115a8 Wake up screen with long press on button
This solves #558
2023-06-15 10:07:23 +02:00
Edward Firmo
5cfed28caf Fix incorrect variable climate_action_attr 2023-06-14 12:02:55 +02:00
Edward Firmo
74c1e22610 Fix hvac_action display 2023-06-14 11:26:24 +02:00
Edward Firmo
575bda2955 Remove hotwater (#866)
Now the custom icons can be used instead.
2023-06-08 15:48:56 +02:00
Edward Firmo
c1ef9eb92b Fix hvac_action indication icons (#865)
* Fix `hvac_action` indication icons

Fix for pages home and climate.
This should remove the need for all the 25~30 instances of hot water in the code.

* Update nspanel_esphome.yaml
2023-06-08 15:28:25 +02:00
Edward Firmo
4cb8bbe72e Climate - Custom buttons - Long press (#864)
* Climate - Custom buttons - Long press

This add long press functionality to Custom buttons and also fix a bug on short press.
I believe the new custom page is ready for get user's feedback with this.

* Climate - Custom buttons - Long press

* Climate - Custom buttons - Long press

* Climate - Custom buttons - Long press
2023-06-08 14:42:54 +02:00
Blackymas
25f6afcb8f fix some UI Design issues 2023-06-07 22:55:02 +02:00
Edward Firmo
b9bf5b95fa Climate - Custom buttons - Short press 2023-06-06 16:14:49 +02:00
Edward Firmo
8c9b135dc1 Climate - Custom buttons - Update status (#862)
Update status of custom buttons on climate page when the status changes.

=> Still missing to assign control to these buttons.
2023-06-06 12:41:51 +02:00
Edward Firmo
cc1f6999cc Climate - Custom buttons (#859)
* Climate - Custom buttons

Initial implementation of custom buttons on climate pages.

* Update nspanel_esphome.yaml

* Update tft files

* Update nspanel_eu_code

* update nspanel_us_code
2023-06-05 12:00:14 +02:00
Blackymas
6219ecdc79 new climate nspanel_us 2023-06-04 23:11:54 +02:00
Blackymas
0878696b79 climate nspanel_eu finish 2023-06-02 23:40:47 +02:00
Edward Firmo
ab067bd20c Climate page - Performance & bug fix (#854)
* Climate page - Performance & bug fix

Performance improvement:
- Moved icon definition to TFT, so only buttons related to supported hvac modes will be updated and just icon color and link enabling is sent.
Bug fixing:
- Removed incorrect button name on buttons update
Others:
- Merged `set_climate_target_temp` into `set_climate` services
- Update current temperature when target temperature is updated

* Removed reference to `set_climate_target_temp`

Removed unused entry from blueprint.

* Removed service `set_climate_target_temp`

* Update `nspanel_eu`

- Set climate buttons on the TFT.
- Bump version to 3.3.2 (temporarily, to align with ESPHome and Blueprint)

* Update `nspanel_eu_code`
2023-06-02 09:02:41 +02:00
Edward Firmo
3b4cc94518 Update translations - Swedish
From #845 by @rogerjak.
2023-06-01 18:58:04 +02:00
Edward Firmo
94d3157c4d Climate: support to target_temp_step (#853)
* Climate: support to `target_temp_step`

Adding support to attribute `target_temp_step` to define the step of changing temperature.
`0.5` will be used if this attribute is not available on the climate entity.

* Update nspanel_esphome.yaml

* Update nspanel_eu files

* Update nspanel_eu_code files
2023-06-01 18:30:16 +02:00
Edward Firmo
0e48d65549 2sec hold for sending target_temp (#851)
* 2sec hold for sending target_temp

Added 2sec hold of `target_temp` value before sending it to ESPHome and Blueprint, so the climate service is not called at every click on the slider or +/-.

* Update nspanel_eu_code
2023-05-30 17:07:22 +02:00
Edward Firmo
89e55a20d4 Fix buttons on climate page (#850)
* Fix buttons on climate page

Fix icon for dry and auto.
Move Off for last position.
Fix TFT sending incorrect id for buttons.

* Update TFT

* Update nspanel_eu_code
2023-05-29 21:08:07 +02:00
Edward Firmo
5298a0a032 Move target_temp set to TFT (#849)
* Move target_temp set to TFT

Use TFT to set target temp from slider and +/-.
Using decimals for slider.

* Update nspanel_esphome.yaml

* Update nspanel_eu files

* update nspanel_eu_code folder
2023-05-29 18:12:58 +02:00
Edward Firmo
410255ba37 Language update - NOR & FIN 2023-05-26 12:07:55 +02:00
Edward Firmo
5463e54926 Remove climate-optimistic mode (#841)
* Remove climate-optimistic mode

* Remove `send_thermostat_cycle_state` service

* Remove sensor `Display Target Temperature`

* Remove `display_target_temperature`
2023-05-26 11:49:20 +02:00
Edward Firmo
3e0cd4a9bd New climate page - Buttons (basic)
Initial implementation of buttons on the new climate page.
2023-05-25 15:56:14 +02:00
Blackymas
864abd24fc fix Button 7 and remove all default values 2023-05-24 23:20:43 +02:00
Edward Firmo
72705d9806 New climate page - Values 2023-05-24 21:24:11 +02:00
Edward Firmo
14283c0776 New climate page - basic support (#835)
* New climate page - basic support

Basic support to the new climate page.
Still pending values and buttons.

* Support to new climate services

* New climate page - basic
2023-05-24 18:38:41 +02:00
Edward Firmo
e5a702e541 Translations - ITA & HEB 2023-05-24 11:10:55 +02:00
Edward Firmo
8f80e1fb84 Translations - Spanish 2023-05-23 22:55:51 +02:00
Edward Firmo
5063b4a4c0 Translations - Croatian 2023-05-23 16:27:41 +02:00
Edward Firmo
f0549e2660 Translations - DEU & POL 2023-05-23 09:41:07 +02:00
Blackymas
d038bcc0d5 changed nspanel_us tft version 2023-05-22 22:38:57 +02:00
Edward Firmo
a28f1fb586 Translations - FRA & GRC 2023-05-22 15:49:27 +02:00
Edward Firmo
8ad3beb72f Add API connection status sensor (#774)
As requested by users:
- https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions/735#discussioncomment-5755419

Could this be used to prevent some of the "Loading..." or perhaps update screen when connection is reestablished?
2023-05-22 13:57:49 +02:00
Edward Firmo
1a46c85e6e Enable users select alignment for entity values (#753)
* Enable users select alignment for entity values

Users will be able to select the alignment for the column with values on the entity pages.
The options are:
- Right (default)
- Center
- Left

solves #732

* Add support to `xcen` on `set_entity`
2023-05-22 13:56:34 +02:00
Edward Firmo
3a5f562c20 More flexible date_format engine (#744)
* More flexible `date_format` engine

This is not changing anything for normal users other than minor UI on the blueprint setting, however will start using the `date_format` in a python standard string, but translating `%A` with existing weekdays in MUI.
Advanced users will be able to edit they automation yaml (either in `automations.yaml` file or editing the automation in yaml mode) in order to use any format they want.
=> This is not adding new translations to short week days or months, so if users add this in advanced mode, it will be shown in English.

* Added support for translation of date strings

Support translations to all date related strings.
=> Pending the translations - to ask support from the community.

* Support for custom date formats

* Fixed translation PRT

* Update nspanel_blueprint.yaml
2023-05-22 13:55:05 +02:00
Blackymas
70d62f51f8 add new climate
add new climate for nspanel_eu
add global variable home page for naspanel_us
2023-05-21 22:44:06 +02:00
Edward Firmo
c3acffd829 Auto-update entities pages (simplified) (#819)
This is a simplified version of #728 which is easier to maintain, as only conditions for entities pages have being added.
So the scope is limited to:
- Auto-update entity pages without compromising overall performance. (Entities page values not updating unless re-opened #410)
2023-05-18 14:53:37 +02:00
Edward Firmo
4688608ba1 Fix status bar error when no climate
Fix an issue on constructing the status bar when a climate entity is not defined.
2023-05-17 10:10:42 +02:00
Edward Firmo
221e3a168f Removed pages names from nextion var
To make it easier for future updates
2023-05-17 09:33:22 +02:00
Edward Firmo
bfbd95f9c1 Fix selectors for Button 32 (#818)
This closes #815
2023-05-17 09:02:23 +02:00
Edward Firmo
45725dc820 New time&date update strategy (#785)
Takes advantage of new global vars implemented by eee2bb7295
This will improve drastically the speed on displaying the Home page.
This push removes the update of date & time from the Home page and moved it to the time minute trigger (every minute), regardless the page shown (including when sleeping).
The time is also update after a boot (to ensure there's a time value when the Home page is displayed for the first time) and with an automation reload (just to cover the case when time format changes).
2023-05-09 17:02:16 +02:00
Blackymas
e55db10b70 home page local to global 2023-05-04 17:24:55 +02:00
Blackymas
ba82e08470 change home page local to global 2023-05-04 17:20:01 +02:00
Blackymas
eee2bb7295 change home page local to global 2023-05-04 17:16:28 +02:00
Edward Firmo
91dab53a59 Fix error when hw button is not on/off (#776)
This prevents message `Nextion reported variable name invalid!` when the button have a state other than `on` or `off`, like when it is connected to a stateless entity (scene, automation, etc.).
2023-05-04 00:04:56 +02:00
Edward Firmo
15aab73376 Fix sorting of language names 2023-05-02 18:22:45 +02:00
Edward Firmo
fc8108fc2c Fix units showing None when not available (#767)
This solves #766
2023-05-02 10:43:25 +02:00
Edward Firmo
0c5940c341 Fixed typo in source_url 2023-05-02 10:31:49 +02:00
Blackymas
666cd14789 v3.3 - fixed some bugs, performance, improvements
v3.3 - fixed some bugs, performance, improvements
2023-05-01 21:45:28 +02:00
Edward Firmo
0370c8143e Merge branch 'main' into beta 2023-05-01 21:29:09 +02:00
Blackymas
b20e80b840 v3.3 - fixed some bugs, performance, improvements
v3.3 - fixed some bugs, performance, improvements
2023-05-01 21:08:17 +02:00
Edward Firmo
adb4c8c12f Fix crash climate without temperature attrb (#762)
The systems won't crash if the climate entity doesn't have a `temperature` attribute.
It will try to calculate target from `target_temp_high` and `target_temp_low` otherwise will keep target temperature as empty.

This solves #749
2023-05-01 10:07:35 +02:00
Edward Firmo
b856619331 Fix units on indoor temperature (#757)
* Fix units on indoor temperature

It will now show units from ùnit_of_measurement` to keep consistence with other value entities on Home page.

This solves #755

* Removing redundancy
2023-04-30 12:33:14 +02:00
Edward Firmo
3f8b5ad3aa Fix missing icons (#752)
As per https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/657#issuecomment-1527333817
2023-04-29 13:44:10 +02:00
Edward Firmo
8b06ce15aa Chips to support boolean entities (#748) 2023-04-28 13:51:01 +02:00
Edward Firmo
6bb54394a0 Moved page labels inputs to the page items (#746)
This solves #742
2023-04-28 07:58:18 +02:00
Edward Firmo
0bd3200155 Update CONTRIBUTING.md 2023-04-28 01:16:22 +02:00
Edward Firmo
8d22fdb41c Removed duplicated entry for OpenWeatherMap 2023-04-27 21:49:47 +02:00
Edward Firmo
3a08cfc583 Fixes name on cover settings page (#741)
solves #739
2023-04-27 13:35:13 +02:00
Chris
7677934244 Merge pull request #737 from deejaybeam/dev
fix: current_page does not extist anymore
2023-04-26 23:40:55 +02:00
Chris
13726fa08e Merge branch 'Blackymas:dev' into dev 2023-04-26 23:40:22 +02:00
deejaybeam
f609e92c0d fix: current_page does not exist anymore 2023-04-26 23:39:35 +02:00
Edward Firmo
085842a8e9 Removed filter from device selection
To keep compatibility with HA 2022.11.1.
2023-04-26 23:33:04 +02:00
Edward Firmo
89ad6426ed Fixes icon for unavailable (#736) 2023-04-26 23:19:01 +02:00
denes44
f3cfa2c8ed Wake up panel service call (#734)
* Add service call for waking up the display

* Option to reset the sleep and page timers
2023-04-26 23:11:05 +02:00
Edward Firmo
a34f51e6b6 Introduces show_while_loading mode (#731) 2023-04-26 22:05:15 +02:00
Edward Firmo
222ae92d36 Update README.md (#727) 2023-04-26 22:04:15 +02:00
Edward Firmo
b05633aae5 Rebuild Sleep mode switch (#719) 2023-04-26 22:03:54 +02:00
Edward Firmo
32b98e09f6 Creating CONTRIBUTING.md (#700) 2023-04-26 22:03:06 +02:00
Edward Firmo
c78ea43ea2 Fix light/cover settings page appearing on swipe 2023-04-26 13:21:06 +02:00
Edward Firmo
355a643ff7 Visual feedback for stateless entities (hw button) (#725)
Implement visual feedback for stateless entities (whatever finishes with a state other than `on`, `off`, `open` and `closed`, like scenes, automations, buttons, etc.).
This extends b18f2848f4 and solves #691.
2023-04-25 21:00:30 +02:00
Edward Firmo
a252ddf74e Fix: button not updating with external changes (#721)
* Fix: button not updating with external changes

* Removed debug code

* Revert trigger_id change
2023-04-24 20:52:05 +02:00
deejaybeam
8ca88755c1 fix: follow new default-mode esphome 2023.4 2023-04-24 17:55:36 +02:00
Edward Firmo
32f297353a Fix issue with light settings page opening with 0% 2023-04-24 13:11:45 +02:00
Edward Firmo
41d6acdf36 Changes to nextion_inited to become a sensor (#715)
* Changes to nextion_inited

Changed from `switch` named `Nextion inited` (with entity_id like `switch.xxxx_nextion_inited`) to a `binary_sensor` named `Nextion display` (`binary_sensor.xxxx_nextion_display`).
The idea is to avoid users trying to change it's state from Home Assistant (with unknown consequences) and make this entity more clear, improving usability.

* Change `nextion_inited` to a sensor
2023-04-24 12:42:06 +02:00
Edward Firmo
19e6374e03 Rename 'Sleep mode' switch (#714)
* Rename 'Sleep mode' switch

Renamed from `Sleep Modus` to `Sleep mode`.

Breaking change: This will rename the entity_id of that switch and this can affect existing automations created by users and also will require changes in the blueprint if #698 is merged.
Note: Variable names in HMI/TFT not renamed.

* Align with other PR
2023-04-24 12:40:44 +02:00
Edward Firmo
374502c6d8 Replaces the white screen by a QR code (#701)
The QR code have a link to the repository, but perhaps this could be changed later to point directly to a page with instruction of what to do if a user see that screen.
The file is growing by less than 1kb and I believe a QR code with a link gives to the users a better feeling than a totally white screen where they cannot interact with.
2023-04-24 12:35:51 +02:00
Edward Firmo
f9776463c1 Wake-up panel when sleep mode is disabled (#698)
The panel will wake-up to Home page if it is on screen saver page (sleeping) when sleep mode is disabled.

This solves #696
2023-04-24 12:34:53 +02:00
Edward Firmo
f48a58a76a Standardize inputs descriptions (#694)
* Standardize inputs descriptions

Standardize the descriptions on all inputs (visible to users when setting up the Blueprint)

* Removing trailing spaces
2023-04-24 12:34:04 +02:00
Edward Firmo
d7944855ad Fixes to translations in POL as per #695 (#705) 2023-04-23 21:41:51 +02:00
Edward Firmo
9ef8287be7 Fix error on weather pages pic
The weather picture was broken when breaking down that line of code.
2023-04-23 18:52:17 +02:00
Edward Firmo
c750971b0e Standardize yaml
To improve readability.
No changes in the code.
2023-04-23 15:42:17 +02:00
Edward Firmo
36a0811776 Standardize yaml
No changes in functionalities, just removing blank lines and indentation of comments.
2023-04-23 14:29:57 +02:00
Edward Firmo
508dbd01a8 Clean up (#704)
* Break down long lines

To improve readability.

* Update nspanel_blueprint.yaml

* Breaking down long lines

To improve readability.

* Clean-up

* Breaking down long lines
2023-04-21 14:13:59 +02:00
Edward Firmo
ebb37b85c8 Fix translations to FIN as per #703 2023-04-21 14:07:35 +02:00
Edward Firmo
8e04a34e41 Code clean-up 2023-04-21 10:42:13 +02:00
Edward Firmo
8a510086b1 Standardize the use of ' and " in the code (#702)
The new standard for code will be like this:
`var: '{{ state_attr(entity_id, "friendly_name") }}'`
2023-04-21 10:03:15 +02:00
Edward Firmo
f01f3d5e4e Used aliases for element on home page (#697)
- Removed duplicated code used to update element in the home page and used aliases instead.
- Breaking down long lined to improve readability.
2023-04-20 13:08:31 +02:00
Edward Firmo
e78b77de9e Added link to yamllint docs 2023-04-20 12:08:16 +02:00
Chris
42766724fa upd: bump to version 3.3 2023-04-19 23:50:03 +02:00
deejaybeam
2cf447f660 upd: remove trailing spaces 2023-04-19 23:37:01 +02:00
deejaybeam
b18f2848f4 fix: visual feedback for stateless entities 2023-04-19 23:30:46 +02:00
Edward Firmo
a1d1bac49f Removing unnecessary blank spaces 2023-04-19 18:03:16 +02:00
Edward Firmo
37cda13162 Breaking down long lines to make it more readable 2023-04-19 17:53:10 +02:00
Edward Firmo
1a1b190e5e Breaking down long lines to make it more readable 2023-04-19 17:45:05 +02:00
Edward Firmo
633f58d074 forbid-duplicated-anchors 2023-04-19 17:31:20 +02:00
Edward Firmo
624fd832e3 Fix inputs based on #692
Fixes items 1 & 2 of #692
2023-04-19 14:02:06 +02:00
Edward Firmo
60c43e99bd Add validation actions (#693)
* Add validation action

* Clean-up yaml

Removed trailing spaces

* Clean-up yaml

Removed trailing spaces

* Clean-up yaml

Removed trailing spaces

* Clean-up yaml

Removed trailing spaces

* Clean-up yaml

Removed trailing spaces

* Update validate_yaml.yml

* Validate on push

Only for nspanel_esphome.yaml and nspanel_blueprint.yaml

* Extending warnings for +255-char lines

* Update validate_yaml.yml

* Clean-up yaml

* Update validate_yaml.yml

* Clean-up yaml

* Clean-up yaml

* Clean-up yaml

* Clean-up yaml

* Clean-up yaml

* Update and rename validate_yaml.yml to validate_blueprint.yml

* Create validate_esphome.yml

* Clean-up yaml
2023-04-19 13:16:28 +02:00
Edward Firmo
cf5829af8f Removing extra line 2023-04-18 21:56:20 +02:00
Chris
6de0c44b14 Nspanel event (#689)
* upd: hmi2txt export

* upd: sync latest dev

* upd: currentpage

* upd: lightsettings

* upd: coversettings

* upd: touchevent

* Fix error preventing long click on button pages

* upd: climate

* upd: lastclick w.o. blueprint

* Upd: Long_press - Lights

* Update: Everything else (#688)

Still a bug with confirmation message and long press button.

* Fix: Notifications

* Fix: Button long press

* Fix: Climate page

* Fix: Indoor temp when no sensor defined

* fix: open climate from homepage triggers mulitple

---------

Co-authored-by: Edward Firmo <94725493+edwardtfn@users.noreply.github.com>
2023-04-18 21:54:04 +02:00
Edward Firmo
736c2c777a Fix error preventing long click on button pages 2023-04-17 11:26:47 +02:00
Chris
eb748457df Merge pull request #682 from Blackymas/dev
new beta
2023-04-15 16:00:53 +02:00
deejaybeam
e597ad5c59 upd: comments 2023-04-15 15:30:08 +02:00
Edward Firmo
ec68abb7e3 Fix button showing as unavailable on HA restart
Buttons should show as `off` when state is `unknown`.
Same is valid for:
- button
- input_button
- scene
2023-04-15 14:53:02 +02:00
Chris
38272052d7 Merge pull request #681 from deejaybeam/dev
Dev
2023-04-15 14:04:29 +02:00
deejaybeam
d23f53b9d2 Merge branch 'dev' of https://github.com/deejaybeam/NSPanel_HA_Blueprint into dev 2023-04-15 14:03:03 +02:00
Chris
c031cfee22 Merge pull request #679 from Blackymas/edwardtfn-patch-3
Improved weather pages
2023-04-15 13:57:19 +02:00
Chris
12200c80c8 Merge pull request #674 from Blackymas/edwardtfn-patch-2
Change panel selector to built in device selector
2023-04-15 13:02:44 +02:00
Chris
6e4e5ab817 Merge pull request #1 from Blackymas/edwardtfn-patch-2
New Panel selector and a weather backup selection
2023-04-15 12:56:43 +02:00
Edward Firmo
d9de15be10 Improved weather pages
Tested with the following integrations:
- AccuWeather - Better when forecast is enabled
- Met.no - Better when hourly entity is enabled
- OpenMeteo
- OpenWeatherMap
- SMHI
2023-04-15 11:11:13 +02:00
Edward Firmo
576c08c658 Narrowing down the list od devices 2023-04-15 06:47:55 +02:00
Chris
d29517c127 Merge pull request #676 from deejaybeam/dev
upd: set_entity-service
2023-04-14 23:23:01 +02:00
deejaybeam
642a78364a upd: set_entity-service 2023-04-14 23:22:19 +02:00
Chris
2627d993c1 Merge pull request #675 from deejaybeam/dev
fix: button to exit reparse-mode on factory-device
2023-04-14 20:31:40 +02:00
deejaybeam
9d822e7ee9 fix: button to exit reparse-mode on factory-device 2023-04-14 20:25:13 +02:00
Edward Firmo
03c05ff084 Fix input descriptions for icons
To support the new icon format.
2023-04-14 17:32:18 +02:00
Edward Firmo
5604235ded Change panel selector to built in device selector
1. The blueprint will now ask for user to select the panel from the list of ESPHome devices instead of typing it's name, in order to reduce the chance of an error
-> The old name format still supported, so this is not a breaking change.

2. If a weather entity is not provided, the blueprint will pick one weather entity available, if any.
2023-04-14 15:14:06 +02:00
Chris
53b7d9af6f Merge pull request #667 from doron1/patch-1
Update the correct Nextion variable for sleep modus
2023-04-14 11:50:43 +02:00
Edward Firmo
433e83d931 Add support to change baud rate with Nextion (#662)
* User's defined baud_rate

* Update nspanel_esphome.yaml

* Bump version to 3.2.3
2023-04-14 00:49:25 +02:00
Edward Firmo
5d523eabd6 Supports icon from attributes for chips 2023-04-13 14:20:29 +02:00
Edward Firmo
cfb076a01b Support for icon from attributes on Entities pages 2023-04-13 13:53:35 +02:00
Edward Firmo
1d2138fefd Use Home Assistant icon selector for icons (#657)
* Use Home Assistant icon selector for icons

Replace all icon selection to Home Assistant native icon selector, improving the user experience.

Note: As not all the MDI icons are available for Nextion, if one of those icons is selected it will be displayed as a question mark `?`.

* Fix button icon when unavailable

Apply fixed from PR#660 into this branch to avoid merging conflicts in the future.

* Supports legacy icon selection

This add the support for legacy icon selection, so icons will still be shown if users install the new version in an environment where icons where previously selected.
2023-04-13 13:16:52 +02:00
EnginDzhemil
e1b1543a25 fix bulgarian translation (#669)
Co-authored-by: Engin Dzhemil <engin.dzhemil@openpayd.com>
2023-04-12 21:32:22 +02:00
Edward Firmo
13d4156ef1 Fix position of values on page home (#661)
Fix error where values in the page home could be assigned to another component if a previous component have a state unknown or unavailable.
2023-04-12 21:30:49 +02:00
Edward Firmo
877dc316ff Fix button icon when unavailable (#660)
Button pages will show a mdi:alert-circle when an entity is unavailable, just like before.
2023-04-12 21:30:09 +02:00
doron1
b0ea3ef63d Correct Nextion variable for sleep modus
Code was updating the wrong (probably old) variable name on the panel, when the "sleep" button is pressed in settings page
2023-04-12 20:49:57 +03:00
Edward Firmo
76abf9611d Update clock at the beginning of each minute
This was already implemented on #543 but it was lost later:

As it is now, using minutes: "/1", the time will update every minute, but that could happen when lots of seconds has passed on that minute, making possible the displayed time to be up to 59s late.
By changing that to seconds: 0 if forces the update in the same rate, but always in the first second of a minute, keeping the displayed time always updated.
2023-04-12 19:25:18 +02:00
Blackymas
27d1846c2b add some bug fixes and performance improvements
add some bug fixes and performance improvements
2023-04-11 00:27:38 +02:00
Edward Firmo
56f27d1a86 Reduce # of concurrent instances of blueprint
This reduces the number of parallel instances of the blueprint running. I've done several tests and couldn't see more than 10 instances, so I believe if we should limit the concurrent runs and this will probably be an indication of a problem we want to know about.
2023-04-11 00:05:01 +02:00
Edward Firmo
95ff13d831 Convert napanel_name to a valid format (#647)
This supports users mistyping the NSPanel name in the blueprint settings. One of the most common mistakes is using `-` in the name, instead of `_` and this change will try to replace that when users type the name with this invalid char.
2023-04-10 23:58:12 +02:00
Edward Firmo
59727e294d Home page: Removing unnecessary calls to panel (#629)
Trying to gain a bit on performance by not sending calls to the panel when not needed (element not available, etc.).
2023-04-10 23:57:35 +02:00
Edward Firmo
1ea041c731 Fixed translation (Spanish)
As per 342a5ae1b8 (r108312227)
2023-04-10 17:43:15 +02:00
Edward Firmo
3134f07671 Fix input descriptions to entity pages (#634)
It was incorrectly describing BUTTONPAGExx instead of ENTITYPAGExx.

This fixes #633
2023-04-07 12:12:53 +02:00
Edward Firmo
36d2cf2f21 Fixes to Croatian string formats
#628
2023-04-07 11:55:27 +02:00
Edward Firmo
adbe6a4dc6 Fix translations to Croatian
#628
2023-04-07 08:22:27 +02:00
Blackymas
6397053d25 Add time format 24h without leading zero
Add time format 24h without leading zero
2023-04-07 00:55:49 +02:00
Edward Firmo
f5781d48b3 Add "Croatian" as supported language (#632)
#628
2023-04-06 21:45:40 +02:00
Edward Firmo
cf1ed9aa66 Fix: Variable date_format missing
Moving the variable definition back to the root.
2023-04-06 12:49:18 +02:00
Edward Firmo
03498a2b79 Fix: Date format not applied when time changes 2023-04-06 12:41:19 +02:00
Edward Firmo
cee264d769 Add time format 24h without leading zero
To be consistent with the new date format added on v3.2.3.
2023-04-06 09:41:58 +02:00
Edward Firmo
c931e551c8 Bug fixed: Removed duplicated line 2023-04-06 00:36:48 +02:00
Blackymas
f4e8d3b006 Bump blueprint version to `3.2.3
Bump blueprint version to `3.2.3`
2023-04-06 00:30:13 +02:00
Edward Firmo
4fc9f98ce8 Bump blueprint version to 3.2.3 2023-04-06 00:27:00 +02:00
Edward Firmo
5a0715064d Roll back temperature units to fit screen (#625)
This should fix #617
2023-04-06 00:19:43 +02:00
Edward Firmo
124b9d87d5 Remove + from positive temperatures (#624) 2023-04-06 00:14:10 +02:00
Edward Firmo
84c9f073bd Added continue_on_error to service calls (#608)
This will make the automation more resilient, however it could hide some errors, making a bit harder to troubleshoot.
2023-04-06 00:13:08 +02:00
Blackymas
05f68816c6 change weather field temp chars 2023-04-05 23:46:42 +02:00
Blackymas
25315afe11 fix weather temp field chars 2023-04-05 23:11:00 +02:00
Blackymas
fde287199d Code optimization
Code optimization
2023-04-05 22:57:27 +02:00
Blackymas
a595600669 Support for opening & closing states on buttons
NEW: Support for `opening` & `closing` states on buttons
2023-04-05 22:56:39 +02:00
Blackymas
246eed6df3 Removed "Weather integration" selection from setup
NEW: Removed "Weather integration" selection from setup
2023-04-05 22:56:13 +02:00
Blackymas
db4ffb9c17 Fixed translation strings to Spanish & Portuguese
Fixed translation strings to Spanish & Portuguese
2023-04-05 22:54:53 +02:00
Blackymas
79c2b1533a Performance improvement: Temperature min/max
Performance improvement: Temperature min/max
2023-04-05 22:54:30 +02:00
Blackymas
9def80eae6 new temp field weather01-04 2023-04-05 22:25:35 +02:00
Edward Firmo
fa2ef5173b Performance improvement: Temperature min/max
- Merge the 3 calls needed to create the temperature min/max display on the Weather pages into just one call per page.
2023-04-05 19:26:11 +02:00
Edward Firmo
342a5ae1b8 Fixed translation strings to Spanish & Portuguese 2023-04-05 13:43:04 +02:00
Edward Firmo
92753d5ca4 Removed "Weather integration" selection from setup
The weather integration is now automatically detected by the Blueprint, based on the attributes provided by the integration itself, so an user selection is not needed anymore.
2023-04-05 13:09:43 +02:00
Edward Firmo
0eef377ca9 Support for opening &closing states on button
- Button pages now displays cover status when is is `opening` or `closing`.

This probably solves #451
2023-04-05 09:38:49 +02:00
Edward Firmo
a831d189d8 Code optimization 2023-04-05 08:58:11 +02:00
Edward Firmo
2a5f3124d5 Fix first button not responding to short press (#603) 2023-04-05 02:04:12 +02:00
Edward Firmo
f871ef84e9 Fix date format on home page (#602)
* Fix date format on home page

To use custom date format

* Remove debug call
2023-04-05 02:02:32 +02:00
Edward Firmo
383835d710 Add cover battery when not as an attribute (#601)
- It will try to find a battery sensor withing the same device.

This should fix #153
2023-04-05 02:02:04 +02:00
Edward Firmo
601568b6f0 Fix on date format (copy #568 to DEV) (#600)
https://github.com/Blackymas/NSPanel_HA_Blueprint/pull/568
2023-04-04 23:50:00 +02:00
Blackymas
60afcf60cc Merge pull request #568 from albinmedoc/main
fix: corrects date_format
2023-04-04 23:44:06 +02:00
Edward Firmo
a351eece0b Removing empty lines (merging conflicts) (#598) 2023-04-04 23:41:56 +02:00
Edward Firmo
10a9e417ea Code refactoring (#565)
* Code refactoring - Nextion constants - Colors

No changes in functionalities. Just renaming variables related to colors in order to improve readability.

* Code refactoring - Nextion constants - Icons

* Adding aliases on the first level actions

This will make easier troubleshooting as aliases are shown in the logs.

* Nextion constants - Pages

* Nextion constants - Commands

* Nextion constants - Other pics

* Fixed typo in nextion.pics.hardware.button

* Fixed " 'mui_weekday_today' is undefined"

* Code refactoring/standardization

Refactoring:
- Weather pages
 - It might support any weather integration now, including OpenWeather)
 - New string for translation (when weather info is not available for a certain day)
- Home page (partial)

* Fix bug "'home_page_values' is undefined"

* Code refactoring - Button pages

Rebuilt button pages in order to improve readability and maintainability.
No changes on functionalities,

* Changed blueprint version to v3.2.2

* Refactoring entities pages

* Reorganizing inputs to improve readability

* Bug fixes: qrcode icon & weather provider

- Fixed bug preventing to detect that QR Code was enabled in order to display the QR code icon on Home page
- Fixed weather integration detection

* Review states(entity_id) to make it more resilient

Reduce the chances of crash if a `states(entity_id)` returns an error.

* Make state_attr(entity_id, attr) more resilitent

To avoid crashes with an invalid return.

* Perf improv: Don't load weather vars unless needed

Performance improvement - don't load weather vars when those are not needed.

* Using alias for delay_value

To make easier to maintain the code.

* Code refactoring: Button press/status

Optimizing code in order to improve readability & maintainability.

* Reorganizing pages variables
2023-04-04 23:38:00 +02:00
Blackymas
787f337220 v3.2.2 - fixed some bugs performance improvement
v3.2.2 - fixed some bugs performance improvement
2023-04-04 08:37:14 +02:00
Blackymas
44aaea74ec change weather params
Change order of weather params to fit the screen (#592)
2023-04-04 08:25:30 +02:00
Edward Firmo
4a346ce2d2 Change order of weather params to fit the screen (#592) 2023-04-04 07:11:43 +02:00
Blackymas
4ead4382a2 Merge pull request #591 from Blackymas/dev
fix for wakeup sleep mode
2023-04-03 22:43:19 +02:00
Blackymas
1e64e134f9 fix for wakeup sleep mode 2023-04-03 22:37:57 +02:00
Blackymas
68190ece4b Merge pull request #589 from Blackymas/dev
v.3.2.2 - fixed some bugs
2023-04-03 21:14:34 +02:00
Blackymas
81d0bcf304 change description 2023-04-03 21:13:30 +02:00
Blackymas
94364d711e Merge pull request #585 from Blackymas/dev
v.3.2.2 - fixed some bugs
2023-04-03 16:40:51 +02:00
Chris
2953942fbd Merge pull request #584 from deejaybeam/dev
v3.2.2
2023-04-03 08:28:08 +02:00
Chris
51173352d2 Merge branch 'Blackymas:dev' into dev 2023-04-03 08:26:05 +02:00
Chris
1bec2b1160 upd: v3.2.2 2023-04-03 08:21:35 +02:00
Blackymas
4921453a1b fix variables for v3.2.2 2023-04-02 22:32:42 +02:00
Blackymas
95a4447eeb Update page_id & component_id 2023-04-02 22:30:05 +02:00
deejaybeam
350b3f4ca7 upd: use set_button on all button pages 2023-04-02 08:55:30 +02:00
deejaybeam
a8172a1b06 fix: fallback state 2023-04-02 08:49:02 +02:00
deejaybeam
df10d09736 upd: use current nextion-component 2023-04-01 02:17:04 +02:00
Chris
4f31326b8e Merge pull request #578 from deejaybeam/dev
fix: avoid "0" brightness in some cases
2023-04-01 02:12:20 +02:00
deejaybeam
f0e557b5e4 fix: avoid "0" brightness in some cases 2023-04-01 02:11:00 +02:00
Chris
80d19b1da1 Merge pull request #577 from deejaybeam/dev
upd: service set_button to improve performance
2023-03-31 23:24:33 +02:00
deejaybeam
df0855862f upd: service set_button to improve performance 2023-03-31 23:23:43 +02:00
Albin Medoc
12f22554d8 fix: corrects date_format 2023-03-30 11:06:29 +02:00
Edward Firmo
d23fe9616c fix: ignore unassigned indoor sensor
Fix for when sensor is set but unavailable.
2023-03-29 15:49:29 +02:00
Chris
76fee43d3b Merge pull request #561 from deejaybeam/dev
fix: ignore unassigned indoor sensor
2023-03-29 11:01:50 +02:00
deejaybeam
e8fd5e2020 fix: ignore unassigned indoor sensor 2023-03-29 11:00:50 +02:00
Chris
89faeb3ec1 Merge pull request #525 from edwardtfn/patch-19
Code refactoring - Weather & Climate
2023-03-28 22:35:38 +02:00
Chris
a006af2654 Merge pull request #537 from edwardtfn/patch-21
Removing empty sequences
2023-03-28 22:34:07 +02:00
Chris
4ea23c7cf5 Merge pull request #543 from edwardtfn/patch-23
Update clock at the beginning of each minute
2023-03-28 22:33:39 +02:00
Chris
1e7ead8e46 Merge pull request #556 from deejaybeam/dev
fix: typo
2023-03-28 19:16:42 +02:00
deejaybeam
d88290474e fix: typo 2023-03-28 19:11:12 +02:00
Blackymas
75f17f0d3e fix sleep button settings page 2023-03-27 22:05:17 +02:00
Edward Firmo
8a21f88df9 Merge branch 'dev' into patch-19 2023-03-27 00:51:40 +02:00
Edward Firmo
5a01431670 Resolving merging conflicts with #541 2023-03-27 00:46:20 +02:00
Blackymas
7c90677d99 Merge pull request #544 from Blackymas/beta
v3.2.1 - new features and fixes
2023-03-26 22:28:01 +02:00
Blackymas
fe65530eb5 Merge pull request #542 from Blackymas/dev
v3.2.1 - new features and fixes
2023-03-26 22:27:33 +02:00
Edward Firmo
ecd806b1c5 Update clock at the beginning of each minute
As it is now, using `minutes: "/1"`, the time will update every minute, but that could happen when lots of seconds has passed on that minute, making possible the displayed time to be up to 59s late.
By changing that to `seconds: 0` if forces the update in the same rate, but always in the first second of a minute, keeping the displayed time always updated.
2023-03-26 22:26:55 +02:00
Chris
72e59947b6 Merge pull request #541 from deejaybeam/dev
fix: remove unneeded home.hotwater.pic
2023-03-26 21:15:33 +02:00
Chris
8869eb2f67 Merge branch 'Blackymas:dev' into dev 2023-03-26 21:14:55 +02:00
deejaybeam
c7c54261cb Merge branch 'dev' of https://github.com/deejaybeam/NSPanel_HA_Blueprint into dev 2023-03-26 21:14:25 +02:00
deejaybeam
27185ea88c fix: remove unneeded home.hotwater.pic 2023-03-26 21:14:14 +02:00
Chris
bfe2c65bfd Merge pull request #540 from deejaybeam/dev
upd: blank.tft
2023-03-26 21:10:32 +02:00
Chris
45dafc3d0d Merge branch 'Blackymas:dev' into dev 2023-03-26 21:09:41 +02:00
Blackymas
c9c31bba57 size for the Date field 2023-03-26 20:54:13 +02:00
Chris
485e5cc8d2 Merge branch 'dev' of https://github.com/deejaybeam/NSPanel_HA_Blueprint into dev 2023-03-26 19:59:44 +02:00
Chris
175c927ee8 upd: blank.tft 2023-03-26 19:59:38 +02:00
Edward Firmo
4392bf251b Fix variable name hotwater_pic_on -> hotw_bt_on
Trying to avoid merging conflict with #538
2023-03-26 17:54:06 +02:00
Edward Firmo
9616ea4c8f Merging weather01 page into the others
- All the weather pages now shares the same code, increasing standardization
- Support for other forecast parameters when supported by the integration
- Removed empty rows between the forecast parameters
2023-03-26 17:21:10 +02:00
Edward Firmo
2a9162e809 Removing empty sequences
This probably isn't an issue, but a sequence shouldn't be empty.
2023-03-26 16:11:39 +02:00
Blackymas
df976b0a90 Merge pull request #533 from Blackymas/dev
v3.2.1 - new features and fixes
2023-03-26 00:44:23 +01:00
Chris
220b5fb02b Merge pull request #532 from deejaybeam/dev
fix: remove hp-bottons on disable in blueprint
2023-03-26 00:41:11 +01:00
deejaybeam
a0a0d16af7 fix: remove hp-bottons on disable in blueprint 2023-03-26 00:40:42 +01:00
Blackymas
f97b298d00 repositioning date and time 2023-03-26 00:19:18 +01:00
Chris
6feba8a56d Merge pull request #531 from deejaybeam/dev
upd: remove unneeded link
2023-03-25 23:50:25 +01:00
deejaybeam
0ff61a2e4a upd: remove unneeded link 2023-03-25 23:49:53 +01:00
Blackymas
aee6e7bb57 repositioning date 2023-03-25 23:45:05 +01:00
Chris
602a58cc40 Merge pull request #530 from deejaybeam/dev
fix: hw-button hold display
2023-03-25 23:36:57 +01:00
Chris
5e45641687 Merge branch 'Blackymas:dev' into dev 2023-03-25 23:36:19 +01:00
deejaybeam
8b2beec50c fix: hw-button long press display 2023-03-25 23:26:44 +01:00
Blackymas
3278de673a new time format 2023-03-25 23:19:11 +01:00
Blackymas
3cf5fb3eeb new time format 2023-03-25 23:15:56 +01:00
Chris
d53a34b83f Merge pull request #529 from deejaybeam/dev
upd: reload automation triggers page refresh
2023-03-25 15:29:05 +01:00
deejaybeam
e4f0dba8fa upd: reload automation triggers page refresh 2023-03-25 15:28:08 +01:00
Chris
3ea33a6dfa Merge pull request #528 from deejaybeam/dev
upd: blueprint version 3.2.1
2023-03-25 12:42:48 +01:00
deejaybeam
6b11ffb7cf upd: bluleprint version 3.2.1 2023-03-25 12:41:54 +01:00
Chris
3047204272 Merge pull request #527 from edwardtfn/patch-20
Add support to `input_boolean` to chips
2023-03-25 12:37:56 +01:00
Chris
61af338a96 Merge pull request #522 from edwardtfn/patch-18
Fix for warning "list object has no element n"
2023-03-25 12:35:25 +01:00
Chris
729414944b Merge pull request #521 from edwardtfn/patch-17
Fix "Loading..." when selected before RGB picker
2023-03-25 12:34:29 +01:00
Chris
22dbd2814b Merge pull request #519 from bakito/patch-2
Ignore IntelliJ IDEA project directory
2023-03-25 12:34:00 +01:00
Edward Firmo
44836d1e4d Add support to input_boolean to chips
- Chips now supports `input_boolean` entities (Toggle Helpers).

This resolves #479.
2023-03-25 07:37:33 +01:00
Edward Firmo
881c50dd1f Code refactoring - Weather & Climate
Code refactoring on Weather and Climate entities/pages in order to make easier to maintain and understand.
2023-03-24 23:52:45 +01:00
Edward Firmo
ce7dfb1423 Fix for warning "list object has no element n"
Fix for the following error happening when opening climate page (and maybe other pages also):
```
Template variable warning: list object has no element 3 when rendering '{%- if settings_entity_value != "unknown" and settings_entity_value.split(',') | count >= 3 -%} {{ settings_entity_value.split(',')[3] }} {%- else -%} unknown {%- endif -%}'
```
2023-03-24 18:41:41 +01:00
Edward Firmo
c45bd4057f Fix "Loading..." when selected colors before 3.2.1
- Fix for "Loading..." taking forever when a color was selected prior to the new RGB picker and was not updated.

* This is no fixing the input itself, so users still having to pick a color again with the new selector, but the panel won't get stuck on "Loading..." before the new color selection is made.
2023-03-24 11:14:15 +01:00
Marc Brugger
3401340563 Ignore IntelliJ IDEA project directory 2023-03-24 07:36:56 +01:00
Chris
7f7d496beb Merge pull request #476 from bakito/patch-1
Add Home Assistant Icon Page to blueprint
2023-03-23 22:34:38 +01:00
Chris
c7ec9f97b7 Merge pull request #510 from edwardtfn/patch-13
Support to date & time formats
2023-03-23 22:23:24 +01:00
Chris
3c58a29e73 Merge pull request #513 from edwardtfn/patch-15
Fix error related to dict not containing on/off
2023-03-23 22:04:44 +01:00
Chris
7fd5658630 Merge pull request #514 from edwardtfn/patch-16
Fix for "Error rendering data template"
2023-03-23 22:03:28 +01:00
Chris
81f6783ca1 Merge pull request #518 from deejaybeam/dev
fix: Nspanel stays on loading
2023-03-23 21:55:25 +01:00
deejaybeam
cf430fc1a8 fix: Nspanel stays on loading 2023-03-23 21:54:39 +01:00
Chris
7f6c9c696b Merge pull request #516 from deejaybeam/dev
upd: use rgb color-picker
2023-03-23 14:48:29 +01:00
deejaybeam
7580a38b4f upd: use rgb color-picker 2023-03-23 14:47:31 +01:00
Edward Firmo
14532444bc Fix for "Error rendering data template"
This fix the following error which happens when an entity with a non-numeric value ('unknown', 'unavailable', some text, etc.) is sent to the device:

```
Error: Error rendering data template: ValueError: Template error: round got invalid input 'Geen' when rendering template '{{ states(repeat.item.entity) |round(1) }}{{ state_attr(repeat.item.entity, "unit_of_measurement") }}' but no default was specified
```
This may also implement the feature requested in #490
2023-03-23 12:50:49 +01:00
Edward Firmo
f2a424027d Fix error related to dict not containing on/off
Replace dict key names where reserved names (on/off) have been used.
2023-03-23 12:17:22 +01:00
Edward Firmo
f038eaed87 Support to date & time formats
This add the support to user selected date and time formats.
The following formats are supported now:
- Date formats:
  - EU: 22.03
  - UK: 22/03
  - US: 3/22
- Time formats:
  - EU/UK: 13:30
  - US: 1:30 AM/PM (the AM7PM info will be depending on updates on TFT file)
2023-03-23 07:01:31 +01:00
Chris
3f00773927 Merge pull request #509 from edwardtfn/patch-12
Fix for slow response with "Loading..."
2023-03-22 21:44:38 +01:00
Chris
7e63a4cb18 Merge pull request #508 from edwardtfn/patch-11
Removed incorrect instance of `- choice`
2023-03-22 21:44:21 +01:00
Chris
e6fd475947 Merge pull request #498 from edwardtfn/patch-9
Optimizing Multilingual User Interface
2023-03-22 21:44:00 +01:00
Chris
1869f8023d Merge pull request #482 from edwardtfn/patch-8
Simplifying code - Input area
2023-03-22 21:43:25 +01:00
Edward Firmo
860f5ddbba Fix for slow response with "Loading..."
- Fix the error where a missing/invalid entity causes the panel to slow down when opening a new page or keeps with "Loading..." on the screen until it timeouts.

This will probably fix #493
2023-03-22 20:28:01 +01:00
Edward Firmo
218ef94c9c Removed incorrect entry of - choice
This was probably a copy/paste mistake. ;)
2023-03-22 19:39:49 +01:00
Edward Firmo
730e0acd99 Removed multiple instances of list of days 2023-03-22 16:37:16 +01:00
Marc Brugger
c8afa129b5 remove .idea 2023-03-22 11:06:11 +01:00
Blackymas
ee0c21128d Merge pull request #502 from Blackymas/beta
Fix Notifications
2023-03-21 20:29:06 +01:00
Edward Firmo
1aed46b71f Optimizing Multilingual User Interface
- Optimizing MUI (Multilingual User Interface) code in order to make easier add new languages and to read the code. It will probably consume a bit less resources by reducing the number of `if..elif...` and by removing a bunch of `string.replace`.

- Language selection list sorted alphabetically in order to make easier to find
2023-03-21 17:52:02 +01:00
Blackymas
4e38a928fc Merge pull request #488 from Blackymas/dev
Fix Notification
2023-03-20 20:46:33 +01:00
Blackymas
d58ba87dbb Fix Notification 2023-03-20 20:45:31 +01:00
Edward Firmo
640e245cf8 Simplifying code - Input area
Used YAML alias to simplify the code in the `input:` area. This will make easier to maintain as it creates single points of changes, promoting consistence.
2023-03-20 15:23:59 +01:00
Marc Brugger
f056dace88 Add Home Assistant Icon Page and link to color converter to blueprint 2023-03-19 19:16:11 +01:00
Blackymas
3211f44770 Merge pull request #468 from Blackymas/beta
v.3.2 - New features and custom configurations
2023-03-19 13:22:58 +01:00
Blackymas
bd5b1303f2 Merge pull request #466 from Blackymas/dev
fix value 03 position
2023-03-19 13:21:21 +01:00
Blackymas
8ff0cad379 fix value 03 position 2023-03-19 13:20:54 +01:00
Blackymas
fdcd37c6d0 Merge pull request #458 from Blackymas/dev
fixes
2023-03-18 00:56:56 +01:00
Blackymas
6a464325d7 remove obsolete spaces 2023-03-18 00:50:29 +01:00
Blackymas
3af0c20670 Merge pull request #456 from Floppe/homesensor
Fix so homepage works when one of home values 01-03 is unavailable.
2023-03-18 00:37:10 +01:00
Blackymas
7ee10d4ca6 Merge pull request #445 from edwardtfn/patch-4
Fix warning on settings_entity_value
2023-03-18 00:36:17 +01:00
Blackymas
884c8d91e6 Merge pull request #457 from Blackymas/dev
changed component id boot and sleep
2023-03-17 23:18:10 +01:00
Blackymas
07b8e99b01 change component id boot and sleep 2023-03-17 23:17:16 +01:00
Blackymas
d74b70f864 change component id for repot and sleep 2023-03-17 23:13:47 +01:00
Joachim Wickman
e70fcd54eb Fix so home page works when one of home values 01-03 is unavailable.
Signed-off-by: Joachim Wickman <joachim@wickman.in>
2023-03-17 09:00:34 +02:00
Blackymas
ea5b80e3b8 Merge pull request #450 from Blackymas/dev
fixed heating button
2023-03-15 20:39:13 +01:00
Blackymas
b5cd83240f fixed heating button 2023-03-15 20:37:37 +01:00
Edward Firmo
7d241d1400 Fix warning on settings_entity_value
Fix warning message: 
Template variable warning: list object has no element 3 when rendering '{%- if settings_entity_value != "unknown" -%} {{ settings_entity_value.split(',')[3] }} {%- else -%} unknown {%- endif -%}'
2023-03-15 08:29:08 +01:00
Blackymas
ee2e1d53d2 Merge pull request #441 from Blackymas/dev
fix lightslider
2023-03-14 22:18:13 +01:00
Blackymas
36e0344345 fix lightslider 2023-03-14 22:17:37 +01:00
Blackymas
eb6eebfd46 Merge pull request #427 from Blackymas/dev
fix button issue
2023-03-13 00:31:25 +01:00
Blackymas
0de7850c39 fix button issue 2023-03-13 00:31:02 +01:00
Blackymas
5f1d2b9d10 Merge pull request #424 from Blackymas/dev
rdy for 3.2
2023-03-12 21:51:17 +01:00
Blackymas
0abd5531cb bug fixes 2023-03-12 21:29:41 +01:00
Blackymas
0fdcd088ec tft rdy for v3.2 2023-03-12 21:20:56 +01:00
Blackymas
29df75263b Merge pull request #395 from Blackymas/dev
lightslider jump to page change
2023-03-06 08:50:52 +01:00
Blackymas
5035b89956 lightslider jump to page change 2023-03-06 08:48:26 +01:00
Blackymas
9de5abff25 Merge pull request #394 from Blackymas/dev
new slider function for brightness, temp color, color and cover
2023-03-06 01:12:05 +01:00
Blackymas
a113e0cd43 new function slider brightness, temp, color, cover 2023-03-06 01:11:10 +01:00
Blackymas
a2f5e69b76 new slider function brightness, temp, color, cover 2023-03-06 01:09:09 +01:00
Blackymas
0e41a87659 Merge pull request #393 from Blackymas/dev
reworked code and new functions
2023-03-05 11:32:25 +01:00
Blackymas
f6a6a7adb0 chips, values, button, reworked code 2023-03-05 11:19:48 +01:00
Blackymas
8abfee7b54 chips, free value, bugs, reworked code 2023-03-05 11:18:19 +01:00
Blackymas
70038014a2 add Wifi icon and long press settings page 2023-02-26 22:42:35 +01:00
Blackymas
268c6a7e23 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-22 20:27:56 +01:00
Blackymas
133165e79e chips mapping 2023-02-22 20:27:51 +01:00
Blackymas
99f2b2815d rdy for climate 2023-02-22 20:27:13 +01:00
Blackymas
d6f0958652 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-22 01:05:09 +01:00
Blackymas
6704e320da rebuild home page done 2023-02-22 01:05:05 +01:00
Blackymas
d0d09b93a4 finish home page 2023-02-22 00:56:47 +01:00
Blackymas
155ab33086 position change 2023-02-22 00:50:07 +01:00
Blackymas
55ed836400 home button command 2023-02-22 00:44:43 +01:00
Blackymas
6ac6a25803 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-22 00:36:46 +01:00
Blackymas
26844cd290 change home Button, icons, color 2023-02-22 00:36:42 +01:00
Blackymas
7dc0f49809 change font size 2023-02-21 23:31:38 +01:00
Blackymas
71cd913135 change home button to icon font 2023-02-21 23:01:32 +01:00
Blackymas
dfa3ee901a last click variable local to global 2023-02-21 08:41:51 +01:00
Blackymas
f7131aaca0 add 7 free chips with icon - change chips 01-03 2023-02-21 01:02:28 +01:00
Blackymas
fefb1374fd Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-20 12:50:42 +01:00
Blackymas
8f5165bd1b fix trigger wrong input home_value03 2023-02-20 12:50:38 +01:00
Blackymas
94a51da6fe outdoor temp size 2023-02-20 01:51:20 +01:00
Blackymas
e422a158ca positions home page 2023-02-20 01:45:43 +01:00
Blackymas
b43d83291b Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-20 01:20:06 +01:00
Blackymas
e751938cdd 3 new values on home page with icon 2023-02-20 01:19:59 +01:00
Blackymas
b8321807dc positions home page 2023-02-20 01:15:59 +01:00
Blackymas
3a42c12c00 home page portions 2023-02-20 01:09:29 +01:00
Blackymas
d552fb458b fix default icon buttons 2023-02-20 01:03:05 +01:00
Blackymas
a7b96d8582 change icon field home page 2023-02-20 00:55:47 +01:00
Blackymas
18f188bb32 change TFT Home page 2023-02-19 23:35:34 +01:00
Blackymas
f44d3fd8d1 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-02-19 22:39:42 +01:00
Blackymas
a0b8697a4f New Button Design + Weather Icon change 2023-02-19 22:39:31 +01:00
Blackymas
de8f463968 delete dim in preinit 2023-02-17 22:53:51 +01:00
deejaybeam
6642a46a04 upd: button-pages 2023-02-17 18:06:33 +01:00
Blackymas
0b856cbb83 rebuild buttons v.1 2023-02-17 08:21:55 +01:00
Blackymas
e41c02e883 v.3.2 rebuild for change from icons to font 2023-02-15 23:11:33 +01:00
Blackymas
6f3dc4a010 rebuild HMI and TFT for Font Icon
rebuild for change from icons to font for the pages -> home page, weather01-04, buttonpage01-04
2023-02-15 23:07:25 +01:00
Blackymas
d46eecc57c Merge pull request #335 from edwardtfn/patch-3
Convert "Update TFT display" into a button
2023-02-15 22:36:53 +01:00
Blackymas
7223103905 Merge pull request #343 from Blackymas/dev
update 3.1.1
2023-02-14 16:10:28 +01:00
Edward Firmo
547338c5b1 Convert "Update TFT display" into a button
* This is a breaking change. Existing automation using the Switch version will need an update to use the button version instead.

This was originally set as a switch, but in reality it behaves as a button, as when the user click it runs an action (in this case, update the TFT display file). Switches should be used only when an entity will remain in one of the two states (on/off), which is not the case here.

This is related to #328.
2023-02-13 15:56:40 +01:00
Chris
811aca8cfa Merge pull request #334 from deejaybeam/dev
fix: apply climate-settings
2023-02-13 09:08:19 +01:00
Chris
0465a9eb8b Merge branch 'Blackymas:dev' into dev 2023-02-13 09:07:24 +01:00
Chris
45907e1ce5 fix: applying climate-settings 2023-02-13 09:05:08 +01:00
Blackymas
3ff82ef8cd change Climate Label, Climate Back, Sleep QR/Noti 2023-02-12 23:40:48 +01:00
Chris
5f6cc373fe Merge pull request #330 from deejaybeam/dev
upd: use new tft multi-climate
2023-02-12 12:24:10 +01:00
deejaybeam
4801f6c6b9 upd: use new tft multi-climate 2023-02-12 12:23:41 +01:00
Blackymas
02b4f6e178 Notification and QR code wake up after sleep 2023-02-12 11:45:57 +01:00
Blackymas
b0161d41f8 new fields climate page 2023-02-12 11:36:16 +01:00
Chris
d1702ccacf Merge pull request #327 from edwardtfn/patch-2
Fix default language input
2023-02-11 21:59:19 +01:00
Edward Firmo
281be927a7 Fix default language input
Fix default language so it can be used when no selection is done (like when upgrading from earlier version when language input was not available).
2023-02-11 20:53:16 +01:00
Chris
c352047991 Merge pull request #325 from deejaybeam/dev
upd: open climate on short_press too
2023-02-11 19:03:02 +01:00
deejaybeam
c058fd4fb1 upd: open climate on short_press too 2023-02-11 19:02:19 +01:00
Chris
e4e5cb0f51 Merge pull request #324 from deejaybeam/dev
upd: multi-climate
2023-02-11 18:33:21 +01:00
deejaybeam
da611e384a upd: multi-climate 2023-02-11 18:28:41 +01:00
Chris
5292bbff8b Merge pull request #321 from deejaybeam/dev
upd: prep for release 3.1.1
2023-02-10 20:58:29 +01:00
deejaybeam
a22311c4e8 upd: prep for release 3.1.1 2023-02-10 20:56:14 +01:00
Chris
0d250fb56b Merge pull request #315 from deejaybeam/dev
fixes in blueprint
2023-02-08 22:27:25 +01:00
deejaybeam
5ba5d2fb08 fix: issue on ha-restart 2023-02-08 22:24:17 +01:00
deejaybeam
51170c514d fix: ignore unassigned hw-buttons 2023-02-07 19:33:02 +01:00
Blackymas
53cf4f1371 Merge pull request #298 from Blackymas/beta
v.3.1.0 - New features and US Version
2023-02-05 11:55:37 +01:00
Blackymas
6ab6892f5b Merge pull request #297 from Blackymas/dev
rdy for Release
2023-02-05 11:53:52 +01:00
Blackymas
a38948ad2f US Version dry 2023-02-05 11:52:55 +01:00
Blackymas
0f56e859db tft dry for stable 2023-02-04 00:55:43 +01:00
Blackymas
365f863fc2 Add files via upload 2023-02-04 00:47:58 +01:00
Blackymas
cf2e648a21 old TFT and hmi shifted 2023-02-04 00:46:56 +01:00
Chris
b7c077faad Merge pull request #295 from deejaybeam/dev
upd: change entity icon description
2023-02-03 22:09:49 +01:00
deejaybeam
44d65c3cd7 upd: change entity icon description 2023-02-03 22:08:46 +01:00
Chris
069cece05e Merge pull request #289 from deejaybeam/dev
upd: hw-button hold
2023-02-02 17:53:25 +01:00
deejaybeam
276524686a upd: hw-button hold 2023-02-02 17:52:41 +01:00
Chris
a46b3ad20b Merge pull request #284 from deejaybeam/dev
fix: unavailable entity
2023-02-01 21:49:14 +01:00
deejaybeam
295096a9d7 fix: unavailable entity 2023-02-01 21:48:26 +01:00
Chris
0c6b994161 Merge pull request #283 from deejaybeam/dev
fix: new tft ids
2023-02-01 21:15:07 +01:00
deejaybeam
63e1ab4947 fix: new tft ids 2023-02-01 21:14:27 +01:00
Chris
9ec2bac284 Merge pull request #282 from deejaybeam/dev
upd: HW-buttons hold
2023-02-01 21:08:40 +01:00
Chris
6fdbec1486 Merge branch 'Blackymas:dev' into dev 2023-02-01 21:08:03 +01:00
deejaybeam
f11215c097 upd: HW-buttons hold 2023-02-01 21:07:00 +01:00
Blackymas
7ec5bb6a04 Add files via upload 2023-02-01 20:52:32 +01:00
Blackymas
aae9bd8d8a Add files via upload 2023-02-01 20:36:37 +01:00
Chris
cdf980ee8f Merge pull request #279 from deejaybeam/dev
upd: remove global variable touchevent
2023-02-01 19:22:56 +01:00
deejaybeam
7b23050791 upd: remove global variable touchevent 2023-02-01 19:20:37 +01:00
Chris
faaa698e46 Merge pull request #278 from deejaybeam/dev
fix: exclude screensaver
2023-02-01 18:54:02 +01:00
deejaybeam
4b5c10a68e fix: exclude screensaver 2023-02-01 18:52:33 +01:00
Blackymas
b00720d465 touchevent 2023-01-31 21:43:34 +01:00
Blackymas
c4cf3049b2 chnage default delay to 1 2023-01-31 21:15:04 +01:00
Blackymas
f7e76bdbd8 dry for home timer es-home 2023-01-31 21:10:02 +01:00
Blackymas
4294fb39b2 Add files via upload 2023-01-31 00:05:05 +01:00
Blackymas
eb2f810161 Add files via upload 2023-01-30 23:51:05 +01:00
Blackymas
17e11063e3 Add files via upload 2023-01-30 23:45:21 +01:00
Blackymas
70e2f724f7 Add files via upload 2023-01-30 23:37:01 +01:00
Blackymas
f3787c812a Add files via upload 2023-01-30 23:31:50 +01:00
Blackymas
a056a13f0b Add files via upload 2023-01-30 23:28:34 +01:00
Blackymas
13d5b7a1d2 Add files via upload 2023-01-30 23:21:17 +01:00
Blackymas
2c8a45153b Add files via upload 2023-01-30 23:03:46 +01:00
Blackymas
be12633af1 Add files via upload 2023-01-30 22:02:00 +01:00
Blackymas
81e4149b11 delete home timer 2023-01-30 21:56:58 +01:00
Blackymas
4b98f4a80a Add files via upload 2023-01-30 21:08:54 +01:00
Chris
d83f37962d Merge pull request #272 from deejaybeam/dev
upd: page-timer esphome
2023-01-30 18:03:26 +01:00
Chris
33b0d0674a Merge branch 'Blackymas:dev' into dev 2023-01-30 18:02:39 +01:00
Chris
b7f2c18c85 upd: page-timer esphome 2023-01-30 18:01:42 +01:00
Blackymas
cda0e0c1d6 Add files via upload 2023-01-30 17:51:30 +01:00
Blackymas
42eb9b5d71 Add files via upload 2023-01-30 17:01:38 +01:00
Blackymas
35be40fb93 change txt_max Page label to 30 2023-01-30 11:09:31 +01:00
Blackymas
1d5c40d7a8 change lastclick 2023-01-30 11:01:23 +01:00
Blackymas
c1ea2e1810 Merge pull request #270 from Blackymas/Blackymas-patch-1
Blackymas test sponsor
2023-01-30 01:11:59 +01:00
Blackymas
f9562d495a Create FUNDING.yml 2023-01-30 01:11:25 +01:00
Blackymas
58ad89ee4e wrong entities_entity27 2023-01-29 23:27:28 +01:00
Blackymas
b4a0800929 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-01-29 21:38:19 +01:00
Blackymas
e27c92ef0e change delay to 0 2023-01-29 21:38:14 +01:00
Blackymas
936c152ca6 entity card and home icon 2023-01-29 21:35:25 +01:00
Blackymas
fadd725662 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-01-29 21:12:51 +01:00
Blackymas
ab5d30d0ce wrong entity icon, UKR trans., version to 3.1.0 2023-01-29 21:12:47 +01:00
Blackymas
12ecc30e1f Add files via upload 2023-01-29 12:13:02 +01:00
Blackymas
985cf69f0b change home entity icon mapping 2023-01-29 12:11:27 +01:00
Chris
ffa9deaf54 Merge pull request #264 from deejaybeam/dev
upd: instant update of home-buttons
2023-01-28 15:07:11 +01:00
deejaybeam
8613208b5f upd: instant update of home-buttons 2023-01-28 14:07:20 +01:00
Chris
7b1bbb704a Merge pull request #261 from deejaybeam/dev
upd: entities
2023-01-28 00:59:44 +01:00
Chris
5acbdef022 upd: entities 2023-01-28 00:58:59 +01:00
Blackymas
96f855e930 entitycards dry 2023-01-25 23:46:25 +01:00
Blackymas
c504ade7d4 Add files via upload 2023-01-25 23:42:38 +01:00
Blackymas
5941b6dab4 Add files via upload 2023-01-25 23:37:37 +01:00
Blackymas
33416b498c Add files via upload 2023-01-25 23:11:53 +01:00
Chris
beb8941c80 Merge pull request #250 from deejaybeam/dev
small changes
2023-01-25 22:05:44 +01:00
Chris
33d8487adf Merge branch 'Blackymas:dev' into dev 2023-01-25 22:02:49 +01:00
deejaybeam
cb5e9a2afe upd: add delay on boot 2023-01-25 22:00:38 +01:00
Blackymas
802a089c16 Add files via upload 2023-01-25 21:50:50 +01:00
deejaybeam
edad480e4f internal temperature sensor change upd_interval 2023-01-25 21:42:14 +01:00
Blackymas
6181cbca97 change to entitypage01 2023-01-25 09:56:30 +01:00
Blackymas
572fb9e934 Add files via upload 2023-01-25 00:10:38 +01:00
Blackymas
52dabed6ee Add files via upload 2023-01-24 23:13:36 +01:00
Blackymas
d12d8fbd86 Add files via upload 2023-01-24 23:00:59 +01:00
Chris
b0d57e63e3 Merge pull request #240 from deejaybeam/dev
upd: trigger on automation-reload
2023-01-24 16:37:50 +01:00
Chris
baf3ff4e95 Merge branch 'dev' of https://github.com/deejaybeam/NSPanel_HA_Blueprint into dev 2023-01-24 16:34:03 +01:00
Chris
c061c0bae1 upd: trigger on automation-reload 2023-01-24 16:33:56 +01:00
Chris
797c7d1a32 Merge pull request #239 from deejaybeam/dev
upd: set boot-infos
2023-01-24 13:28:08 +01:00
Chris
b1b63b11cd upd: set boot-infos 2023-01-24 13:26:37 +01:00
Chris
2ac8305eff Merge pull request #233 from deejaybeam/dev
QR-code, local fallback
2023-01-24 01:08:38 +01:00
deejaybeam
eb9d9e0f1e upd: set local fallback via blueprint 2023-01-24 01:05:09 +01:00
deejaybeam
9a1b447087 upd: change qr-code-call 2023-01-24 00:21:12 +01:00
Chris
7fb8480138 Merge pull request #231 from danwright87/dev
Update nspanel_esphome.yaml
2023-01-23 22:39:25 +01:00
danwright87
ad26272524 Update nspanel_esphome.yaml
Add relay local fallback
2023-01-23 21:16:23 +00:00
Blackymas
147cf0f497 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-01-23 00:14:04 +01:00
Blackymas
fa08f6b54a QR Code rdy 2023-01-23 00:14:00 +01:00
Blackymas
0f2d5fbd29 qr code 2023-01-22 23:38:28 +01:00
Blackymas
d645f4c02e Add files via upload 2023-01-22 16:34:55 +01:00
Blackymas
f0af3f1562 add blueprint jump qrcode page 2023-01-22 16:33:39 +01:00
Blackymas
b78699c9d5 add qrcode service 2023-01-22 16:22:33 +01:00
Blackymas
c3f2ddd499 Add files via upload 2023-01-22 01:04:57 +01:00
Blackymas
6f962ebfd0 test icon font 2023-01-22 00:40:43 +01:00
Blackymas
7f768ced45 fix entity card current page 2023-01-22 00:15:53 +01:00
Chris
37e287d253 Merge pull request #207 from X-Ryl669/dev
Simplify and remove useless code in ESP32
2023-01-21 23:19:32 +01:00
X-Ryl669
298e67a29d Fix build issue since std namespace is missing
Also fix some spelling mistakes
2023-01-21 11:58:10 +01:00
X-Ryl669
f1af69581e Remove useless test
Faster boot up by removing one useless line in UART communication
2023-01-20 14:49:13 +01:00
X-Ryl669
351b84ad96 Simplify the left/mid/right compute chain. 2023-01-20 14:46:42 +01:00
Blackymas
e050bce77e Update README.md 2023-01-19 23:56:11 +01:00
Blackymas
01de27059d first entity card page rdy 2023-01-19 23:52:25 +01:00
Blackymas
7407a2841b test design entity 2023-01-19 22:37:53 +01:00
Blackymas
2f1a947cfc test design entity 2023-01-19 22:03:06 +01:00
Blackymas
f26e5e33cc test design Entity Card 2023-01-19 21:58:44 +01:00
Blackymas
5a040cbd8e test design Entity Card 2023-01-19 21:56:53 +01:00
Blackymas
d2c383ef82 Merge pull request #199 from Blackymas/beta
change tft baud to bauds
2023-01-19 08:55:46 +01:00
Blackymas
ffc89d07e9 Merge pull request #198 from Blackymas/dev
change tft baud to bauds
2023-01-19 08:54:51 +01:00
Blackymas
2bae66f6fe new blank aft - baud -> bauds 2023-01-19 08:54:03 +01:00
Blackymas
09aaabf4c5 rdy new blank tft 2023-01-19 08:52:55 +01:00
Blackymas
5de8c739f8 change baud to bauds 2023-01-19 08:50:44 +01:00
Blackymas
1220715e9b Merge pull request #195 from Blackymas/beta
Update Readme
2023-01-16 22:40:02 +01:00
Blackymas
8cb194b3b9 Merge pull request #194 from Blackymas/dev
Update README.md
2023-01-16 22:39:15 +01:00
Blackymas
dd4f6c3b9e Update README.md 2023-01-16 22:35:18 +01:00
Blackymas
1f6eabeeee Merge pull request #189 from Blackymas/beta
Release - v.3.0.0
2023-01-15 10:23:49 +01:00
Blackymas
0309dec38d Merge pull request #188 from Blackymas/dev
Update README.md
2023-01-14 23:31:32 +01:00
Blackymas
143b80f630 Update README.md 2023-01-14 23:29:15 +01:00
Blackymas
6001ab425c Merge pull request #184 from Blackymas/dev
rdy for stable
2023-01-12 22:22:53 +01:00
Blackymas
817d187dd8 add Version number to blueprint description 2023-01-12 22:21:17 +01:00
Chris
ab0e622dd9 Merge pull request #182 from deejaybeam/dev
upd: add service upload_tft_url
2023-01-12 19:12:03 +01:00
Chris
1541c07e99 Merge branch 'Blackymas:dev' into dev 2023-01-12 19:08:55 +01:00
Chris
a823bf9739 upd: add service upload_tft_url 2023-01-12 19:07:04 +01:00
Blackymas
ec79ccf008 Merge pull request #181 from Blackymas/dev
Dev to beta
2023-01-12 16:26:52 +01:00
Blackymas
bd5fb7adc6 add fan pic 2023-01-12 08:53:23 +01:00
Blackymas
5e80691b3e add fan mapping 2023-01-12 08:51:56 +01:00
Chris
fbbb10b4e8 Merge pull request #176 from PunkRa1n/patch-2
sorted and fixed language selection
2023-01-11 21:52:49 +01:00
PunkRa1n
593a9f8592 sorted and fixed language selection 2023-01-11 21:49:06 +01:00
Chris
45f3ab2f13 Merge pull request #174 from deejaybeam/dev
fix: restore .vscode
2023-01-11 12:32:28 +01:00
Chris
3422a49973 fix: restore .vscode 2023-01-11 12:22:02 +01:00
Chris
e70a661f2f Merge pull request #163 from tikismoke/fan_entities
Fan entities
2023-01-11 12:13:15 +01:00
Blackymas
7380a485fd reboot button - boot page 2023-01-10 22:33:10 +01:00
Blackymas
ddbdf6fcab Add files via upload 2023-01-10 22:26:02 +01:00
Blackymas
e3e7b16b6a reboot button 2023-01-10 22:24:59 +01:00
Blackymas
4fc051acda add reboot button on boot page 2023-01-10 22:15:02 +01:00
tikismoke
281d284f67 Delete settings.json 2023-01-10 21:56:39 +01:00
tikismoke
f1a0cd3086 Delete .wsuo 2023-01-10 21:56:27 +01:00
tikismoke
773b39f7e5 Delete read.lock 2023-01-10 21:56:15 +01:00
tikismoke
8608b3b397 Delete 6ef87407-4c14-4dfe-9117-c8cc11aa6f4e.vsidx 2023-01-10 21:56:09 +01:00
tikismoke
8bbeace1b2 Delete 4a36059d-0d01-4a92-9922-a7a244697e7f.vsidx 2023-01-10 21:56:03 +01:00
tikismoke
cb9ba1a2ff Delete VSWorkspaceState.json 2023-01-10 21:55:54 +01:00
tikismoke
204d574457 Delete slnx.sqlite 2023-01-10 21:55:49 +01:00
Blackymas
21a8598f87 add reboot button on boot page 2023-01-10 21:53:40 +01:00
Blackymas
53dabf89fe Add files via upload 2023-01-10 21:51:29 +01:00
Chris
512189af4e Merge pull request #171 from deejaybeam/dev
upd: weather-entity, new boot-process
2023-01-10 17:49:01 +01:00
Chris
491b5cb23e upd: weather-entity, new boot-process 2023-01-10 17:46:50 +01:00
Blackymas
8ae14a4cff init boot change 2023-01-09 20:10:24 +01:00
Blackymas
c3de9950ac Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2023-01-09 18:20:30 +01:00
Blackymas
3b32ae3754 change boot hmi 2023-01-09 18:20:22 +01:00
Blackymas
471eab4e93 new boot 2023-01-09 18:15:38 +01:00
Blackymas
d44ced1cd5 fix indoor temp 2023-01-09 15:22:38 +01:00
Blackymas
2d0212b2f8 change indoor temp 2023-01-09 13:03:31 +01:00
Blackymas
b018c22922 indoor outdoor temp 2023-01-09 11:07:34 +01:00
Blackymas
bacfe4bec9 indoor temp sensor 2023-01-09 10:13:25 +01:00
Blackymas
8295284b65 indoor temp sensor 2023-01-09 09:42:30 +01:00
Blackymas
03842f1a42 add RUS translation 2023-01-09 08:55:23 +01:00
tikismoke
9363ee3b48 correct icon no update for fan 2023-01-06 17:06:47 +01:00
Blackymas
42ed489a1c translate please_confirm_mui 2023-01-06 15:21:49 +01:00
Blackymas
4993695a73 Add files via upload 2023-01-06 11:09:40 +01:00
Blackymas
a56db0170c change esphome Display Start 2023-01-06 10:27:13 +01:00
Blackymas
0ac19e4096 Add files via upload 2023-01-06 10:12:46 +01:00
Blackymas
14328846a7 Add files via upload 2023-01-06 09:43:28 +01:00
Blackymas
b3648e947d Add files via upload 2023-01-06 09:24:25 +01:00
Blackymas
ca736ac139 Add files via upload 2023-01-06 09:23:57 +01:00
Blackymas
cf7f943d82 Add files via upload 2023-01-06 09:10:59 +01:00
Blackymas
e6e286edd0 Add files via upload 2023-01-06 09:10:08 +01:00
Blackymas
6c86ed1f7f Add files via upload 2023-01-06 09:06:31 +01:00
Blackymas
3a4c3fe37d Add files via upload 2023-01-06 08:57:37 +01:00
tikismoke
ec67e93af0 button error 2023-01-05 20:56:15 +01:00
tikismoke
88472c7de1 typo 2023-01-05 19:48:57 +01:00
tikismoke
c0e8a46865 fan entities 1st test 2023-01-05 19:13:18 +01:00
Chris
a7aa574d8c Merge pull request #162 from deejaybeam/dev
upd: confirmation
2023-01-05 17:49:59 +01:00
deejaybeam
e32df95471 upd: confirmation 2023-01-05 17:47:14 +01:00
Chris
c19cdd3703 Merge pull request #161 from deejaybeam/dev
upd: Notification
2023-01-05 01:06:56 +01:00
Chris
1fafff21b9 Merge branch 'Blackymas:dev' into dev 2023-01-05 01:05:07 +01:00
deejaybeam
bf11e4c6e6 upd: notification 2023-01-05 01:01:08 +01:00
Blackymas
37750c642b Add files via upload 2023-01-05 01:00:28 +01:00
Blackymas
9340e3c6cd Add files via upload 2023-01-05 00:04:48 +01:00
Blackymas
280f88de2e change button08release 2023-01-04 01:39:08 +01:00
Chris
5b8f19b425 Merge pull request #157 from deejaybeam/dev
upd: new home-page and prep notify
2023-01-04 01:01:05 +01:00
deejaybeam
fe7da90f30 upd: new home-page and prep notify 2023-01-04 00:59:14 +01:00
Blackymas
2b1cf79f46 Add files via upload 2023-01-03 23:55:20 +01:00
Blackymas
5513f1d1ab dry for Notification 2023-01-03 23:43:29 +01:00
Blackymas
fae2f043e7 New Home Page and notification 2023-01-03 17:03:46 +01:00
Blackymas
8e9aa4efc1 Add files via upload 2023-01-03 16:02:23 +01:00
Blackymas
3871a97d8a Merge pull request #154 from naofireblade/dev
Added binary_sensor to supported button entities
2023-01-03 15:33:29 +01:00
Blackymas
3f634e3eb5 Add files via upload 2023-01-03 12:40:41 +01:00
Blackymas
e0455e1635 Add files via upload 2023-01-03 12:22:37 +01:00
Blackymas
71935d37f8 Add files via upload 2023-01-03 11:57:15 +01:00
Blackymas
34f057dba4 Add files via upload 2023-01-03 09:23:02 +01:00
Arne Blumentritt
7c42431143 Added binary_sensor to supported button entities 2023-01-02 23:04:51 +01:00
Blackymas
cd766c2cad Add files via upload 2023-01-02 16:05:28 +01:00
Blackymas
1d12f87a5e Add files via upload 2023-01-02 15:50:15 +01:00
Blackymas
1305284855 Add files via upload 2023-01-02 15:23:42 +01:00
Blackymas
24a415f773 Merge pull request #148 from Blackymas/beta
Add baud rate 115200 by default
2023-01-02 11:34:44 +01:00
Blackymas
d6d8de0b8e Merge pull request #147 from Blackymas/dev
Add baud rate 115200 by default
2023-01-02 11:34:19 +01:00
Blackymas
50e53ae596 new blank tft´s 2023-01-02 11:02:54 +01:00
Blackymas
92f52be4f1 Add baud rate 115200 by default 2023-01-02 11:02:10 +01:00
Blackymas
3d01355b75 add baud rate 115200 by default in TFT File 2023-01-02 10:41:03 +01:00
Blackymas
fffc70e733 Merge pull request #135 from Blackymas/beta
change description
2022-12-30 01:04:57 +01:00
Blackymas
79427157a8 Merge pull request #134 from Blackymas/dev
change description
2022-12-30 01:04:24 +01:00
Blackymas
942bacdc28 Update README.md 2022-12-30 01:03:26 +01:00
Blackymas
415465ee62 Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2022-12-30 01:02:53 +01:00
Blackymas
a21dc7524c change description 2022-12-30 01:02:47 +01:00
Blackymas
0e417e5e91 Update README.md 2022-12-30 01:00:41 +01:00
Blackymas
1a36d9bf36 Merge pull request #132 from Blackymas/beta
25 languages added
2022-12-30 00:12:21 +01:00
Blackymas
3d7564b003 Merge pull request #131 from Blackymas/dev
25 languages added
2022-12-30 00:11:46 +01:00
Chris
7bebb0e8bf Merge pull request #129 from deejaybeam/dev
fix: ignore entities with state unknown
2022-12-29 17:37:54 +01:00
deejaybeam
34daabcaad fix: ignore entities with state unknown 2022-12-29 17:35:48 +01:00
Blackymas
817aa011cf language font size 2022-12-29 16:09:26 +01:00
Blackymas
7f2ecd360e add Language 2022-12-28 13:08:01 +01:00
Blackymas
f259e202bd Merge branch 'dev' of https://github.com/Blackymas/NSPanel_HA_Blueprint into dev 2022-12-28 12:50:33 +01:00
Blackymas
045c1ed939 add language 2022-12-28 12:50:25 +01:00
Chris
532f0f5ffe Merge pull request #120 from deejaybeam/dev
add script-domain, hw-buttons, small fix
2022-12-22 17:39:14 +01:00
Chris
805317e865 upd: additional domains for hw-buttons 2022-12-22 14:59:24 +01:00
Chris
a1e420e2cf upd: add script domain for buttons 2022-12-22 14:44:42 +01:00
Chris
549a978736 fix: no exec on unavailable state 2022-12-22 13:56:10 +01:00
Blackymas
184f25cb3f Merge pull request #112 from chpego/add_french_language
Add french language
2022-12-19 08:55:55 +01:00
Blackymas
dd14d6f88c change fonts for new languages 2022-12-15 10:12:39 +01:00
chpego
7a4f9f6f70 add french language 2022-12-12 12:09:33 +01:00
Blackymas
e7df0e5099 Merge pull request #98 from Blackymas/beta
add new pic in Readme
2022-12-11 00:42:59 +01:00
Blackymas
bda5a311c6 Merge pull request #97 from Blackymas/dev
add new pic in Readme
2022-12-11 00:42:34 +01:00
Blackymas
e5c44c9510 add new pic 2022-12-11 00:41:59 +01:00
Blackymas
387376a36b Merge pull request #96 from Blackymas/beta
v.2.1.0 - add new Domains, Buttons and Button Page Label
2022-12-10 22:46:13 +01:00
Blackymas
4c53f18d5b Add files via upload 2022-12-10 22:43:35 +01:00
Blackymas
919a4fe707 Update README.md 2022-12-10 22:42:54 +01:00
Blackymas
d30557a3a6 Update README.md 2022-12-10 22:41:17 +01:00
Blackymas
bc453a917f Merge pull request #93 from Blackymas/dev
New Domains, Icons and Button Page Label
2022-12-10 22:37:53 +01:00
Blackymas
e0a1117a4a Add files via upload 2022-12-10 22:33:15 +01:00
Blackymas
62a73ad255 Update README.md 2022-12-10 22:31:17 +01:00
Blackymas
55de07ecde Update README.md 2022-12-10 22:30:42 +01:00
Blackymas
c60aca7e54 change some button pics 2022-12-10 22:27:40 +01:00
Blackymas
d8cf4fbd2b Update README.md 2022-12-10 21:33:08 +01:00
Blackymas
795260ccaf Merge pull request #90 from chpego/patch-1
fix some typo
2022-12-10 21:27:26 +01:00
chpego
5d1ab726ae fix some typo
on README file
2022-12-10 06:32:55 +00:00
Chris
c3b4eb8a87 Merge pull request #89 from deejaybeam/dev
upd: add page-labels
2022-12-10 01:32:28 +01:00
deejaybeam
46582e3010 upd: add page-labels 2022-12-10 01:31:42 +01:00
Chris
592200e7d6 Merge pull request #88 from deejaybeam/dev
upd: additional domains for buttons
2022-12-10 00:40:50 +01:00
deejaybeam
dcd60b8cc4 upd: assign correct pics for new domains 2022-12-10 00:38:30 +01:00
Chris
a63c4f1412 Merge branch 'Blackymas:dev' into dev 2022-12-09 23:12:07 +01:00
Blackymas
b1579c7ea9 new button page label and domains 2022-12-09 21:25:27 +01:00
Blackymas
f5b9b1714a new version for new domains and button page label 2022-12-09 21:22:41 +01:00
deejaybeam
95ad152139 upd: additonal domains for buttons 2022-12-09 18:45:02 +01:00
Blackymas
fbc35f697f fix issues with HW buttons 2022-12-09 08:34:22 +01:00
356 changed files with 86551 additions and 26659 deletions

13
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,13 @@
# These are supported funding model platforms
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: https://www.paypal.com/donate/?hosted_button_id=S974SWQMB8PB2

View File

@@ -0,0 +1,21 @@
name: Validate Blueprint YAML
on:
push:
paths:
- "nspanel_blueprint.yaml"
pull_request:
paths:
- "nspanel_blueprint.yaml"
#schedule:
# - cron: "0 0 * * *"
workflow_dispatch:
jobs:
code_scan:
name: Validate Blueprint YAML
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4.1.0
- name: Validate nspanel_blueprint.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_blueprint.yaml

165
.github/workflows/validate_esphome.yml vendored Normal file
View File

@@ -0,0 +1,165 @@
name: Validate ESPHome
on:
push:
paths:
- "nspanel_esphome*.yaml"
- "advanced/esphome/nspanel_esphome*.yaml"
pull_request:
paths:
- "nspanel_esphome*.yaml"
- "advanced/esphome/nspanel_esphome*.yaml"
workflow_dispatch:
concurrency:
# yamllint disable-line rule:line-length
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
code_scan:
name: Code scan (YAML)
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4.1.0
- name: Validate nspanel_esphome.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome.yaml
- name: Validate nspanel_esphome_core.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_core.yaml
- name: Validate nspanel_esphome_addon_upload_tft.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_addon_upload_tft.yaml
- name: Validate nspanel_esphome_advanced.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_advanced.yaml
- name: Validate nspanel_esphome_addon_climate_base.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_addon_climate_base.yaml
- name: Validate nspanel_esphome_addon_climate_cool.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_cool.yaml
- name: Validate nspanel_esphome_addon_climate_heat.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_heat.yaml
- name: Validate nspanel_esphome_addon_climate_dual.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_dual.yaml
build_core:
name: Core
runs-on: "ubuntu-latest"
needs:
- code_scan
steps:
- uses: actions/checkout@v4.1.0
- name: Build core
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_core.yaml"
build_advanced:
name: Advanced
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced.yaml"
build_climate_heat:
name: Climate (heat)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_heat
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_heat.yaml"
build_climate_cool:
name: Climate (cool)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_cool
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_cool.yaml"
build_climate_dual:
name: Climate (dual)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_dual
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_dual.yaml"
build_climate_heat_advanced:
name: Advanced+climate (heat)
runs-on: "ubuntu-latest"
needs:
- build_climate_heat
- build_advanced
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_heat
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_heat.yaml"
build_climate_cool_advanced_esp_idf:
name: esp-idf & Bluetooth proxy
runs-on: "ubuntu-latest"
needs:
- build_climate_cool
- build_advanced
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_cool+esp_idf
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf.yaml"
#build_climate_cool_advanced_esp_idf5:
# name: esp-idf v5 & Bluetooth proxy
# runs-on: "ubuntu-latest"
# needs:
# - build_climate_cool_advanced_esp_idf
# steps:
# - uses: actions/checkout@v4.1.0
# - name: Build core+advanced+climate_cool+esp_idf5
# uses: esphome/build-action@v1.8.0
# with:
# yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf5.yaml"
build_climate_heat_advanced_customization:
name: Customizations
runs-on: "ubuntu-latest"
needs:
- build_climate_heat_advanced
- build_climate_cool_advanced_esp_idf
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_heat+customizations
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_heat_customizations.yaml"
#build_climate_cool_advanced_esp_idf5:
# name: esp-idf v5 & Bluetooth proxy
# runs-on: "ubuntu-latest"
# needs:
# - build_climate_cool
# - build_advanced
# steps:
# - uses: actions/checkout@v4.1.0
# - name: Build core+advanced+climate_cool+esp_idf
# uses: esphome/build-action@v1.8.0
# with:
# yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf5.yaml"

View File

@@ -0,0 +1,166 @@
name: Validate ESPHome (beta)
on:
workflow_dispatch:
concurrency:
# yamllint disable-line rule:line-length
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
code_scan:
name: Code scan (YAML)
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4.1.0
- name: Validate nspanel_esphome.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome.yaml
- name: Validate nspanel_esphome_core.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_core.yaml
- name: Validate nspanel_esphome_addon_upload_tft.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_addon_upload_tft.yaml
- name: Validate nspanel_esphome_advanced.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_advanced.yaml
- name: Validate nspanel_esphome_addon_climate_base.yaml
run: yamllint -c "./.rules/yamllint.yml" advanced/esphome/nspanel_esphome_addon_climate_base.yaml
- name: Validate nspanel_esphome_addon_climate_cool.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_cool.yaml
- name: Validate nspanel_esphome_addon_climate_heat.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_heat.yaml
- name: Validate nspanel_esphome_addon_climate_dual.yaml
run: yamllint -c "./.rules/yamllint.yml" nspanel_esphome_addon_climate_dual.yaml
build_core:
name: Core
runs-on: "ubuntu-latest"
needs:
- code_scan
steps:
- uses: actions/checkout@v4.1.0
- name: Build core
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_core.yaml"
version: beta
build_advanced:
name: Advanced
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced.yaml"
version: beta
build_climate_heat:
name: Climate (heat)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_heat
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_heat.yaml"
version: beta
build_climate_cool:
name: Climate (cool)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_cool
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_cool.yaml"
version: beta
build_climate_dual:
name: Climate (dual)
runs-on: "ubuntu-latest"
needs:
- build_core
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+climate_dual
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_climate_dual.yaml"
version: beta
build_climate_heat_advanced:
name: Advanced+climate (heat)
runs-on: "ubuntu-latest"
needs:
- build_climate_heat
- build_advanced
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_heat
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_heat.yaml"
version: beta
build_climate_cool_advanced_esp_idf:
name: esp-idf & Bluetooth proxy
runs-on: "ubuntu-latest"
needs:
- build_climate_cool
- build_advanced
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_cool+esp_idf
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf.yaml"
version: beta
#build_climate_cool_advanced_esp_idf5:
# name: esp-idf v5 & Bluetooth proxy
# runs-on: "ubuntu-latest"
# needs:
# - build_climate_cool_advanced_esp_idf
# steps:
# - uses: actions/checkout@v4.1.0
# - name: Build core+advanced+climate_cool+esp_idf5
# uses: esphome/build-action@v1.8.0
# with:
# yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf5.yaml"
# version: beta
build_climate_heat_advanced_customization:
name: Customizations
runs-on: "ubuntu-latest"
needs:
- build_climate_heat_advanced
- build_climate_cool_advanced_esp_idf
steps:
- uses: actions/checkout@v4.1.0
- name: Build core+advanced+climate_heat+customizations
uses: esphome/build-action@v1.8.0
with:
yaml_file: "./.test/esphome_advanced_climate_heat_customizations.yaml"
version: beta
#build_climate_cool_advanced_esp_idf5:
# name: esp-idf v5 & Bluetooth proxy
# runs-on: "ubuntu-latest"
# needs:
# - build_climate_cool
# - build_advanced
# steps:
# - uses: actions/checkout@v4.1.0
# - name: Build core+advanced+climate_cool+esp_idf
# uses: esphome/build-action@v1.8.0
# with:
# yaml_file: "./.test/esphome_advanced_climate_cool_esp_idf5.yaml"
# version: beta

50
.github/workflows/validate_markdown.yml vendored Normal file
View File

@@ -0,0 +1,50 @@
name: Validate Markdown
on:
pull_request:
paths:
- '**/*.md'
push:
paths:
- '**/*.md'
workflow_dispatch:
jobs:
markdown-lint:
name: Markdown Lint
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4.1.0
# https://github.com/marketplace/actions/markdownlint-cli2-action
- name: Identify changed files
uses: tj-actions/changed-files@v41
id: changed-files
with:
files: '**/*.md'
separator: ","
# https://github.com/marketplace/actions/markdownlint-cli2-action
- name: Markdown Lint
uses: DavidAnson/markdownlint-cli2-action@v14
if: steps.changed-files.outputs.any_changed == 'true'
with:
globs: ${{ steps.changed-files.outputs.all_changed_files }}
separator: ","
config: '.rules/.markdownlint.jsonc'
fix: true
markdown-links:
name: Check links
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4.1.0
# https://github.com/gaurav-nelson/github-action-markdown-link-check
- name: Markdown links
uses: gaurav-nelson/github-action-markdown-link-check@v1
with:
check-modified-files-only: yes
config-file: '.rules/mlc_config.json'
base-branch: 'main'

12
.gitignore vendored
View File

@@ -1,3 +1,15 @@
# Ignore Mac DS_Store files
.DS_Store
**/.DS_Store
Nextion2Text.*
*.cmd
*.bat
# Ignore IntelliJ IDEA project directory
.idea
# Ignore dev folder
#dev
nspanel_esphome_prebuilt.bin

View File

@@ -0,0 +1,4 @@
{
"MD013": { "line_length": 200 }
}

13
.rules/mlc_config.json Normal file
View File

@@ -0,0 +1,13 @@
{
"ignorePatterns": [
{
"pattern": "^http://homeassistant\\.local.*$"
},
{
"pattern": "^https://sonoff.tech/product/central-control-panel/nspanel/$"
},
{
"pattern": "^https://sonoff.tech/wp-content/uploads/2021/11/%E4%BA%A7%E5%93%81%E5%8F%82%E6%95%B0%E8%A1%A8-NSPanel-20210831.pdf$"
}
]
}

13
.rules/yamllint.yml Normal file
View File

@@ -0,0 +1,13 @@
# https://yamllint.readthedocs.io/en/stable/configuration.html#default-configuration
extends: default
rules:
anchors:
forbid-undeclared-aliases: true
forbid-duplicated-anchors: true
# 255 chars should be enough, but don't fail if a line is longer
line-length:
max: 200
#level: warning

View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

View File

@@ -0,0 +1,22 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml
esp32:
framework:
type: esp-idf
bluetooth_proxy:
# Set Wi-Fi power save mode to "LIGHT" as required for Bluetooth on ESP32
wifi:
power_save_mode: LIGHT

View File

@@ -0,0 +1,24 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml
esp32:
framework:
type: esp-idf
version: 5.0.2
platform_version: 6.3.2
bluetooth_proxy:
# Set Wi-Fi power save mode to "LIGHT" as required for Bluetooth on ESP32
wifi:
power_save_mode: LIGHT

View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cold: !include ../nspanel_esphome_addon_climate_cold.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

View File

@@ -0,0 +1,251 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cold: !include ../nspanel_esphome_addon_climate_cold.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml
##### Customizations from Wiki #####
api:
# Encrypt the communication between ESPHome and Home Assistant
encryption:
key: !secret api_encryption_key
# Reboot if HA is not connected for 15 minutes
reboot_timeout: 15min
binary_sensor:
# Is display awake?
- name: ${device_name} Display state
id: display_state
platform: template
lambda: |-
return (id(current_page).state != "screensaver");
# Enable Bluetooth proxy
bluetooth_proxy:
button:
# Adds a button to put the panel to sleep
- name: ${device_name} Sleep
id: force_sleep
platform: template
icon: mdi:sleep
on_press:
then:
- logger.log: Button Sleep pressed
- lambda: |-
if (id(current_page).state != "screensaver") id(disp1).goto_page("screensaver");
# Adds a button to wake-up the panel (similar to the existing service)
- name: ${device_name} Wake-up
id: force_wake_up
platform: template
icon: mdi:alarm
on_press:
then:
- logger.log: Button Wake-up pressed
- lambda: |-
if (id(current_page).state == "screensaver") id(disp1).goto_page(id(wakeup_page_name).state.c_str());
// id(timer_page).execute(id(wakeup_page_name).state.c_str()); // enable this if you want page timeout to be reset
id(timer_sleep).execute(id(wakeup_page_name).state.c_str(), int(id(timeout_sleep).state));
id(timer_dim).execute(id(wakeup_page_name).state.c_str(), int(id(timeout_dim).state));
# Add custom presets to your climate (heat in this example)
climate:
- id: !extend thermostat_embedded
heat_deadband: 0.3
heat_overrun: 0.0
default_preset: "Home"
preset:
- name: "Off"
default_target_temperature_low: ${temp_min} ${temp_units}
mode: "off"
- name: Home
default_target_temperature_low: 21 ${temp_units}
mode: "heat"
- name: Away
default_target_temperature_low: 16.5 ${temp_units}
mode: "heat"
- name: Sleep
default_target_temperature_low: 17.5 ${temp_units}
mode: "heat"
# Change framework to `esp-idf`
esp32:
framework:
type: esp-idf
esphome:
# change OTA password, remove after flashing
on_boot:
- priority: 601.0
then:
- lambda: |-
id(my_ota).set_auth_password("New password");
# Limit the amount of resources used for compiling
compile_process_limit: 1
light:
# Add the display as a light in Home Assistant
- name: ${device_name} Display
id: display_light
icon: mdi:tablet-dashboard
platform: monochromatic
output: display_output
default_transition_length: 0s
on_turn_on:
then:
- lambda: |-
ESP_LOGD("light.display_light", "Turn-on");
if (current_page->state == "screensaver") disp1->goto_page(wakeup_page_name->state.c_str());
timer_reset_all->execute(wakeup_page_name->state.c_str());
on_turn_off:
then:
- lambda: |-
ESP_LOGD("light.display_light", "Turn-off");
disp1->goto_page("screensaver");
logger:
# Enable hardware UART serial logging
baud_rate: 115200
ota:
# change OTA password, remove after flashing
password: !secret wifi_password
id: my_ota
output:
# Output required by `display_light` to send the commands to Nextion
- id: display_output
platform: template
type: float
write_action:
- lambda: |-
ESP_LOGV("output.display_output", "state: %f", state);
uint8_t current_brightness = int(round(display_light->current_values.is_on() ? (display_light->current_values.get_brightness() * 100.0f) : 0.0));
ESP_LOGV("output.display_output", "current_brightness: %i%%", current_brightness);
set_brightness->execute(current_brightness);
script:
# Updates the existing `page_changed` script to update the `display_light` status when a page changes
- id: !extend page_changed
then:
- lambda: |-
ESP_LOGD("script.page_changed(custom)", "page: %s", page.c_str());
ESP_LOGV("script.page_changed(custom)", "is_on(): %s", display_light->current_values.is_on() ? "True" : "False");
if (page == "screensaver" and display_light->current_values.is_on()) {
auto call = display_light->turn_off();
call.perform();
} else if (page != "screensaver" and (not display_light->current_values.is_on())) {
auto call = display_light->turn_on();
call.perform();
}
# Updates the existing `set_brightness` script to update the `display_light` status when a new brightness level is set
- id: !extend set_brightness
then:
- lambda: |-
ESP_LOGD("script.set_brightness(custom)", "brightness: %i%%", brightness);
uint8_t current_brightness = int(round(display_light->current_values.is_on() ? (display_light->current_values.get_brightness() * 100.0f) : 0.0));
ESP_LOGV("script.set_brightness(custom)", "current_brightness: %i%%", current_brightness);
if (brightness != current_brightness) {
if (current_page->state != "screensaver" and brightness > 0) {
auto call = display_light->turn_on();
call.set_brightness(static_cast<float>(id(display_last_brightness)) / 100.0f);
call.perform();
} else if (display_light->current_values.is_on()) {
auto call = display_light->turn_off();
call.set_brightness(0);
call.perform();
}
}
time:
- id: !extend time_provider
timezone: "America/Cancun"
# Use my own local network time server
platform: sntp
servers:
- !secret mysntpserver
- europe.pool.ntp.org
- 0.pool.ntp.org
on_time:
#- hours: 22
# minutes: 0
# seconds: 0
# then:
# - deep_sleep.enter:
# sleep_duration: 7h
# Scheduled relay
- hours: 7
minutes: 30
seconds: 0
then:
- switch.turn_on: relay_1
- hours: 12
minutes: 15
seconds: 0
then:
- switch.turn_off: relay_1
- hours: 19
minutes: 30
seconds: 0
then:
- switch.turn_on: relay_1
- hours: 23
minutes: 30
seconds: 0
then:
- switch.turn_off: relay_1
# Scheduled climate
- hours: 7
minutes: 0
seconds: 0
then:
- climate.control:
id: thermostat_embedded
mode: auto
target_temperature: 22°C
- hours: 19
minutes: 0
seconds: 0
then:
- climate.control:
id: thermostat_embedded
mode: auto
target_temperature: 20°C
- hours: 23
minutes: 0
seconds: 0
then:
- climate.control:
id: thermostat_embedded
mode: auto
target_temperature: 18°C
web_server:
# Custom web server credentials
auth:
username: !secret web_server_username
password: !secret web_server_password
wifi:
networks:
- id: !extend wifi_default
# Set IP address manually
manual_ip:
static_ip: 192.168.0.123
gateway: 192.168.0.1
subnet: 255.255.255.0
# Set dual network
priority: 10
- ssid: !secret wifi_ssid_backup
password: !secret wifi_password_backup
priority: 0
# Set Wi-Fi power save mode to "LIGHT" as required for Bluetooth on ESP32
power_save_mode: LIGHT

View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
#advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
#advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
#advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

12
.test/esphome_core.yaml Normal file
View File

@@ -0,0 +1,12 @@
substitutions:
device_name: nspanel
wifi_ssid: "nspanel"
wifi_password: "NSPanel_HA_Blueprint"
nextion_update_url: "https://github.com/Blackymas/NSPanel_HA_Blueprint/dummy"
packages:
core_package: !include ../nspanel_esphome.yaml # Core package
#advanced_package: !include ../advanced/esphome/nspanel_esphome_advanced.yaml
#addon_climate_heat: !include ../nspanel_esphome_addon_climate_heat.yaml
#addon_climate_cool: !include ../nspanel_esphome_addon_climate_cool.yaml
#addon_climate_dual: !include ../nspanel_esphome_addon_climate_dual.yaml

7
.test/secrets.yaml Normal file
View File

@@ -0,0 +1,7 @@
api_encryption_key: MSANehPIH8kCp/vGcpPcKPSkYnv3zchyxkXCleXJinM=
mysntpserver: 192.168.0.1
web_server_password: NotASecret01
web_server_username: NotASecret01
wifi_password: NotASecret01
wifi_password_backup: NotASecret01
wifi_ssid_backup: NotASecret01

278
README.md
View File

@@ -1,170 +1,224 @@
# NSPanel Custom with HA Blueprint
This innovative solution is designed to revolutionize how you interact with your Sonoff NSPanel. Our goal? To make the customization of your NSPanel seamless, intuitive, and completely code-free!
*Are you happy with our version for NSPanel? Please consider supporting us with a donation.*
[![Paypal](https://user-images.githubusercontent.com/41958506/212499642-b2fd097a-0938-4bfc-b37b-74df64592c58.png)](https://www.paypal.com/donate/?hosted_button_id=S974SWQMB8PB2)
[![Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.](https://my.home-assistant.io/badges/blueprint_import.svg)](https://my.home-assistant.io/redirect/blueprint_import/?blueprint_url=https%3A%2F%2Fgithub.com%2FBlackymas%2FNSPanel_HA_Blueprint%2Fblob%2Fmain%2Fnspanel_blueprint.yaml)
This project allows you to configure your complete NSPanel via a Blueprint with UI.
## Table of Contents
### *That means you don't have to customize any code or change any lines in the code.*
1. [Project Highlights](#-project-highlights)
2. [Documentation & Resources](#-documentation--resources)
3. [Features](#-features)
4. [Pages Overview](#-pages-overview)
5. [Contributing](#-contributing)
6. [Community & Support](#-community--support)
7. [Acknowledgements](#-acknowledgements)
8. [Donations](#-donations)
So you have a nice graphical interface where you can build your NSPanel.
And the best thing is, the installation takes only a few minutes.
## 🌟 Project Highlights
The goal was to create a version that allows everyone to use the NSpanel fully local without having to deal with programming or reading hours of documentation - *AND YES WE DID IT!!!!* ;)
- **No Coding Required:** Customize your NSPanel without touching a single line of code. It's all about intuitive, user-friendly experiences!
- **Quick Setup:** Get your NSPanel up and running in minutes with our easy-to-follow graphical interface.
- **Local Control:** Embrace full local control of your NSPanel, steering clear of cloud dependencies.
- **Community-Driven:** A project for the users, by the users. Your contributions shape the future of this project!
📕 Full documentation and installation is available here [NSPanel Configuration, Setup and HowTo](https://github.com/Blackymas/NSPanel_HA_Blueprint/wiki).
## 📚 Documentation & Resources
🚀 How to create "Issues" when I have a problem [WIKI HowTo](https://github.com/Blackymas/NSPanel_HA_Blueprint/wiki)
- **Getting Started:** Dive into our comprehensive [Documentation and Setup Guide](docs/README.md) for detailed instructions.
- **Video Tutorial:** Prefer visual learning? Check out our [Step-by-Step Setup Video](docs/README.md).
- **Troubleshooting:** Encounter an issue? Here's how to report it: [WIKI HowTo](docs/README.md).
- **Feature Requests:** Got ideas? Share them [here](https://github.com/Blackymas/NSPanel_HA_Blueprint/labels/new%20feature%20request).
- **What's Next?:** Discover what's next and what we are working on right now in our [Milestones](https://github.com/Blackymas/NSPanel_HA_Blueprint/milestones?direction=asc&sort=due_date)
⭐ All Feature Requests can be found here [All Feature Request](https://github.com/Blackymas/NSPanel_HA_Blueprint/labels/new%20feature%20request)
## 🚀 Features
🎉 Roadmap Roadmap can be found here [Roadmap](https://github.com/Blackymas/NSPanel_HA_Blueprint/labels/roadmap)
🙋 WE ARE LOOKING FOR YOU! _**We are always looking for people who would like to support this project. We are looking for help with "programming new features, writing documentation or translating documentation to EN. If you are interested then please contact us :)**_
## NSPanel:
![2 Home](https://user-images.githubusercontent.com/41958506/203653897-cf96a7af-2b92-4ad9-a375-987decad5aa7.png)
![3 Buttonpage](https://user-images.githubusercontent.com/41958506/203654022-c6d81263-ce56-4a84-917a-9d4911f19f55.png)
(Home and Buttonpage)
![4 lightsetting 1](https://user-images.githubusercontent.com/41958506/203654055-943d1910-7673-4d9f-ad81-7ef00d155e5a.png)
![5 Lightsetting 2](https://user-images.githubusercontent.com/41958506/203654076-93e110df-f314-4cf1-8500-ed667f2202fd.png)
(Lightsettings - Brightness and TEMP Color)
![6 Lightsetting 3](https://user-images.githubusercontent.com/41958506/203654179-f7303b02-c886-4890-b976-cb498940a627.png)
![7 Thermostat](https://user-images.githubusercontent.com/41958506/203654189-4294b634-430f-423c-b170-9f1680f94b0e.png)
(Colorwheel and Thermostat)
![8 Cover](https://user-images.githubusercontent.com/41958506/203654290-c6ec2f2f-7924-492c-914c-0d96dc3907e0.png)
![9 Weather](https://user-images.githubusercontent.com/41958506/203654307-24000d00-b7e1-47eb-bd64-9e97b508db52.png)
(Coversetting and Weather Forcast)
![10 Settings](https://user-images.githubusercontent.com/41958506/203654386-e4e574ad-8674-4268-84dd-1c4e40f98eb9.png)
![1 Boot](https://user-images.githubusercontent.com/41958506/203667473-d33523a4-3197-4838-9099-cccebfc727db.png)
(NSPanel Settings and Boot Screen)
![Device Setting 1](https://user-images.githubusercontent.com/41958506/203723223-8afc0e44-51cf-49ed-8a49-8ba713716639.png)
![Device Setting 2](https://user-images.githubusercontent.com/41958506/203724491-53ecd93d-bc7c-4c2d-850b-f106691e2639.png)
(HA Device Seeting for Example temperature correction)
## Blueprint:
![Blueprint 1](https://user-images.githubusercontent.com/41958506/203655004-a11f5a1c-d098-4e1a-958a-0293e50000b2.png)
![Blueprint 2](https://user-images.githubusercontent.com/41958506/203655014-e6cae9df-aaf8-4537-8165-b8f44a177d3b.png)
## Features:
- easy to use and simple configuration via Blueprint - no change in the code is necessary
- Easy to use and simple configuration via Blueprint - no change in the code is necessary
- 32 buttons on 4 button pages with long press function for settings (more buttons are also possible)
- Button design is automatically generated based on the selected entity
- Buttons show current brightness and cover position in the button itself
- Buttons label can be assigned via blueprint
- Weather + 5 days weather forcast
- Thermostat + Touch + Relay control for floor heating
- Light control (brightness-slider, colorwheel, TempColor-slider) - via Long Press
- Cover control (open, close, position-slider) - via long press
- Settings page (display brightness, display dim brightness, auto-dim, sleep mode, reboot NSPanel)
- Weather + 5 days weather forecast
- Thermostat + Touch + [Relay control for floor heating](docs/addon_climate.md)
- Light control (brightness, color and temperature) - via long Press
- Cover control (open, close and position) - via long press
- Settings page (display brightness, display dim brightness, sleep mode, reboot NSPanel)
- Swipe between pages
- Top menu with 10 icons for specific states
- Heating control (hot water)
- modern design - design easy to change via Adobe Express (free + design template)
- 2 pysical switches
- Modern design - design easy to change via Adobe Express (free + design template)
- 2 physical switches with optional fallback mode
- and much more ;)
## 📖 Pages Overview
# Pages
### Home
## Home
- current weather with button to Weather Forcast page
![Home EU](docs/pics/eu_home.png)
![Home US](docs/pics/us_home.png)
- Current weather with button to Weather Forcast page
- Hardware buttons can be freely assigned
- Hardware button label or without label
- Blue line indicates on or off of the entity
- Temperature outside
- Hardware button label (optional)
- Blue line indicates the entity's states (`on` or `off`)
- Outside temperature
- Status icons at the top
- Room temperature with button to thermostat page
- Room humidity
- Hot water temperature
- Button to display settings page
- Up to 3 user's selectable entities
### Buttons Pages
## Button Page
- 32 Button
- 4 Button pages
![3 Buttonpage](https://user-images.githubusercontent.com/41958506/203654022-c6d81263-ce56-4a84-917a-9d4911f19f55.png)
![NEW Domains](https://user-images.githubusercontent.com/41958506/206879659-3aea30c1-b126-4d52-a869-abf6adfc8fa1.png)
- Up to 8 buttons per page, across 4 different pages, totaling 32 buttons
- Button design is automatically generated based on the selected entity
- Buttons show current brightness and cover position in the button itself
- Buttons label can be assigned via blueprint
- all buttons with long press function
- automatic detection by long press if it is a light or cover for submenu
- swipe between all pages
- swipe also down and up for fast access to certain pages
- Buttons display current brightness and cover position directly on the button
- Button labels can be assigned via blueprint
- All buttons feature a long-press function
- Automatic detection of light, cover, fan, media player, alarm or climate entities for submenus through long press
- Swipe between all pages
- Swipe up and down for quick access to specific pages
### Entities Pages
![Entities EU](docs/pics/eu_entities.png)
![Entities US](docs/pics/us_entities.png)
- Up to 8 entities per page, across 4 different pages, totaling 32 entities
- Icons and labels can be individually configured via blueprint or automatically detected for each entity
- Flexible alignment options for values as per user preference
### Light Settings
![4 lightsetting 1](https://user-images.githubusercontent.com/41958506/203654055-943d1910-7673-4d9f-ad81-7ef00d155e5a.png)
![5 Lightsetting 2](https://user-images.githubusercontent.com/41958506/203654076-93e110df-f314-4cf1-8500-ed667f2202fd.png)
![6 Lightsetting 3](https://user-images.githubusercontent.com/41958506/203654179-f7303b02-c886-4890-b976-cb498940a627.png)
## Light Settings
- Light current state
- Brightness Slider
- Colorwheel
- TempColor slider
- Brightness slider
- RGB color wheel
- Color temperature slider
- Jump back to the right button page
### Cover Settings
![8 Cover](https://user-images.githubusercontent.com/41958506/203654290-c6ec2f2f-7924-492c-914c-0d96dc3907e0.png)
## Cover Settings
- Open and close cover
- Cover position via slider
- Cover battery value if available (I use Ikea roller blind)
- Cover battery value (when available)
- jump back to the right button page
### Thermostat / Climate
## Thermostat
- Touch Temp control
- Outside temperature
- Hot water
- heating on, off and idle
- Hot water button
- Target temperature control slider
- Current temperature
- 4 user's selectable values (for water and external temperatures, etc.)
- All the standard climate controls from Home Assistant (`heat`, `fan`, `cool`, `auto`, `dry`)
- 2 user's selectable buttons
- [Can be used for local control (even when Wi-Fi is unavailable) when your panel's relays are used to control your cooler/heater](docs/addon_climate.md)
### Fan speed
## Weather Forcast
- 5 days Weather Forcast via swipe (Integration Accuweather - but should also go with another integration)
- Lowest and highest temperature outside
- Turn-on and turn-off fan
- Set speed via slider or buttons
- jump back to the right button page
### Alarm
- Arm/disarm an alarm (standard modes supported by Home Assistant)
- Support to numeric pin for arming or disarming
### Weather Forecast
![9 Weather](https://user-images.githubusercontent.com/41958506/203654307-24000d00-b7e1-47eb-bd64-9e97b508db52.png)
- 5 days weather forecast via swipe (supports most used weather integrations)
- Min and max outside temperatures
- Date
- Rain probability
- Sunshine hours
- Sun pressure
- Thunderstorm probability
- Wind speed
- Night thunderstorm probability and wind speed
- Other weather parameters (when provided by your integration):
- Rain probability
- Sunshine hours
- UV index
- Thunderstorm probability
- Wind speed
### Display Settings
![Settings EU](docs/pics/eu_settings.png)
![Settings US](docs/pics/us_settings.png)
## Display Settings
- Restart NSPanel
- Sleep mode - display off after time X
- Display brightness slider
- Display dim brightness slider
- Status Brightness in %
### Boot
![Boot EU](docs/pics/eu_boot.png)
![Boot US](docs/pics/us_boot.png)
## Thanks to:
SmartHome Yourself: https://www.youtube.com/c/SmarthomeyourselfDe_DIY
## Home Assistant interface
Masto: https://github.com/masto/NSPanel-Demo-Files
## Device's page
Marcfager: https://github.com/marcfager/nspanel-mf
On the device's page under "Devices & Services" you can set the global configuration of your device and see the value of it's sensors and relays:
lovejoy77: https://github.com/lovejoy777/NSpanel
![Device Setting - Controls](docs/pics/ha_device_controls.png)
Hellis81: https://github.com/Hellis81/NS-panel
![Device Setting - Sensors](docs/pics/ha_device_sensors.png)
![Device Setting - Configuration](docs/pics/ha_device_configuration.png)
![Device Setting - Diagnostic](docs/pics/ha_device_diagnostic.png)
## Automation (Blueprint)
In your automations you use the blueprint's inputs to define what will be shown on your panel and how it should behave:
![Blueprint 01](docs/pics/ha_blueprint_01.png)
![Blueprint 02](docs/pics/ha_blueprint_02.png)
![Blueprint 03](docs/pics/ha_blueprint_03.png)
![Blueprint 04](docs/pics/ha_blueprint_04.png)
![Blueprint 05](docs/pics/ha_blueprint_05.png)
## 🚀 Contributing
- **Pull Requests:** Please direct all pull requests to the `DEV` branch, not the `main` branch.
- **Join Our Team:** We're on the lookout for enthusiasts in programming, documentation, and translation. Interested? Please let us know.
## 🌍 Community & Support
Join our vibrant community! Whether you're seeking support, wanting to contribute, or just looking to share your NSPanel journey, we're here for you.
- **[Issues & Feature requests](https://github.com/Blackymas/NSPanel_HA_Blueprint/issues)**
- **[Discussion Forum](https://github.com/Blackymas/NSPanel_HA_Blueprint/discussions)**
- **[Home Assistant Community](https://community.home-assistant.io/t/sonoff-nspanel-blueprint-configure-your-own-custom-nspanel-easy-via-a-blueprint/500577)**
## 🎉 Acknowledgements
A huge thank you to everyone who has contributed to making this project a reality. Your support, feedback, and contributions have been invaluable.
And special thanks for the other projects which inspired us:
- [Hellis81](https://github.com/Hellis81/NS-panel)
- [Jimmyboy83](https://github.com/Jimmyboy83/nspanel)
- [joBr99](https://github.com/joBr99/Generate-HASP-Fonts)
- [lovejoy77](https://github.com/lovejoy777/NSpanel)
- [Marcfager](https://github.com/marcfager/nspanel-mf)
- [Masto](https://github.com/masto/NSPanel-Demo-Files)
- [sairon](https://github.com/sairon/esphome-nspanel-lovelace-ui)
- [SmartHome Yourself](https://www.youtube.com/c/SmarthomeyourselfDe_DIY)
## 💖 Donations
Are you happy with our version for NSPanel? Please consider supporting us with a donation.
[![Paypal](https://user-images.githubusercontent.com/41958506/212499642-b2fd097a-0938-4bfc-b37b-74df64592c58.png)](https://www.paypal.com/donate/?hosted_button_id=S974SWQMB8PB2)

341
ReleaseNotes.md Normal file
View File

@@ -0,0 +1,341 @@
# v4.2 - Multi-Alarm Control, Dual Thermostat Functionality, and More
## Support this project
**As always, we would like to thank everyone who donated to this project and remind you that every donation helps to support this project
So if you haven't made a donation yet, now would be a good time ;)**
[![Paypal](https://user-images.githubusercontent.com/41958506/212499642-b2fd097a-0938-4bfc-b37b-74df64592c58.png)](https://www.paypal.com/donate/?hosted_button_id=S974SWQMB8PB2)
## General
Hello everyone! In our latest update, we've made some great strides to enhance your experience.
We've fine-tuned the TFT upload process, making it smoother and more user-friendly for both newbies and veterans.
Exciting news we've introduced multiple alarm control panels and added support for dual target temperature thermostats, complete with a handy new add-on.
On top of that, you've got more customization freedom now. Play around with additional custom buttons and icon size settings on your Home and button pages.
Oh, and don't miss the new clock feature on the sleep page it's a small but nifty addition!
Dive into the details below and see how these improvements can upgrade your day-to-day. Looking forward to your feedback!
### Upcoming Change: Switching to ESP-IDF Framework by March 2024
Exciting news for our community in just a couple of months, by March 2024, we'll be transitioning to the **ESP-IDF** as our default framework.
This upgrade is designed to significantly increase the available memory on the ESP, making more room for new features and your customizations.
While the change is around the corner, there's no need to rush. You have time to get ready for this transition.
When it's time to switch, youll need to flash your device using a serial cable, similar to what you did for your first custom firmware installation.
If you happen to need a serial firmware installation before March, consider giving `esp-idf` a try earlier.
Its already supported and a good step towards future-proofing your setup.
And if you're not able to make the switch by March or can't flash via serial, don't worry.
Youll still have the option to use the `arduino` framework and update your device wirelessly (OTA).
For all the details on customizing the framework, our [customization docs](docs/customization.md#framework-esp-idf) are there to help.
We're committed to making this transition as smooth as possible, so reach out if you have any concerns or need assistance.
## Updating
Updates may come with changes on the blueprint inputs and 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.
### Files that need to be reloaded
1. nspanel_eu.tft, nspanel_us.tft or nspanel_us_land.tft - v4.2
2. nspanel_esphome.yaml - v4.2
3. nspanel_blueprint.yaml - v4.2
### Instructions
*You can find the update procedures following here:*
- [How To - All important thing you should know - Update](docs/howto.md#update-blueprint)
## Breaking changes
1. **The `background` parameter in the `esphome.xxxxx_set_component_color` service is now deprecated.**
2. **On the home and climate pages, the button layout has changed.**
This adjustment was made to incorporate additional custom buttons on the home page and new target temperature indicators on the climate page.
3. **Wi-Fi power save mode has been reset to `NONE` as the default setting.**
This was the standard up to v4.0. We switched it in v4.1 to accommodate Bluetooth components.
However, since this feature isn't widely used, we're reverting to the original setting.
For Bluetooth usage, you should manually set a different mode, such as `LIGHT`, as shown in the customization example below:
```yaml
##### My customization - Start #####
# Enable Bluetooth proxy
bluetooth_proxy:
# Set Wi-Fi power save mode to "LIGHT" as required for Bluetooth on ESP32
wifi:
power_save_mode: LIGHT
##### My customization - End #####
```
4. **The default baud rate for advanced mode has been reverted to 115200 bps** to resolve issues that arise when rendering button pages.
5. **ESPHome v2023.12.0 has been established as the minimum required version** to ensure optimal performance and compatibility, particularly with the recent developments in the Nextion component.
6. **The Alarm section in the blueprint settings has been removed.** All configurations previously made in this section have been automatically transferred to custom button 07.
7. **Documentation in German is no longer maintained.** This change allows us to more efficiently update and maintain the remaining documentation.
8. **Reversion to "Toggle" as default action for automation entities on buttons.**
In this update, we have reverted the default action for button presses on automation. entities back to "Toggle".
This change reverses the adjustment made in version 4.1, where "Trigger" was set as the default action.
**Impact:**
- **Default Behavior:** With this reversion, pressing a button linked to an automation entity will now enable or disable the automation, as it did prior to version 4.1.
- **Consistency and Familiarity:** This change aims to align with user expectations and maintain consistency in the user experience.
- **Customization Still Available:** Users still have the option to manually set "Trigger" as the action for their `automation.` entities, as per their preference.
We understand that changes in default settings can impact your workflows.
We appreciate your understanding as we strive to balance new features with the familiarity and stability of the user experience.
9. **Advanced mode no longer enforces a specific framework.**
In the past, the enforcement of framework changes by the advanced mode could inadvertently result in users switching frameworks during OTA updates.
This practice was not recommended due to the potential for errors.
10. **Alarm page cannot be used as wake-up page.**
As multiple alarms are supported now, the system don't know which one to show on the wake-up.
11. **Changes in icon presentation.**
As part of our efforts to standardize icons across various pages, you might notice some differences in how they appear and behave.
This includes new colors for lights and climate icons, as well as the introduction of new icon designs.
While many aspects can still be customized through blueprint settings, the default presentation will now adhere to this new standardized format.
These changes might be a departure from what you're accustomed to in previous versions, but they aim to enhance overall consistency and user experience.
12. ***Action required:* Reset your wake-up page selection.**
We've enhanced the wake-up page functionality for improved consistency after power cycles.
Previously, the system didn't remember your selection following a power outage.
With our latest update, this issue has been resolved.
However, this improvement requires you to reselect your wake-up page one more time.
Thanks for your cooperation in making these settings more reliable for everyday use.
## Overview of noteworthy changes
1. Standardized entity icons
2. Additional custom buttons on Home page
3. Outdoor temperature selectable font size
4. Select icon size for button's pages
5. Support to CJK languages (experimental)
6. Improved TFT transfer
7. Multiple Alarm Control Panels
8. Support to `remote`
9. Home page chips now supports covers
10. Chips can be inverted
11. Add swipe control to screensaver page
12. Enhanced control for automation entities on buttons
13. Dual thermostat controller support (add-on)
14. Dual thermostat display
15. Enhanced timeout flexibility for Sleep, Page fallback, and Dimming settings
16. Display time on the `screensaver` page
## Details of noteworthy changes
### 1. Standardized entity icons
The engine for defining the icons to be shown and it's color was standardize between all the pages, so now you may see a more consistent User's Interface.
We've upgraded the icon definition engine to standardize the appearance and color of icons across all pages.
This enhancement leads to a more consistent and harmonious user interface.
Expect a unified visual experience that aligns the look and feel of icons throughout the system, contributing to improved navigation and aesthetic appeal.
### 2. Additional custom buttons on Home page
It's that simple, now you have 7 buttons where used to be 3.
Well, where used to be 4, as the space previously used by the Alarm button is now a custom button. 😉
### 3. Outdoor temperature selectable font size
Now you can select the font size of your outdoor temperature display:
![image](https://github.com/Blackymas/NSPanel_HA_Blueprint/assets/94725493/263f14d6-39f7-41d2-ae12-72f403d811fd)
> Important: Long text with bigger fonts may exceed the limit of space reserved for this with incomplete information shown.
### 4. Select icon size for button's pages
You can also select the size of the icons on the buttos pages:
![HA Blueprint - Buttons pages icon's size](docs/pics/ha_blueprint_buttons_pages_icon_size.png)
![EU Buttons pages - Small icons](docs/pics/eu_buttonpages_icon_small.png)
![EU Buttons pages - Large icons](docs/pics/eu_buttonpages_icon_large.png)
### 5. Support to CJK languages (experimental)
You will find 3 new TFT files on the repository for the CJK languages.
These files are considerably bigger, as the fonts requires more memory, but it should work fine in your panel.
**ATTENTION:** This is an experimental feature and may contain bugs or some areas missing translations.
Please report if you find anything.
### 6. Improved TFT transfer
#### TFT file selectors
We still working on the Upload TFT engine to make it easier for new and for experienced users.
Now, together with the **Update TFT Display** button, you will find also **Update TFT Display - Model** and **Update TFT Display - Branch** (disabled by default)
where you can select the different model you are using and the upload URL will be automatically adjusted to donwload the file directly from the repository on GitHub,
making this process much easier and removing the need of flashing your device every time you want to play with another TFT file or install the `nspanel_blank.tft`.
![HA Blueprint - Update TFT controls](docs/pics/ha_blueprint_upload_tft_controls.png)
If you have issues with the remote file and want to transfer it from your local server just as before, simply select **Use nextion_update_url** in **Update TFT Display - Model**.
And you also can use the `esphome.xxxxx_upload_tft_url` service to upload using an alternative URL without the need of flash your panel again.
#### Alternative baud rate for TFT uploads
You can select an alternative baud rate for your TFT uploads.
This allows faster TFT uploads and also supports displays previously set with baud rates not supported by this project (currently 115200 bps and 921600 bps).
In most cases, this would be set for a higher value to enable faster TFT transfer.
The default is 921600 bps, the maximum supported by Nextion displays.
You can also use this if you have issues with TFT transfer and want to try a lower baud rate as in some rare cases Nextion will automatically set itself to 9600 bps.
To enable an alternative upload TFT baud rate, add the desired value in your substitutions like this:
```yaml
upload_tft_baud_rate: "9600"
```
If an invalid value is entered, 115200 bps will be used.
The default value for this substitution (in case it is not set by users) will be 921600 bps.
During a TFT transfer, the system will always fall back to the standard baud rate (115200 bps) if other tentatives fails.
### 7. Multiple Alarm Control Panels
Now alarm control panel entities can be assigned to chips and custom buttons in the Home page,
but also to hardware buttons, any of the buttons pages or entities pages, similarly to other domains.
### 8. Support to `remote`
Entities from the `remote` domain can now be assigned to buttons (hardware and buttons pages) and custom buttons (home and climate pages).
The service `remote.toggle` will be called when the button is pressed.
### 9. Home page chips now supports covers
That's it!
Chips now include cover visualization, allowing for easy monitoring of covers directly from the Home page.
### 10. Chips can be inverted
Chips now have an 'invert' option on the blueprint settings, providing additional customization flexibility.
### 11. Add swipe control to Screensaver page
You can now navigate to button pages from the screensaver while your panel is in sleep mode.
The swipe controls will function as they do on the Home page.
### 12. Enhanced control for automation entities on buttons
We're pleased to announce a new feature that offers users enhanced control over their smart home setups.
Now, you can globally select between **Toggle** and **Trigger** actions for button presses on automation entities.
This update allows for a more personalized and efficient control experience, tailored to your unique preferences.
#### Key features
- **Toggle:** This action will enable or disable the automation.
It is set as the default option.
- **Trigger:** This action will execute the automation regardless of its current state, providing more flexibility.
#### How to use
1. Access your configuration for automation under **Services** > **Automations & Scenes**.
Select the automation associated with your panel setup.
1. Scroll to the **ADVANCED SETTINGS** section at the end.
1. From the menu, select your desired action - either **Toggle** or **Trigger**.
1. Apply the setting.
This will then be effective across all relevant entities.
This update is specially designed to cater to diverse user needs, ensuring a more intuitive and responsive smart home experience.
### 13. Dual thermostat controller support (add-on)
This new add-on enables the NSPanel to manage both heating and cooling systems simultaneously, utilizing its dual relay functionality.
#### Key Benefits
- **Versatility:** Users can now configure their NSPanel to control both a heater and a cooler, offering increased flexibility in home temperature management.
- **Efficiency:** With the ability to control both heating and cooling systems, the NSPanel can more effectively maintain desired temperatures, potentially leading to energy savings.
- **User Experience:** This update simplifies the user interface by integrating control of both systems into one panel, making it easier to manage home climate.
#### Implementation Details
- The dual thermostat controller functionality allows the NSPanel to utilize both of its relays for separate heating and cooling control.
Users can configure their heating and cooling settings independently, providing a tailored climate control experience.
- The update is designed to be intuitive and user-friendly, ensuring a seamless transition for existing NSPanel users.
- Additional Documentation: For detailed instructions and configurations, refer to the updated [add-on climate documentation](docs/addon_climate.md).
#### Note to Users
This feature enhances the capabilities of the NSPanel without compromising its existing functionalities.
Users who previously used the NSPanel for single-mode (either heating or cooling) control can
now explore dual-mode options for a more comprehensive climate control solution.
### 14. Enhanced Climate Page for Dual Thermostat Control
Leveraging the capabilities introduced with the Dual Thermostat Controller add-on,
the existing climate page has been upgraded to support systems with dual temperature settings.
This enhancement allows users to effectively manage thermostats that require both heating and cooling target temperatures, directly from the NSPanel's interface.
While originally developed to complement the new add-on,
this refined climate page also seamlessly extends its functionality to existing thermostats with dual set capabilities,
offering a more versatile and comprehensive climate control experience.
### 15. Enhanced timeout flexibility for Sleep, Page fallback, and Dimming settings
We have improved the functionality of our system by enhancing the timeout flexibility for Sleep, Page Fallback, and Dimming settings.
The previous timeout limit of 300 seconds has been significantly expanded, offering users more control and customization options for these specific features.
This enhancement allows for a wider range of use cases, catering to the needs of those who require extended periods for these settings,
while still maintaining the option for shorter durations.
### 16. Display time on the `screensaver` page
In this release, we're excited to introduce a new feature that adds a display time function to the Screensaver page.
With this update, our screensaver not only serves its primary purpose of saving screen energy but also doubles as an informative display,
reflecting our commitment to creating practical, user-friendly solutions.
You can enable this feature on the bueprint settings, at the **CUSTOM CONFIGURATION** section (almost at the end).
You also have to set **Display Brightness Sleep** at the device's page (**Settings** > **Devices & Services** > **ESPHome**).
## What's Next?
Discover what's next and what we are working on right now in our [Milestones](https://github.com/Blackymas/NSPanel_HA_Blueprint/milestones?direction=asc&sort=due_date)
## Special thanks to
- @bluefoxlee - For the CJK fonts and all the support with #1359.
- @Floppe - Fix entity pages labels, #1455
- @tikismoke - Customization guide: Exposing relay fallback switch to Home Assistant, #1537
## Previous releases
- [v4.1.4 - Support to Home Assistant 2023.12.0](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.1.4)
- [v4.1.3 - Bug fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.1.3)
- [v4.1.2 - Bug fixes and minor enhancements](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.1.2)
- [v4.1.1 - UI Enhancements and Reintroduction of `play_rtttl` Service](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.1.1)
- [v4.1 - Easier TFT transfer](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.1)
- [v4.0.2 - Bug fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.0.2)
- [v4.0.1 - Bug fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.0.1)
- [v4.0 - Alarm and Media player pages, Climate add-ons and a more robust panel](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v4.0)
- [v3.4.1 - Patch for issues when compiling with ESPHome 2023.7.0](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v3.4.1)
- [v3.4 - New climate page and some bug fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v3.4)
- [v3.3 - New improvements and some issues fixed](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v.3.3)
- [v3.2.2 - fixed some bugs performance improvement](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v3.2.2)
- [v3.2.1 - New features and some fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v3.2.1)
- [v3.2 - New features and custom configurations](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v.3.2)
- [v3.1.0 - New features and US Version](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v.3.1.0)
- [v3.0.0 - major update with many features and improvements](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v.3.0.0)
- [v2.2.0 - 25 new languages added](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v.2.2.0)
- [v2.1.0 - New Domains, Buttons and Button Page Label](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v2.1.0)
- [v2.0.2](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v2.0.2)
- [v2.0.1 - Bug Fixes](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v2.0.1)
- [v2.0.0](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/v2.0.0)
- [v1.0.1 Blueprint](https://github.com/Blackymas/NSPanel_HA_Blueprint/releases/tag/latest)

15
advanced/.gitignore vendored Normal file
View File

@@ -0,0 +1,15 @@
# Ignore Mac DS_Store files
.DS_Store
**/.DS_Store
Nextion2Text.*
*.cmd
*.bat
# Ignore IntelliJ IDEA project directory
.idea
# Ignore dev folder
dev
#nspanel_esphome_prebuilt.yaml

5
advanced/esphome/.gitignore vendored Normal file
View File

@@ -0,0 +1,5 @@
# Gitignore settings for ESPHome
# This is an example and may include too much for your use-case.
# You can modify this file to suit your needs.
/.esphome/
/secrets.yaml

View File

@@ -0,0 +1,213 @@
#####################################################################################################
##### NSPANEL ESPHOME created by Blackymas - https://github.com/Blackymas/NSPanel_HA_Blueprint #####
##### ESPHome Add-on for Climate control - Shared - This will be called by heat/cool #####
##### PLEASE only make changes if it is necessary and also the required knowledge is available. #####
##### For normal use with the Blueprint, no changes are necessary. #####
#####################################################################################################
##### ATTENTION: This will add climate elements to the core system and requires the core part. #####
#####################################################################################################
---
substitutions:
### Local thermostat defaults ###
# https://esphome.io/components/climate/thermostat.html
heater_relay: "0" # Select 1 for "Relay 1", 2 for "Relay 2" or "0" to a dummy switch/disabled
cooler_relay: "0" # Select 1 for "Relay 1", 2 for "Relay 2" or "0" to a dummy switch/disabled
min_off_time: "300"
min_run_time: "300"
min_idle_time: "30"
# https://esphome.io/components/climate/index.html#base-climate-configuration
temp_min: "7"
temp_max: "35"
temp_step: "0.5"
target_low: "18"
target_high: "24"
##### DO NOT CHANGE THIS #####
addon_climate_cool: "false"
addon_climate_heat: "false"
addon_climate_dual: "false"
##############################
climate:
- platform: thermostat
name: ${device_name} Thermostat
id: thermostat_embedded
sensor: temp_nspanel
min_idle_time: ${min_idle_time}s
visual:
min_temperature: ${temp_min} ${temp_units}
max_temperature: ${temp_max} ${temp_units}
temperature_step:
target_temperature: 0.5 # This is hard coded for now as ESPHome isn't supporting a substitution here. In contact with support.
current_temperature: 0.1
idle_action:
- switch.turn_off: relay_${heater_relay}
default_preset: "Off"
on_boot_restore_from: memory
internal: false
on_state:
- lambda: |-
static const char *const TAG = "addon_climate_base.climate.thermostat_embedded.on_state";
ESP_LOGD(TAG, "Starting");
page_climate->execute();
page_home->execute();
ESP_LOGD(TAG, "Finished");
globals:
##### Is embedded thermostat visible on climate page? #####
- id: is_addon_climate_visible
type: bool
restore_value: false
initial_value: 'false'
##### Embeded climate friendly name #####
- id: addon_climate_friendly_name
type: std::string
restore_value: false
initial_value: '"${device_name} Thermostat"'
switch:
##### PHYSICAL SWITCH 0 (Dummy) - Used when relay is not set #####
- name: ${device_name} Relay 0 (dummy)
platform: template
id: relay_0
lambda: !lambda return false;
internal: true
optimistic: true
script:
- id: !extend addon_climate_service_call
then:
- lambda: |-
id(is_addon_climate_visible) = true;
disp1->set_component_value("climate.embedded", 1);
auto call = thermostat_embedded->make_call();
if (key == "set_temperature")
call.set_target_temperature(stof(value) / 10);
else if (key == "hvac_mode")
call.set_mode(value);
call.perform();
- id: !extend global_settings
then:
- lambda: |-
id(addon_climate_friendly_name) = embedded_climate_friendly_name;
- id: !extend open_entity_settings_page
then:
- lambda: |-
if (page == "climate" and entity == "embedded_climate")
id(addon_climate_friendly_name) = page_label;
- id: !extend page_climate
then:
- lambda: |-
if (current_page->state == "climate" and id(is_addon_climate_visible))
{
disp1->set_component_text_printf("page_label", id(addon_climate_friendly_name).c_str());
float temp_step = ${temp_step};
float temp_offset = ${temp_min};
float temp_max = ${temp_max};
float total_steps = (temp_max-temp_offset)/temp_step;
uint supported_hvac_modes = 0;
if (${addon_climate_dual})
supported_hvac_modes = 3;
else
supported_hvac_modes = supported_hvac_modes + ((${addon_climate_heat}) ? 1 : 0) + ((${addon_climate_cool}) ? 2 : 0);
set_climate->execute
(
thermostat_embedded->current_temperature, // current_temp
0, // supported_features
thermostat_embedded->target_temperature, // target_temp
thermostat_embedded->target_temperature_high, // target_temp_high
thermostat_embedded->target_temperature_low, // target_temp_low
int(round(${temp_step}*10)), // temp_step
int(round(total_steps)), // total_steps //int(round((10*thermostat_embedded->target_temperature-temp_offset)/temp_step)), // slider_val
int(round(${temp_min}*10)), // temp_offset
"", // climate_icon
true // embedded_climate
);
// Update target temp icon
update_climate_icon->execute("target_icon", int(thermostat_embedded->action), int(thermostat_embedded->mode));
// Update buttons bar
// Hide not supported hotspots
disp1->hide_component("button01");
if (${addon_climate_dual}) disp1->show_component("button02"); else disp1->hide_component("button02");
if (${addon_climate_heat} or ${addon_climate_dual}) disp1->show_component("button03"); else disp1->hide_component("button03"); //Heat
if (${addon_climate_cool} or ${addon_climate_dual}) disp1->show_component("button04"); else disp1->hide_component("button04"); //Cool
disp1->hide_component("button05");
disp1->hide_component("button06");
disp1->show_component("button07"); //Off
// Set buttons colors
disp1->set_component_font_color("button01", 6339);
disp1->set_component_font_color("button02", (thermostat_embedded->mode==climate::CLIMATE_MODE_HEAT_COOL) ? 65535 : ((${addon_climate_dual}) ? 48631 : 6339));
disp1->set_component_font_color("button03", (thermostat_embedded->mode==climate::CLIMATE_MODE_HEAT) ? 64164 : ((${addon_climate_heat} or ${addon_climate_dual}) ? 48631 : 6339));
disp1->set_component_font_color("button04", (thermostat_embedded->mode==climate::CLIMATE_MODE_COOL) ? 1055 : ((${addon_climate_cool} or ${addon_climate_dual}) ? 48631 : 6339));
disp1->set_component_font_color("button05", 6339);
disp1->set_component_font_color("button06", 6339);
disp1->set_component_font_color("button07", (thermostat_embedded->mode==climate::CLIMATE_MODE_OFF) ? 10597 : 35921);
}
- id: !extend page_changed
then:
- lambda: |-
id(is_addon_climate_visible) = (page == "climate" and detailed_entity->state == "embedded_climate");
- id: !extend page_home
then:
- lambda: |-
// Update chips
if (id(is_embedded_thermostat))
update_climate_icon->execute("home.icon_top_03", int(thermostat_embedded->action), int(thermostat_embedded->mode));
- id: !extend set_climate
then:
- lambda: |-
if (current_page->state == "climate")
id(is_addon_climate_visible) = embedded_climate;
- id: !extend watchdog
then:
- lambda: |-
static const char *const TAG = "addon_climate_base.script.watchdog";
bool addon_climate_cool = ${addon_climate_cool};
bool addon_climate_heat = ${addon_climate_heat};
bool addon_climate_dual = ${addon_climate_dual};
uint cooler_relay = ${cooler_relay};
uint heater_relay = ${heater_relay};
ESP_LOGI(TAG, "Add-on climate:");
if (addon_climate_cool) {
ESP_LOGI(TAG, " Cool: %s", addon_climate_cool ? "Enabled" : "Disabled");
if (cooler_relay == 1 or cooler_relay == 2)
ESP_LOGI(TAG, " Relay: %i", cooler_relay);
else
ESP_LOGE(TAG, " Relay: %i", cooler_relay);
}
if (addon_climate_heat) {
ESP_LOGI(TAG, " Heat: %s", addon_climate_heat ? "Enabled" : "Disabled");
if (heater_relay == 1 or heater_relay == 2)
ESP_LOGI(TAG, " Relay: %i", heater_relay);
else
ESP_LOGE(TAG, " Relay: %i", heater_relay);
}
if (addon_climate_dual) {
ESP_LOGI(TAG, " Dual: %s", addon_climate_dual ? "Enabled" : "Disabled");
if (cooler_relay == 1 or cooler_relay == 2)
ESP_LOGI(TAG, " Relay (cooler): %i", cooler_relay);
else
ESP_LOGE(TAG, " Relay (cooler): %i", cooler_relay);
if (heater_relay == 1 or heater_relay == 2)
ESP_LOGI(TAG, " Relay (heater): %i", heater_relay);
else
ESP_LOGE(TAG, " Relay (heater): %i", heater_relay);
if (cooler_relay == heater_relay)
ESP_LOGE(TAG, " Double relay assignment");
}
if ((addon_climate_cool && addon_climate_heat) ||
(addon_climate_cool && addon_climate_dual) ||
(addon_climate_heat && addon_climate_dual) ||
(!addon_climate_cool && !addon_climate_heat && !addon_climate_dual)) {
ESP_LOGE(TAG, "Invalid settings for add-on Climate");
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,99 @@
#####################################################################################################
##### NSPANEL ESPHOME created by Blackymas - https://github.com/Blackymas/NSPanel_HA_Blueprint #####
##### ESPHOME ADVANCED #####
##### PLEASE only make changes if it is necessary and also the required knowledge is available. #####
##### For normal use with the Blueprint, no changes are necessary. #####
#####################################################################################################
##### ATTENTION: This will add advanced elements to the core system and requires the core part. #####
#####################################################################################################
---
substitutions:
##### Do not change this here. #####
##### Set your substitutions on #####
##### your base yaml file. #####
web_password: ${wifi_password}
#####################################
button:
##### EXIT REPARSE TFT DISPLAY #####
- name: ${device_name} Exit reparse
platform: template
icon: mdi:file-sync
id: tft_reparse_off
entity_category: config
on_press:
- logger.log: "Button pressed: Exit reparse"
- script.execute: exit_reparse
##### UPDATE TFT BLANK DISPLAY #####
- name: ${device_name} Update TFT display (blank)
platform: template
icon: mdi:file-sync
id: tft_update_blank
entity_category: config
on_press:
- lambda: |-
static const char *const TAG = "button.tft_update_blank";
ESP_LOGD(TAG, "Button pressed: Update TFT display (blank)");
upload_tft->execute("${nextion_blank_url}");
captive_portal:
sensor:
##### Uptime Sensors #####
- name: ${device_name} Uptime seconds
id: uptime_sec
platform: uptime
internal: true
- name: ${device_name} API uptime
id: api_timestamp
platform: template
lambda: 'return id(time_provider).now().timestamp;'
internal: false
device_class: timestamp
entity_category: diagnostic
accuracy_decimals: 0
update_interval: never
- name: ${device_name} Device uptime
id: device_timestamp
platform: template
lambda: 'return (id(time_provider).now().timestamp - id(uptime_sec).state);'
internal: false
device_class: timestamp
entity_category: diagnostic
accuracy_decimals: 0
update_interval: never
text_sensor:
##### ESPhome version used to compile the app #####
- name: ${device_name} ESPhome Version
platform: version
disabled_by_default: true
- platform: wifi_info
ip_address:
name: ${device_name} IP
disabled_by_default: true
id: ip_address
ssid:
name: ${device_name} SSID
disabled_by_default: true
bssid:
name: ${device_name} BSSID
disabled_by_default: true
time:
- id: !extend time_provider
on_time_sync:
then:
- component.update: api_timestamp
- component.update: device_timestamp
web_server:
id: web_server_std
port: 80
auth:
username: admin
password: ${web_password}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,79 @@
#####################################################################################################
##### NSPANEL ESPHOME created by Blackymas - https://github.com/Blackymas/NSPanel_HA_Blueprint #####
##### ESPHOME PRE-BUILT #####
##### PLEASE only make changes if it is necessary and also the required knowledge is available. #####
##### For normal use with the Blueprint, no changes are necessary. #####
#####################################################################################################
---
substitutions:
device_name: nspanel
wifi_ssid: nspanel
wifi_password: NSPanel_Blueprint
pre_built: "true"
packages:
core_package: !include ./nspanel_esphome_core.yaml # Core package
upload_tft_package: !include ./nspanel_esphome_addon_upload_tft.yaml # Core package
button:
- platform: factory_reset
name: Factory reset
disabled_by_default: true
internal: false
# In combination with the `ap` this allows the user
# to provision wifi credentials to the device.
captive_portal:
dashboard_import:
package_import_url: github://Blackymas/NSPanel_HA_Blueprint/advanced/esphome/nspanel_esphome_prebuilt.yaml # Must be updated
import_full_config: false
esp32:
framework:
type: esp-idf
# Sets up Bluetooth LE (Only on ESP32) to allow the user
# to provision wifi credentials to the device.
esp32_improv:
authorizer: none
esphome:
name_add_mac_suffix: true
project:
name: esphome.NSPanel_HA_Blueprint
version: "${version}"
# Sets up the improv via serial client for Wi-Fi provisioning
improv_serial:
logger:
baud_rate: 115200
ota:
password: ""
script:
- id: !extend watchdog
then:
- lambda: |-
static const char *const TAG = "prebuilt.script.watchdog";
ESP_LOGI(TAG, "Pre-built version: ${pre_built}");
select:
- id: !extend tft_file_model
platform: template
options:
- "NSPanel Blank"
- "NSPanel EU"
- "NSPanel US"
- "NSPanel US Landscape"
- "NSPanel EU (CJK languages)"
- "NSPanel US (CJK languages)"
- "NSPanel US Landscape (CJK languages)"
initial_option: "NSPanel Blank"
wifi:
ap: {}
power_save_mode: LIGHT # To make it compatible with BLE

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,21 @@
Program.s
//The following code is only run once when power on, and is generally used for global variable definition and power on initialization data
int sys0=0,sys1=0,sys2=0,swipex=0,swipey=0,swipex2=0,swipey2=0,swipec=0,swipec2=0,swipedx=100,swipedy=100 //At present, the definition of global variable only supports 4-byte signed integer (int), and other types of global quantity declaration are not supported. If you want to use string type, you can use variable control in the page to implement
int r=0,g=0,b=0
int h=0,s=0,v=0
int p=0,q=0,t=0,f=0
int back_page_id=0
int dimdelta=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40,brightness_sleep=0
int display_mode=1 // 1 = EU, 2 = US, 3 = US landscape, 4 = blank
int charset=2 // 1 = International (original), 2 = CJK
//bauds=115200//Configure baudrate
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port
if(display_mode==1)
{
lcd_dev fffb 0002 0000 0020// Fix touch offset for EU Version
}
page 8//Power on start page boot

View File

@@ -0,0 +1,411 @@
Page alarm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis bt_home,0
vis bt_away,0
vis bt_night,0
vis bt_vacat,0
vis bt_bypass,0
}
Variable (string) lastclick
Attributes
ID : 3
Scope : local
Text :
Max. Text Size: 255
Variable (string) code_format
Attributes
ID : 28
Scope : local
Text :
Max. Text Size: 15
Variable (string) code_arm_req
Attributes
ID : 29
Scope : local
Text :
Max. Text Size: 1
Text page_label
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Alarm Control Panel
Max. Text Size : 100
Text icon_state
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’—
Max. Text Size : 10
Text bt_home_text
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Home
Max. Text Size : 22
Text bt_away_text
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Away
Max. Text Size : 22
Text bt_night_text
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Night
Max. Text Size : 22
Text bt_vacat_text
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Vacation
Max. Text Size : 22
Text bt_bypass_text
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Bypass
Max. Text Size : 22
Text bt_disarm_text
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Disarm
Max. Text Size : 22
Text bt_home_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_away_icon
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_night_icon
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : ï §
Max. Text Size : 3
Text bt_vacat_icon
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_bypass_icon
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_disarm_icon
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Picture bt_home_pic
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_away_pic
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_night_pic
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_vacat_pic
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_bypass_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_disarm_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: disabled
Button button_back
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot bt_home
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_home_pic.pic=44
bt_home_text.bco=65024
bt_home_text.pco=0
bt_home_icon.bco=65024
bt_home_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"home\", \"value\": \"click\", \"mui\": \""+bt_home_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_away
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_away_pic.pic=44
bt_away_text.bco=65024
bt_away_text.pco=0
bt_away_icon.bco=65024
bt_away_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"away\", \"value\": \"click\", \"mui\": \""+bt_away_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_night
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_night_pic.pic=44
bt_night_text.bco=65024
bt_night_text.pco=0
bt_night_icon.bco=65024
bt_night_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"night\", \"value\": \"click\", \"mui\": \""+bt_night_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_vacat
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_vacat_pic.pic=44
bt_vacat_text.bco=65024
bt_vacat_text.pco=0
bt_vacat_icon.bco=65024
bt_vacat_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"vacation\", \"value\": \"click\", \"mui\": \""+bt_vacat_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_bypass
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_bypass_pic.pic=44
bt_bypass_text.bco=65024
bt_bypass_text.pco=0
bt_bypass_icon.bco=65024
bt_bypass_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"bypass\", \"value\": \"click\", \"mui\": \""+bt_bypass_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_disarm
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_disarm_pic.pic=44
bt_disarm_text.bco=65024
bt_disarm_text.pco=0
bt_disarm_icon.bco=65024
bt_disarm_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"disarm\", \"value\": \"click\", \"mui\": \""+bt_disarm_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer wakeup_timer
Attributes
ID : 31
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,200 @@
Page boot
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
dim=100
vis bt_reboot,0
sendme
dim=100
vis bt_reboot,0
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"
Page Exit Event
dim=0
Variable (int32) counter
Attributes
ID : 11
Scope: local
Value: 0
Variable (string) aux1
Attributes
ID : 12
Scope : local
Text :
Max. Text Size: 10
Text ip_addr
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Initializing...
Max. Text Size : 15
Text t0
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please wait...
Max. Text Size : 15
Text t1
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : The process can take several seconds!
Max. Text Size : 50
Text tft_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : TFT:
Max. Text Size : 4
Text esph_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ESPHome:
Max. Text Size : 8
Text bluep_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Blueprint:
Max. Text Size : 10
Text tft_version
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 4.2beta.2
Max. Text Size : 9
Text esph_version
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text bluep_version
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text baud_rate
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text framework
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Dual-state Button bt_reboot
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : Reboot
Max. Text Size : 6
Timer tm_esphome
Attributes
ID : 13
Scope : local
Period (ms): 30000
Enabled : yes
Events
Timer Event
counter.val++
if(counter.val>60)
{
rest
}
sendme
printh 91
prints "display_mode",0
printh 00
prints display_mode,0
printh FF FF FF
printh 91
prints "charset",0
printh 00
prints charset,0
printh FF FF FF
printh 92
prints "tft_version",0
printh 00
prints tft_version.txt,0
printh 00
printh FF FF FF
covx counter.val,aux1.txt,0,0
esph_version.txt="Retry #"+aux1.txt
sys0=counter.val%10
if(sys0==0)
{
baud=115200
}
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"

View File

@@ -0,0 +1,792 @@
Page buttonpage01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage01
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page home
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage02
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage03
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage04
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page home
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,867 @@
Page climate
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==1||embedded.val==1)
{
sendme
vis target_icon,0
vis target_high,0
vis target_low,0
vis current_temp,0
vis climateslider,0
vis slider_high,0
vis slider_low,0
vis button01,0
vis button02,0
vis button03,0
vis button04,0
vis button05,0
vis button06,0
vis button07,0
}else
{
page home
}
Page Exit Event
covx embedded.val,va2.txt,0,0
if(timer0.en==1)
{
timer0.en=0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer1.en==1)
{
timer1.en=0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer2.en==1)
{
timer2.en=0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
Variable (string) va1
Attributes
ID : 24
Scope : local
Text :
Max. Text Size: 10
Variable (string) climatesetting
Attributes
ID : 25
Scope : local
Text :
Max. Text Size: 255
Variable (string) lastclick
Attributes
ID : 26
Scope : local
Text :
Max. Text Size: 255
Variable (int32) temp_offset
Attributes
ID : 28
Scope: local
Value: 0
Variable (int32) temp_step
Attributes
ID : 29
Scope: local
Value: 0
Variable (int32) temp_number0
Attributes
ID : 33
Scope: local
Value: 0
Variable (int32) va0
Attributes
ID : 34
Scope: local
Value: 0
Variable (int32) embedded
Attributes
ID : 35
Scope: global
Value: 0
Variable (string) va2
Attributes
ID : 36
Scope : local
Text :
Max. Text Size: 10
Variable (string) click_comp
Attributes
ID : 38
Scope : local
Text :
Max. Text Size: 8
Variable (int32) active_slider
Attributes
ID : 42
Scope: local
Value: 1
Variable (int32) is_temp_range
Attributes
ID : 44
Scope: local
Value: 0
Variable (int32) temp_number1
Attributes
ID : 48
Scope: local
Value: 0
Variable (int32) temp_number2
Attributes
ID : 49
Scope: local
Value: 0
Text current_temp
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text page_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text target_icon
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01_icon
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value02_icon
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value03_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text button01
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button02
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button03
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button04
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button05
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button06
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button07
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button08
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button09
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text target_high
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Release Event
active_slider.val=is_temp_range.val
Text target_low
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Release Event
active_slider.val=2
Slider slider_high
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=1
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer1.en=1
Slider slider_low
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=2
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
timer2.en=1
Slider climateslider
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=0
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer0.en=1
Button button_back
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot decrease_temp
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val>0)
{
climateslider.val--
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val>0)
{
slider_high.val--
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val>0)
{
slider_low.val--
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Hotspot increase_temp
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val<climateslider.maxval)
{
climateslider.val++
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val<slider_high.maxval)
{
slider_high.val++
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val<slider_low.maxval)
{
slider_low.val++
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer timer0
Attributes
ID : 27
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
covx embedded.val,va2.txt,0,0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer click_timer
Attributes
ID : 39
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \"climate\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 40
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer timer1
Attributes
ID : 46
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer1.en=0
covx embedded.val,va2.txt,0,0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer timer2
Attributes
ID : 47
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer2.en=0
covx embedded.val,va2.txt,0,0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,151 @@
Page confirm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (int32) page_id
Attributes
ID : 3
Scope: global
Value: 0
Variable (string) aux
Attributes
ID : 5
Scope : local
Text :
Max. Text Size: 255
Variable (string) page_name
Attributes
ID : 9
Scope : global
Text :
Max. Text Size: 12
Variable (string) component
Attributes
ID : 10
Scope : global
Text :
Max. Text Size: 10
Text t0
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text title
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 100
Text body
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 255
Button bclose
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Button bt_accept
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î— 
Max. Text Size : 3
Events
Touch Release Event
aux.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+component.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints aux.txt,0
printh 00
printh FF FF FF
page page_id.val
Button bt_clear
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…™
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Timer wakeup_timer
Attributes
ID : 11
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,202 @@
Page cover
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) va1
Attributes
ID : 7
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (string) coversetting
Attributes
ID : 11
Scope : local
Text :
Max. Text Size: 255
Text battery_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text cover_value
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text icon_state
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text battery_icon
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Slider coverslider
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx coverslider.val,va1.txt,0,0
cover_value.txt=va1.txt+"%"
coversetting.txt="{\"page\": \"cover\", \"key\": \"position\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints coversetting.txt,0
printh 00
printh FF FF FF
Button cover_open
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"open_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_close
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : ï„›
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"close_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_stop
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"stop_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button button_back
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 13
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,376 @@
Page entitypage01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity01_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
page entitypage03
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
page entitypage04
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity02_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity03_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○
Max. Text Size : 12
Button button_back
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
page entitypage01
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity04_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
page entitypage01
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,377 @@
Page fan
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) fansetting
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 255
Variable (string) va0
Attributes
ID : 8
Scope : local
Text :
Max. Text Size: 10
Text fan_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text icon_state
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Slider fanslider
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 4
Lower range limit: 0
Events
Touch Release Event
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
timer0.en=1
Button button_up
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : ï‘­
Max. Text Size : 3
Events
Touch Press Event
if(fanslider.val<fanslider.maxval)
{
fanslider.val++
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
}
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_on
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
fanslider.val=fanslider.maxval/2
sys0=fanslider.maxval*5
sys0%=10
if(sys0>=5)
{
fanslider.val++
}
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_down
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
if(fanslider.val>fanslider.minval)
{
fanslider.val--
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
}
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_off
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
fanslider.val=fanslider.minval
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
fansetting.txt="{\"page\": \"fan\", \"key\": \"stop\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints fansetting.txt,0
printh 00
printh FF FF FF
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=0
Button button_back
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer swipestore
Attributes
ID : 5
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer timer0
Attributes
ID : 13
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
fansetting.txt="{\"page\": \"fan\", \"key\": \"percentage\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints fansetting.txt,0
printh 00
printh FF FF FF
Timer wakeup_timer
Attributes
ID : 15
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 4
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,723 @@
Page home
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
back_page_id=0
vis bt_notific,is_notification
vis bt_qrcode,is_qrcode
vis bt_entities,is_entities
if(display_mode==3)
{
vis left_bt_text,0
vis right_bt_text,0
}
Variable (string) lastclick
Attributes
ID : 33
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 41
Scope : local
Text :
Max. Text Size: 8
Text time
Attributes
ID : 3
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text current_temp
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 8
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"home\", \"component\": \"climate\", \"event\": \"click\"}",0
printh 00
printh FF FF FF
Text outdoor_temp
Attributes
ID : 5
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 8
Text date
Attributes
ID : 6
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text value01_state
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text left_bt_text
Attributes
ID : 9
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text right_bt_text
Attributes
ID : 10
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text icon_top_01
Attributes
ID : 11
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_02
Attributes
ID : 12
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_03
Attributes
ID : 13
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_04
Attributes
ID : 14
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_05
Attributes
ID : 15
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_06
Attributes
ID : 16
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_07
Attributes
ID : 17
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_08
Attributes
ID : 18
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_09
Attributes
ID : 19
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_10
Attributes
ID : 20
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value01_icon
Attributes
ID : 21
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value03_state
Attributes
ID : 22
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 23
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value02_icon
Attributes
ID : 24
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value02_state
Attributes
ID : 25
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text wifi_icon
Attributes
ID : 26
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text indoortempicon
Attributes
ID : 27
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"home\", \"component\": \"climate\", \"event\": \"click\"}",0
printh 00
printh FF FF FF
Text bt_notific
Attributes
ID : 28
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
if(api==1)
{
page notification
}
Text bt_qrcode
Attributes
ID : 29
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
page qrcode
Text bt_entities
Attributes
ID : 30
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
if(api==1)
{
page entitypage01
}
Text button07
Attributes
ID : 31
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text meridiem
Attributes
ID : 32
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text button01
Attributes
ID : 38
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button02
Attributes
ID : 39
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button03
Attributes
ID : 40
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button04
Attributes
ID : 43
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button05
Attributes
ID : 44
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button06
Attributes
ID : 45
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Picture weather
Attributes
ID : 7
Scope : global
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(api==1)
{
page weather01
}
Dual-state Button left_bt_pic
Attributes
ID : 35
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text :
Max. Text Size : 0
Dual-state Button right_bt_pic
Attributes
ID : 36
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text :
Max. Text Size : 0
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer settings_timer
Attributes
ID : 34
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
page settings
Timer wakeup_timer
Attributes
ID : 37
Scope : local
Period (ms): 50
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=25
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer click_timer
Attributes
ID : 42
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \"home\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
wakeup_timer.en=1 // Set brightness to saved value (from HA)
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx&&api==1)
{
page buttonpage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2&&api==1)
{
page buttonpage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100&&api==1)
{
page buttonpage02
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100&&api==1)
{
page buttonpage03
}
}

View File

@@ -0,0 +1,317 @@
Page keyb_num
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page page_id.val
}else
{
sendme
}
Variable (int32) page_id
Attributes
ID : 17
Scope: local
Value: 0
Variable (string) key
Attributes
ID : 19
Scope : local
Text :
Max. Text Size: 10
Variable (string) domain
Attributes
ID : 20
Scope : local
Text : alarm
Max. Text Size: 10
Variable (string) aux
Attributes
ID : 21
Scope : local
Text :
Max. Text Size: 255
Variable (string) value
Attributes
ID : 22
Scope : local
Text :
Max. Text Size: 10
Text t0
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text pin
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text title
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Alarm
Max. Text Size : 30
Button b1
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 1
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b1.txt
Button bclose
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Release Event
page page_id.val
Button b2
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 2
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b2.txt
Button b3
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 3
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b3.txt
Button b4
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 4
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b4.txt
Button b5
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 5
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b5.txt
Button b6
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 6
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b6.txt
Button b7
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 7
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b7.txt
Button b8
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 8
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b8.txt
Button b9
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 9
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b9.txt
Button bclear
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: on press
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Release Event
pin.txt=""
Button b0
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 0
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b0.txt
Button benter
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press
State : unpressed
Text : î„«
Max. Text Size : 3
Events
Touch Release Event
aux.txt="{\"page\": \"keyb_num\", \"key\": \""+key.txt+"\", \"value\": \""+value.txt+"\", \"pin\": \""+pin.txt+"\", \"base_domain\": \""+domain.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints aux.txt,0
printh 00
printh FF FF FF
Button bview
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
if(pin.pw==1)
{
pin.pw=0
}else
{
pin.pw=1
}
Timer wakeup_timer
Attributes
ID : 23
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,668 @@
Page light
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis light_b_press,1
vis lightslider,1
vis light_value,1
// #### OFF Button #####
vis temp_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis temp_value,0
vis light_value_2,0
// #### OFF Slider #####
vis tempslider,0
vis colorwheel,0
// #### Hide color & temp buttons #####
vis temp_touch,0
vis temp_value_2,0
vis temp_button,0
vis color_touch,0
vis color_button,0
}
Variable (int32) rgb565
Attributes
ID : 22
Scope: local
Value: 0
Variable (string) va1
Attributes
ID : 23
Scope : local
Text : newtxt
Max. Text Size: 20
Variable (string) va2
Attributes
ID : 24
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (string) va3
Attributes
ID : 25
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (int32) currenttab
Attributes
ID : 26
Scope: local
Value: 0
Variable (string) lightsetting
Attributes
ID : 30
Scope : local
Text :
Max. Text Size: 255
Number ring
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Value : 0
Number field
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Value : 0
Text light_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text temp_value
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text light_value_2
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text temp_value_2
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text icon_state
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Picture light_button
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: disabled
Picture color_button
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: disabled
Picture temp_button
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: disabled
Picture light_b_press
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: disabled
Picture temp_b_press
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Picture color_b_pres
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: disabled
Picture colorwheel
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
// Circular Color Picker for Nextion (c) Max Zuidberg 2022
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
// Put this code in the touch press or release
// event of the pic component with the color wheel.
// Requires the two variables field.val and ring.val
//
// sya0 = x, sya1 = sya1
// Note the usage of the hidden sya0, sya1 variables
// within event code as local, temporary variable is fine.
sya0=tch0
sya1=tch1
//
// Convert absolute coordinates to coordinates relative to
// the color wheel center.
// sys0 = x_center, sys1 = y_center
sys0=colorwheel.w/2
sys0+=colorwheel.x
sys1=colorwheel.h/2
sys1+=colorwheel.y
sya0-=sys0
sya1-=sys1
//
// Determine ring
ring.val=0
// sys0 = r^2 = x^2 + y^2
sys0=sya0*sya0
sys1=sya1*sya1
sys0+=sys1
// repeat for all rings
if(sys0>=156)
{
ring.val++
}
if(sys0>=625)
{
ring.val++
}
if(sys0>=1406)
{
ring.val++
}
if(sys0>=2500)
{
ring.val++
}
if(sys0>=3906)
{
ring.val++
}
if(sys0>=5625)
{
ring.val++
}
if(sys0>=7656)
{
ring.val++
}
//
// Determine quadrant (0-3). Note: pixel y coords are inverted
// compared to mathematical y coords. But we want math. quadrants.
sya1*=-1
sys2=0
if(sya1<0)
{
sys2+=2
}
sys0=sya0*sya1
if(sys0<0)
{
sys2+=1
// In this case we also want to swap x and y otherwise the
// atan(abs(x/y)) (calculated below) gives values running
// "the wrong way" (cw instead of ccw).
sys1=sya1
sya1=sya0
sya0=sys1
}
//
field.val=sys2*6
//
// x,y sign is not required anymore
if(sya0<0)
{
sya0*=-1
}
if(sya1<0)
{
sya1*=-1
}
//
// Determine field in ring quadrant
// Factor 100000 chosen more or less arbitrarily.
// sys0 = 100000 * tan_a = 100000 * y / x
sys0=100000*sya1
sys0/=sya0
// repeat for all fields
if(sys0>=26794)
{
field.val++
}
if(sys0>=57735)
{
field.val++
}
if(sys0>=99999)
{
field.val++
}
if(sys0>=173205)
{
field.val++
}
if(sys0>=373205)
{
field.val++
}
covx r,va1.txt,0,0
covx g,va2.txt,0,0
covx b,va3.txt,0,0
va1.txt=""
va2.txt=""
va3.txt=""
Touch Release Event
// Adjust field.val "orientation" and offset to match the h value of the colors in the wheel
h=23-field.val// 0 <= field.val <= 23
// h is expected to be 0-6*256 (see hsv2rgb)
h*=6*256
h/=24// Number of fields
//
// s is expected to be 0-256 (see hsv2rgb)
s=ring.val*256
s/=8// Number of rings
// no "value" selectable; fix it to the maximum (matching the colors in the wheels shown.
v=255
click hsv2rgb,0
click rgb888to565,0
//colPreview.bco=rgb565.val
covx r,va1.txt,0,0
covx g,va2.txt,0,0
covx b,va3.txt,0,0
lightsetting.txt="{\"page\": \"light\", \"component\": \"rgb_color\", \"value\": ["+va1.txt+", "+va2.txt+", "+va3.txt+"]}"
printh 92
prints "nspanelevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
va1.txt=""
va2.txt=""
va3.txt=""
Slider lightslider
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx lightslider.val,va1.txt,0,0
light_value.txt=va1.txt+"%"
light_value_2.txt=va1.txt+"%"
lightsetting.txt="{\"page\": \"light\", \"key\": \"brightness_pct\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
Slider tempslider
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 500
Lower range limit: 153
Events
Touch Release Event
covx tempslider.val,va1.txt,0,0
temp_value.txt=va1.txt
temp_value_2.txt=va1.txt
lightsetting.txt="{\"page\": \"light\", \"key\": \"color_temp\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
Button button_back
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot hsv2rgb
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
// https://de.wikipedia.org/wiki/HSV-Farbraum#Umrechnung_HSV_in_RGB
// The values range from 0..255 instead of 0..1
// h ranges from 0..(6*256)
if(s>=256)
{
s=255
}else if(s<0)
{
s=0
}
if(v>=256)
{
v=255
}else if(v<0)
{
v=0
}
f=h&0xff
p=256-s
p*=v
p=p>>8// / 256
q=s*f// 0-256*256 = 0-65536
q=65536-q
q*=v
q=q>>16
t=256-f
t*=s
t=65536-t
t*=v
t=t>>16
//
f=h>>8
if(f==1)
{
r=q
g=v
b=p
}else if(f==2)
{
r=p
g=v
b=t
}else if(f==3)
{
r=p
g=q
b=v
}else if(f==4)
{
r=t
g=p
b=v
}else if(f==5)
{
r=v
g=p
b=q
}else
{
r=v
g=t
b=p
}
Hotspot rgb888to565
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
r=r&0xff
g=g&0xff
b=b&0xff
sys1=r>>3
sys2=sys1<<6
sys1=g>>2
sys2+=sys1
sys2=sys2<<5
sys1=b>>3
sys2+=sys1
rgb565.val=sys2
Hotspot light_touch
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis light_b_press,1
vis lightslider,1
vis light_value,1
vis temp_value_2,1
// #### OFF Button #####
vis temp_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis temp_value,0
vis light_value_2,0
// #### OFF Slider #####
vis tempslider,0
vis colorwheel,0
Hotspot temp_touch
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis temp_b_press,1
vis tempslider,1
vis temp_value,1
vis light_value_2,1
// #### OFF Button #####
vis light_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis light_value,0
vis temp_value_2,0
// #### OFF Slider #####
vis lightslider,0
vis colorwheel,0
Hotspot color_touch
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis color_b_pres,1
vis colorwheel,1
vis light_value_2,1
// #### OFF Button #####
vis light_b_press,0
vis temp_b_press,0
// #### OFF Value #####
vis light_value,0
vis temp_value,0
vis temp_value_2,0
// #### OFF Slider #####
vis lightslider,0
vis tempslider,0
// #### OFF Color #####
Timer swipestore
Attributes
ID : 21
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 32
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 20
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,423 @@
Page media_player
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) lastclick
Attributes
ID : 18
Scope : local
Text :
Max. Text Size: 255
Variable (string) va0
Attributes
ID : 21
Scope : local
Text :
Max. Text Size: 10
Variable (int32) is_muted
Attributes
ID : 22
Scope: local
Value: 0
Variable (int32) prg_current
Attributes
ID : 24
Scope: local
Value: 0
Variable (int32) prg_total
Attributes
ID : 25
Scope: local
Value: 0
Text page_label
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Media Player
Max. Text Size : 100
Text icon_state
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î„—
Max. Text Size : 10
Text vol_text
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text bt_vol_down
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(vol_slider.val>0)
{
vol_slider.val--
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
}
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_vol_up
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(vol_slider.val<100)
{
vol_slider.val++
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
}
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_mute
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(is_muted.val==0)
{
va0.txt="true"
}else
{
va0.txt="false"
}
lastclick.txt="{\"page\": \"media_player\", \"key\": \"volume_mute\", \"value\": \""+va0.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text time_current
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text time_total
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text track
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 255
Text artist
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 150
Text bt_prev
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’­
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"key\": \"media_previous_track\"}"
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_previous_track\"}",0
printh 00
printh FF FF FF
Text bt_play_pause
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_play_pause\"}",0
printh 00
printh FF FF FF
Text bt_next
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’¬
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_next_track\"}",0
printh 00
printh FF FF FF
Text bt_on_off
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"toggle\"}",0
printh 00
printh FF FF FF
Progress Bar time_progress
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
Value : 0
Slider vol_slider
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
Button button_back
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer timer0
Attributes
ID : 20
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
lastclick.txt="{\"page\": \"media_player\", \"key\": \"volume_set\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer prg_timer
Attributes
ID : 23
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
if(prg_current.val<prg_total.val&&prg_total.val>0)
{
prg_current.val++
time_progress.val=100*prg_current.val/prg_total.val
covx prg_current.val,time_current.txt,0,0
}
// Progress - Total
sys0=prg_total.val/3600 //hours
sys2=prg_total.val%3600 //remainder
sys1=sys2/60 //minutes
sys2%=60 //seconds
time_total.txt=""
if(sys0>0)
{
covx sys0,time_total.txt,0,0
time_total.txt+=":"
if(sys1<10)
{
time_total.txt+="0"
}
}
covx sys1,va0.txt,0,0
time_total.txt+=va0.txt+":"
if(sys2<10)
{
time_total.txt+="0"
}
covx sys2,va0.txt,0,0
time_total.txt+=va0.txt
// Progress - Current
sys0=prg_current.val/3600 //hours
sys2=prg_current.val%3600 //remainder
sys1=sys2/60 //minutes
sys2%=60 //seconds
time_current.txt=""
if(sys0>0)
{
covx sys0,time_current.txt,0,0
time_current.txt+=":"
if(sys1<10)
{
time_current.txt+="0"
}
}
covx sys1,va0.txt,0,0
time_current.txt+=va0.txt+":"
if(sys2<10)
{
time_current.txt+="0"
}
covx sys2,va0.txt,0,0
time_current.txt+=va0.txt

View File

@@ -0,0 +1,183 @@
Page notification
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) lastclick
Attributes
ID : 5
Scope : local
Text :
Max. Text Size: 100
Text notifi_text01
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 512
Text notifi_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Button bt_accept
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î— 
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"notification\", \"component\": \"accept\", \"value\": \"release\"}"
printh 92
prints "nspanelevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Button bt_clear
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…™
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"notification\", \"component\": \"clear\", \"value\": \"release\"}"
printh 92
prints "nspanelevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer swipestore
Attributes
ID : 4
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 9
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 3
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,129 @@
Page qrcode
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
Text qrcode_label
Attributes
ID : 3
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
QR Code qrcode_value
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID: on press and release
Text :
Max. Text Size : 75
Button button_back
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 6
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,101 @@
Page screensaver
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : disabled
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
dim=brightness_sleep
Touch Release Event
page back_page_id
Text text
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 1000
Events
Touch Press Event
page back_page_id
Timer swipestore
Attributes
ID : 3
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
TouchCap wakeup
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
page back_page_id
TouchCap swipe
Attributes
ID : 2
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx&&api==1)
{
page buttonpage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2&&api==1)
{
page buttonpage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100&&api==1)
{
page buttonpage02
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100&&api==1)
{
page buttonpage03
}
}

View File

@@ -0,0 +1,321 @@
Page settings
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
vis lbl_sleep,0
vis bt_sleep,0
Text bright_text
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 80%
Max. Text Size : 4
Text dim_text
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 20%
Max. Text Size : 4
Text lbl_reboot
Attributes
ID : 5
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Reboot
Max. Text Size : 25
Events
Touch Press Event
tm_boot_page.en=1
Touch Release Event
tm_boot_page.en=0
Text lbl_sleep
Attributes
ID : 6
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Sleep mode
Max. Text Size : 25
Text lbl_bright
Attributes
ID : 7
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Bright
Max. Text Size : 25
Text lbl_dim
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Dim
Max. Text Size : 25
Text lbl_brightness
Attributes
ID : 16
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Brightness
Max. Text Size : 25
Slider brightslider
Attributes
ID : 1
Scope : global
Dragging : 0
Send Component ID: on press and release
Position : 80
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
if(tm_bright.en==0)
{
tm_bright.en=1
}
Slider dimslider
Attributes
ID : 2
Scope : global
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
if(tm_dim.en==0)
{
tm_dim.en=1
}
Button button_back
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Dual-state Button bt_reboot
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Dual-state Button bt_sleep
Attributes
ID : 10
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Hotspot bt_bright_down
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(brightslider.val>0)
{
brightslider.val--
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Hotspot bt_bright_up
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(brightslider.val<100)
{
brightslider.val++
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Hotspot bt_dim_down
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(dimslider.val>0)
{
dimslider.val--
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Hotspot bt_dim_up
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(dimslider.val<100)
{
dimslider.val++
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Timer wakeup_timer
Attributes
ID : 17
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer tm_bright
Attributes
ID : 18
Scope : local
Period (ms): 100
Enabled : no
Events
Timer Event
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
tm_bright.en=0
Timer tm_dim
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : no
Events
Timer Event
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
tm_dim.en=0
Timer tm_boot_page
Attributes
ID : 20
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
page boot

View File

@@ -0,0 +1,263 @@
Page weather01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather05
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather05
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather05
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○○●
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,21 @@
Program.s
//The following code is only run once when power on, and is generally used for global variable definition and power on initialization data
int sys0=0,sys1=0,sys2=0,swipex=0,swipey=0,swipex2=0,swipey2=0,swipec=0,swipec2=0,swipedx=100,swipedy=100 //At present, the definition of global variable only supports 4-byte signed integer (int), and other types of global quantity declaration are not supported. If you want to use string type, you can use variable control in the page to implement
int r=0,g=0,b=0
int h=0,s=0,v=0
int p=0,q=0,t=0,f=0
int back_page_id=0
int dimdelta=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40,brightness_sleep=0
int display_mode=2 // 1 = EU, 2 = US, 3 = US landscape, 4 = blank
int charset=2 // 1 = International (original), 2 = CJK
//bauds=115200//Configure baudrate
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port
if(display_mode==1)
{
lcd_dev fffb 0002 0000 0020// Fix touch offset for EU Version
}
page 8//Power on start page boot

View File

@@ -0,0 +1,418 @@
Page alarm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis bt_home,0
vis bt_away,0
vis bt_night,0
vis bt_vacat,0
vis bt_bypass,0
}
Variable (string) lastclick
Attributes
ID : 3
Scope : local
Text :
Max. Text Size: 255
Variable (string) code_format
Attributes
ID : 28
Scope : local
Text :
Max. Text Size: 15
Variable (string) entity
Attributes
ID : 29
Scope : local
Text :
Max. Text Size: 100
Variable (string) code_arm_req
Attributes
ID : 30
Scope : local
Text :
Max. Text Size: 1
Text page_label
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Alarm Control Panel
Max. Text Size : 100
Text icon_state
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’—
Max. Text Size : 10
Text bt_home_text
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Home
Max. Text Size : 22
Text bt_away_text
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Away
Max. Text Size : 22
Text bt_night_text
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Night
Max. Text Size : 22
Text bt_vacat_text
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Vacation
Max. Text Size : 22
Text bt_bypass_text
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Bypass
Max. Text Size : 22
Text bt_disarm_text
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Disarm
Max. Text Size : 22
Text bt_home_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_away_icon
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_night_icon
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : ï §
Max. Text Size : 3
Text bt_vacat_icon
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_bypass_icon
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_disarm_icon
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Picture bt_home_pic
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_away_pic
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_night_pic
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_vacat_pic
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_bypass_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_disarm_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: disabled
Button button_back
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot bt_home
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_home_pic.pic=44
bt_home_text.bco=65024
bt_home_text.pco=0
bt_home_icon.bco=65024
bt_home_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"home\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_home_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_away
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_away_pic.pic=44
bt_away_text.bco=65024
bt_away_text.pco=0
bt_away_icon.bco=65024
bt_away_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"away\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_away_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_night
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_night_pic.pic=44
bt_night_text.bco=65024
bt_night_text.pco=0
bt_night_icon.bco=65024
bt_night_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"night\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_night_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_vacat
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_vacat_pic.pic=44
bt_vacat_text.bco=65024
bt_vacat_text.pco=0
bt_vacat_icon.bco=65024
bt_vacat_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"vacation\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_vacat_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_bypass
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_bypass_pic.pic=44
bt_bypass_text.bco=65024
bt_bypass_text.pco=0
bt_bypass_icon.bco=65024
bt_bypass_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"bypass\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_bypass_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_disarm
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_disarm_pic.pic=44
bt_disarm_text.bco=65024
bt_disarm_text.pco=0
bt_disarm_icon.bco=65024
bt_disarm_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"disarm\", \"value\": \"click\", \"entity\": \""+entity.txt+"\", \"mui\": \""+bt_disarm_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer wakeup_timer
Attributes
ID : 32
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,197 @@
Page boot
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
dim=100
vis bt_reboot,0
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"
Page Exit Event
dim=0
Variable (int32) counter
Attributes
ID : 11
Scope: local
Value: 0
Variable (string) aux1
Attributes
ID : 12
Scope : local
Text :
Max. Text Size: 10
Text ip_addr
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Initializing...
Max. Text Size : 15
Text t0
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please wait...
Max. Text Size : 15
Text t1
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : The process can take several seconds!
Max. Text Size : 50
Text tft_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : TFT:
Max. Text Size : 4
Text esph_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ESPHome:
Max. Text Size : 8
Text bluep_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Blueprint:
Max. Text Size : 10
Text tft_version
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 4.2beta.2
Max. Text Size : 9
Text esph_version
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text bluep_version
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text baud_rate
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text framework
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Dual-state Button bt_reboot
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : Reboot
Max. Text Size : 6
Timer tm_esphome
Attributes
ID : 13
Scope : local
Period (ms): 30000
Enabled : yes
Events
Timer Event
counter.val++
if(counter.val>60)
{
rest
}
sendme
printh 91
prints "display_mode",0
printh 00
prints display_mode,0
printh FF FF FF
printh 91
prints "charset",0
printh 00
prints charset,0
printh FF FF FF
printh 92
prints "tft_version",0
printh 00
prints tft_version.txt,0
printh 00
printh FF FF FF
covx counter.val,aux1.txt,0,0
esph_version.txt="Retry #"+aux1.txt
sys0=counter.val%10
if(sys0==0)
{
baud=115200
}
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"

View File

@@ -0,0 +1,792 @@
Page buttonpage01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage01
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page home
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage02
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage03
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage04
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page home
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,867 @@
Page climate
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==1||embedded.val==1)
{
sendme
vis target_icon,0
vis target_high,0
vis target_low,0
vis current_temp,0
vis climateslider,0
vis slider_high,0
vis slider_low,0
vis button01,0
vis button02,0
vis button03,0
vis button04,0
vis button05,0
vis button06,0
vis button07,0
}else
{
page home
}
Page Exit Event
covx embedded.val,va2.txt,0,0
if(timer0.en==1)
{
timer0.en=0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer1.en==1)
{
timer1.en=0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer2.en==1)
{
timer2.en=0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
Variable (string) va1
Attributes
ID : 24
Scope : local
Text :
Max. Text Size: 10
Variable (string) climatesetting
Attributes
ID : 25
Scope : local
Text :
Max. Text Size: 255
Variable (string) lastclick
Attributes
ID : 26
Scope : local
Text :
Max. Text Size: 255
Variable (int32) temp_offset
Attributes
ID : 28
Scope: local
Value: 0
Variable (int32) temp_step
Attributes
ID : 29
Scope: local
Value: 1
Variable (int32) temp_number0
Attributes
ID : 33
Scope: local
Value: 0
Variable (int32) va0
Attributes
ID : 34
Scope: local
Value: 0
Variable (int32) embedded
Attributes
ID : 35
Scope: global
Value: 0
Variable (string) va2
Attributes
ID : 36
Scope : local
Text :
Max. Text Size: 10
Variable (string) click_comp
Attributes
ID : 38
Scope : local
Text :
Max. Text Size: 8
Variable (int32) active_slider
Attributes
ID : 42
Scope: local
Value: 1
Variable (int32) is_temp_range
Attributes
ID : 44
Scope: local
Value: 0
Variable (int32) temp_number1
Attributes
ID : 48
Scope: local
Value: 0
Variable (int32) temp_number2
Attributes
ID : 49
Scope: local
Value: 0
Text current_temp
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text page_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text target_icon
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01_icon
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value02_icon
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value03_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text button01
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button02
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button03
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button04
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button05
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button06
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button07
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button08
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button09
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text target_high
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Release Event
active_slider.val=is_temp_range.val
Text target_low
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Release Event
active_slider.val=2
Slider slider_high
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 200
Upper range limit: 400
Lower range limit: 0
Events
Touch Release Event
active_slider.val=1
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer1.en=1
Slider slider_low
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 200
Upper range limit: 400
Lower range limit: 0
Events
Touch Release Event
active_slider.val=2
temp_number2.val=slider_high.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer2.en=1
Slider climateslider
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 200
Upper range limit: 400
Lower range limit: 0
Events
Touch Release Event
active_slider.val=0
temp_number0.val=slider_high.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer0.en=1
Button button_back
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot decrease_temp
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val>0)
{
climateslider.val--
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val>0)
{
slider_high.val--
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val>0)
{
slider_low.val--
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Hotspot increase_temp
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val<climateslider.maxval)
{
climateslider.val++
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val<slider_high.maxval)
{
slider_high.val++
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val<slider_low.maxval)
{
slider_low.val++
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer timer0
Attributes
ID : 27
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
covx embedded.val,va2.txt,0,0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer click_timer
Attributes
ID : 39
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \"climate\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 40
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer timer1
Attributes
ID : 46
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer1.en=0
covx embedded.val,va2.txt,0,0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer timer2
Attributes
ID : 47
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer2.en=0
covx embedded.val,va2.txt,0,0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,151 @@
Page confirm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (int32) page_id
Attributes
ID : 3
Scope: global
Value: 0
Variable (string) aux
Attributes
ID : 5
Scope : local
Text :
Max. Text Size: 255
Variable (string) page_name
Attributes
ID : 9
Scope : global
Text :
Max. Text Size: 12
Variable (string) component
Attributes
ID : 10
Scope : global
Text :
Max. Text Size: 10
Text t0
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text title
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 100
Text body
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 255
Button bclose
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Button bt_accept
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î— 
Max. Text Size : 3
Events
Touch Release Event
aux.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+component.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints aux.txt,0
printh 00
printh FF FF FF
page page_id.val
Button bt_clear
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…™
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Timer wakeup_timer
Attributes
ID : 11
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,202 @@
Page cover
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) va1
Attributes
ID : 7
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (string) coversetting
Attributes
ID : 11
Scope : local
Text :
Max. Text Size: 255
Text battery_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text cover_value
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text icon_state
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text battery_icon
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Slider coverslider
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx coverslider.val,va1.txt,0,0
cover_value.txt=va1.txt+"%"
coversetting.txt="{\"page\": \"cover\", \"key\": \"position\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints coversetting.txt,0
printh 00
printh FF FF FF
Button cover_open
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"open_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_close
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : ï„›
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"close_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_stop
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"stop_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button button_back
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 13
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,376 @@
Page entitypage01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity01_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
page entitypage03
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
page entitypage04
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity02_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity03_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
page entitypage01
}
}

View File

@@ -0,0 +1,376 @@
Page entitypage04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text value01_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value05_label
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value04_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value02_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value03_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text entity04_label
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text value06_label
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value07_label
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value08_label
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text value01_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value02_pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value03_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value04_pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value05_pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value06_pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value07_pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value08_pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text value01
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value02
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value03
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value04
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value05
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value06
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value07
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text value08
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 30
Text page_index
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●
Max. Text Size : 12
Button button_back
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 30
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page entitypage03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page entitypage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
page entitypage01
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,377 @@
Page fan
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) fansetting
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 255
Variable (string) va0
Attributes
ID : 8
Scope : local
Text :
Max. Text Size: 10
Text fan_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text icon_state
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Slider fanslider
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 4
Lower range limit: 0
Events
Touch Release Event
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
timer0.en=1
Button button_up
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : ï‘­
Max. Text Size : 3
Events
Touch Press Event
if(fanslider.val<fanslider.maxval)
{
fanslider.val++
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
}
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_on
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
fanslider.val=fanslider.maxval/2
sys0=fanslider.maxval*5
sys0%=10
if(sys0>=5)
{
fanslider.val++
}
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_down
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
if(fanslider.val>fanslider.minval)
{
fanslider.val--
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
}
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=1
Button button_off
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
fanslider.val=fanslider.minval
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
fansetting.txt="{\"page\": \"fan\", \"key\": \"stop\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints fansetting.txt,0
printh 00
printh FF FF FF
if(fanslider.val>fanslider.minval)
{
button_off.pco=59164
button_down.pco=59164
}else
{
button_off.pco=10597
button_down.pco=10597
}
if(fanslider.val<fanslider.maxval)
{
button_up.pco=59164
}else
{
button_up.pco=10597
}
Touch Release Event
timer0.en=0
Button button_back
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer swipestore
Attributes
ID : 5
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer timer0
Attributes
ID : 13
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
sys0=100*fanslider.val/fanslider.maxval
covx sys0,va0.txt,0,0
fan_value.txt=va0.txt+"%"
fansetting.txt="{\"page\": \"fan\", \"key\": \"percentage\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints fansetting.txt,0
printh 00
printh FF FF FF
Timer wakeup_timer
Attributes
ID : 15
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 4
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,723 @@
Page home
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
back_page_id=0
vis bt_notific,is_notification
vis bt_qrcode,is_qrcode
vis bt_entities,is_entities
if(display_mode==3)
{
vis left_bt_text,0
vis right_bt_text,0
}
Variable (string) lastclick
Attributes
ID : 33
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 41
Scope : local
Text :
Max. Text Size: 8
Text time
Attributes
ID : 3
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text current_temp
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 8
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"home\", \"component\": \"climate\", \"event\": \"click\"}",0
printh 00
printh FF FF FF
Text outdoor_temp
Attributes
ID : 5
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 8
Text date
Attributes
ID : 6
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text value01_state
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text left_bt_text
Attributes
ID : 9
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text right_bt_text
Attributes
ID : 10
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text icon_top_01
Attributes
ID : 11
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_02
Attributes
ID : 12
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_03
Attributes
ID : 13
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_04
Attributes
ID : 14
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_05
Attributes
ID : 15
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_06
Attributes
ID : 16
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_07
Attributes
ID : 17
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_08
Attributes
ID : 18
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_09
Attributes
ID : 19
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text icon_top_10
Attributes
ID : 20
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value01_icon
Attributes
ID : 21
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value03_state
Attributes
ID : 22
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 23
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value02_icon
Attributes
ID : 24
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Text value02_state
Attributes
ID : 25
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text wifi_icon
Attributes
ID : 26
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text indoortempicon
Attributes
ID : 27
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"home\", \"component\": \"climate\", \"event\": \"click\"}",0
printh 00
printh FF FF FF
Text bt_notific
Attributes
ID : 28
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
if(api==1)
{
page notification
}
Text bt_qrcode
Attributes
ID : 29
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
page qrcode
Text bt_entities
Attributes
ID : 30
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Release Event
if(api==1)
{
page entitypage01
}
Text button07
Attributes
ID : 31
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text meridiem
Attributes
ID : 32
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Events
Touch Press Event
settings_timer.en=1
Touch Release Event
settings_timer.en=0
Text button01
Attributes
ID : 38
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button02
Attributes
ID : 39
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button03
Attributes
ID : 40
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button04
Attributes
ID : 43
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button05
Attributes
ID : 44
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button06
Attributes
ID : 45
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 3
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"home\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Picture weather
Attributes
ID : 7
Scope : global
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(api==1)
{
page weather01
}
Dual-state Button left_bt_pic
Attributes
ID : 35
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text :
Max. Text Size : 0
Dual-state Button right_bt_pic
Attributes
ID : 36
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text :
Max. Text Size : 0
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer settings_timer
Attributes
ID : 34
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
page settings
Timer wakeup_timer
Attributes
ID : 37
Scope : local
Period (ms): 50
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=25
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer click_timer
Attributes
ID : 42
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \"home\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
wakeup_timer.en=1 // Set brightness to saved value (from HA)
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx&&api==1)
{
page buttonpage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2&&api==1)
{
page buttonpage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100&&api==1)
{
page buttonpage02
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100&&api==1)
{
page buttonpage03
}
}

View File

@@ -0,0 +1,311 @@
Page keyb_num
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page page_id.val
}else
{
sendme
}
Variable (int32) page_id
Attributes
ID : 17
Scope: local
Value: 0
Variable (string) key
Attributes
ID : 19
Scope : local
Text :
Max. Text Size: 10
Variable (string) domain
Attributes
ID : 20
Scope : local
Text : alarm
Max. Text Size: 10
Variable (string) aux
Attributes
ID : 21
Scope : local
Text :
Max. Text Size: 255
Variable (string) value
Attributes
ID : 22
Scope : local
Text :
Max. Text Size: 10
Text t0
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text pin
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 60
Text title
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Alarm
Max. Text Size : 30
Button b1
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 1
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b1.txt
Button bclose
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Release Event
page page_id.val
Button b2
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 2
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b2.txt
Button b3
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press
State : unpressed
Text : 3
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b3.txt
Button b4
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 4
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b4.txt
Button b5
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 5
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b5.txt
Button b6
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 6
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b6.txt
Button b7
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 7
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b7.txt
Button b8
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 8
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b8.txt
Button b9
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press
State : unpressed
Text : 9
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b9.txt
Button bclear
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Release Event
pin.txt=""
Button b0
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 0
Max. Text Size : 1
Events
Touch Release Event
pin.txt+=b0.txt
Button benter
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î„«
Max. Text Size : 3
Events
Touch Release Event
aux.txt="{\"page\": \"keyb_num\", \"key\": \""+key.txt+"\", \"value\": \""+value.txt+"\", \"pin\": \""+pin.txt+"\", \"base_domain\": \""+domain.txt+"\"}"
Button bview
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
if(pin.pw==1)
{
pin.pw=0
}else
{
pin.pw=1
}
Timer wakeup_timer
Attributes
ID : 23
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,668 @@
Page light
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis light_b_press,1
vis lightslider,1
vis light_value,1
// #### OFF Button #####
vis temp_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis temp_value,0
vis light_value_2,0
// #### OFF Slider #####
vis tempslider,0
vis colorwheel,0
// #### Hide color & temp buttons #####
vis temp_touch,0
vis temp_value_2,0
vis temp_button,0
vis color_touch,0
vis color_button,0
}
Variable (int32) rgb565
Attributes
ID : 22
Scope: local
Value: 0
Variable (string) va1
Attributes
ID : 23
Scope : local
Text : newtxt
Max. Text Size: 20
Variable (string) va2
Attributes
ID : 24
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (string) va3
Attributes
ID : 25
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (int32) currenttab
Attributes
ID : 26
Scope: local
Value: 0
Variable (string) lightsetting
Attributes
ID : 30
Scope : local
Text :
Max. Text Size: 255
Number ring
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Value : 0
Number field
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Value : 0
Text light_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text temp_value
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text light_value_2
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text temp_value_2
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text icon_state
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Picture light_button
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: disabled
Picture color_button
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: disabled
Picture temp_button
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: disabled
Picture light_b_press
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: disabled
Picture temp_b_press
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Picture color_b_pres
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: disabled
Picture colorwheel
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
// Circular Color Picker for Nextion (c) Max Zuidberg 2022
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
// Put this code in the touch press or release
// event of the pic component with the color wheel.
// Requires the two variables field.val and ring.val
//
// sya0 = x, sya1 = sya1
// Note the usage of the hidden sya0, sya1 variables
// within event code as local, temporary variable is fine.
sya0=tch0
sya1=tch1
//
// Convert absolute coordinates to coordinates relative to
// the color wheel center.
// sys0 = x_center, sys1 = y_center
sys0=colorwheel.w/2
sys0+=colorwheel.x
sys1=colorwheel.h/2
sys1+=colorwheel.y
sya0-=sys0
sya1-=sys1
//
// Determine ring
ring.val=0
// sys0 = r^2 = x^2 + y^2
sys0=sya0*sya0
sys1=sya1*sya1
sys0+=sys1
// repeat for all rings
if(sys0>=156)
{
ring.val++
}
if(sys0>=625)
{
ring.val++
}
if(sys0>=1406)
{
ring.val++
}
if(sys0>=2500)
{
ring.val++
}
if(sys0>=3906)
{
ring.val++
}
if(sys0>=5625)
{
ring.val++
}
if(sys0>=7656)
{
ring.val++
}
//
// Determine quadrant (0-3). Note: pixel y coords are inverted
// compared to mathematical y coords. But we want math. quadrants.
sya1*=-1
sys2=0
if(sya1<0)
{
sys2+=2
}
sys0=sya0*sya1
if(sys0<0)
{
sys2+=1
// In this case we also want to swap x and y otherwise the
// atan(abs(x/y)) (calculated below) gives values running
// "the wrong way" (cw instead of ccw).
sys1=sya1
sya1=sya0
sya0=sys1
}
//
field.val=sys2*6
//
// x,y sign is not required anymore
if(sya0<0)
{
sya0*=-1
}
if(sya1<0)
{
sya1*=-1
}
//
// Determine field in ring quadrant
// Factor 100000 chosen more or less arbitrarily.
// sys0 = 100000 * tan_a = 100000 * y / x
sys0=100000*sya1
sys0/=sya0
// repeat for all fields
if(sys0>=26794)
{
field.val++
}
if(sys0>=57735)
{
field.val++
}
if(sys0>=99999)
{
field.val++
}
if(sys0>=173205)
{
field.val++
}
if(sys0>=373205)
{
field.val++
}
covx r,va1.txt,0,0
covx g,va2.txt,0,0
covx b,va3.txt,0,0
va1.txt=""
va2.txt=""
va3.txt=""
Touch Release Event
// Adjust field.val "orientation" and offset to match the h value of the colors in the wheel
h=23-field.val// 0 <= field.val <= 23
// h is expected to be 0-6*256 (see hsv2rgb)
h*=6*256
h/=24// Number of fields
//
// s is expected to be 0-256 (see hsv2rgb)
s=ring.val*256
s/=8// Number of rings
// no "value" selectable; fix it to the maximum (matching the colors in the wheels shown.
v=255
click hsv2rgb,0
click rgb888to565,0
//colPreview.bco=rgb565.val
covx r,va1.txt,0,0
covx g,va2.txt,0,0
covx b,va3.txt,0,0
lightsetting.txt="{\"page\": \"light\", \"component\": \"rgb_color\", \"value\": ["+va1.txt+", "+va2.txt+", "+va3.txt+"]}"
printh 92
prints "nspanelevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
va1.txt=""
va2.txt=""
va3.txt=""
Slider lightslider
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx lightslider.val,va1.txt,0,0
light_value.txt=va1.txt+"%"
light_value_2.txt=va1.txt+"%"
lightsetting.txt="{\"page\": \"light\", \"key\": \"brightness_pct\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
Slider tempslider
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 500
Lower range limit: 153
Events
Touch Release Event
covx tempslider.val,va1.txt,0,0
temp_value.txt=va1.txt
temp_value_2.txt=va1.txt
lightsetting.txt="{\"page\": \"light\", \"key\": \"color_temp\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lightsetting.txt,0
printh 00
printh FF FF FF
Button button_back
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot hsv2rgb
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
// https://de.wikipedia.org/wiki/HSV-Farbraum#Umrechnung_HSV_in_RGB
// The values range from 0..255 instead of 0..1
// h ranges from 0..(6*256)
if(s>=256)
{
s=255
}else if(s<0)
{
s=0
}
if(v>=256)
{
v=255
}else if(v<0)
{
v=0
}
f=h&0xff
p=256-s
p*=v
p=p>>8// / 256
q=s*f// 0-256*256 = 0-65536
q=65536-q
q*=v
q=q>>16
t=256-f
t*=s
t=65536-t
t*=v
t=t>>16
//
f=h>>8
if(f==1)
{
r=q
g=v
b=p
}else if(f==2)
{
r=p
g=v
b=t
}else if(f==3)
{
r=p
g=q
b=v
}else if(f==4)
{
r=t
g=p
b=v
}else if(f==5)
{
r=v
g=p
b=q
}else
{
r=v
g=t
b=p
}
Hotspot rgb888to565
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
r=r&0xff
g=g&0xff
b=b&0xff
sys1=r>>3
sys2=sys1<<6
sys1=g>>2
sys2+=sys1
sys2=sys2<<5
sys1=b>>3
sys2+=sys1
rgb565.val=sys2
Hotspot light_touch
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis light_b_press,1
vis lightslider,1
vis light_value,1
vis temp_value_2,1
// #### OFF Button #####
vis temp_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis temp_value,0
vis light_value_2,0
// #### OFF Slider #####
vis tempslider,0
vis colorwheel,0
Hotspot temp_touch
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis temp_b_press,1
vis tempslider,1
vis temp_value,1
vis light_value_2,1
// #### OFF Button #####
vis light_b_press,0
vis color_b_pres,0
// #### OFF Value #####
vis light_value,0
vis temp_value_2,0
// #### OFF Slider #####
vis lightslider,0
vis colorwheel,0
Hotspot color_touch
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
vis color_b_pres,1
vis colorwheel,1
vis light_value_2,1
// #### OFF Button #####
vis light_b_press,0
vis temp_b_press,0
// #### OFF Value #####
vis light_value,0
vis temp_value,0
vis temp_value_2,0
// #### OFF Slider #####
vis lightslider,0
vis tempslider,0
// #### OFF Color #####
Timer swipestore
Attributes
ID : 21
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 32
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 20
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,422 @@
Page media_player
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) lastclick
Attributes
ID : 18
Scope : local
Text :
Max. Text Size: 255
Variable (string) va0
Attributes
ID : 21
Scope : local
Text :
Max. Text Size: 10
Variable (int32) is_muted
Attributes
ID : 22
Scope: local
Value: 0
Variable (int32) prg_current
Attributes
ID : 24
Scope: local
Value: 0
Variable (int32) prg_total
Attributes
ID : 25
Scope: local
Value: 0
Text page_label
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Media Player
Max. Text Size : 100
Text icon_state
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î„—
Max. Text Size : 10
Text vol_text
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 5
Text bt_vol_down
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(vol_slider.val>0)
{
vol_slider.val--
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
}
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_vol_up
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(vol_slider.val<100)
{
vol_slider.val++
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
}
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_mute
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
if(is_muted.val==0)
{
va0.txt="true"
}else
{
va0.txt="false"
}
lastclick.txt="{\"page\": \"media_player\", \"key\": \"volume_mute\", \"value\": \""+va0.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text time_current
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text time_total
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text track
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 255
Text artist
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 150
Text bt_prev
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’­
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_previous_track\"}",0
printh 00
printh FF FF FF
Text bt_play_pause
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_play_pause\"}",0
printh 00
printh FF FF FF
Text bt_next
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’¬
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"media_next_track\"}",0
printh 00
printh FF FF FF
Text bt_on_off
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"media_player\", \"key\": \"toggle\"}",0
printh 00
printh FF FF FF
Progress Bar time_progress
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
Value : 0
Slider vol_slider
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
timer0.en=1
Button button_back
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer timer0
Attributes
ID : 20
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
covx vol_slider.val,va0.txt,0,0
vol_text.txt=va0.txt+"%"
lastclick.txt="{\"page\": \"media_player\", \"key\": \"volume_set\", \"value\": "+va0.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer prg_timer
Attributes
ID : 23
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
if(prg_current.val<prg_total.val&&prg_total.val>0)
{
prg_current.val++
time_progress.val=100*prg_current.val/prg_total.val
covx prg_current.val,time_current.txt,0,0
}
// Progress - Total
sys0=prg_total.val/3600 //hours
sys2=prg_total.val%3600 //remainder
sys1=sys2/60 //minutes
sys2%=60 //seconds
time_total.txt=""
if(sys0>0)
{
covx sys0,time_total.txt,0,0
time_total.txt+=":"
if(sys1<10)
{
time_total.txt+="0"
}
}
covx sys1,va0.txt,0,0
time_total.txt+=va0.txt+":"
if(sys2<10)
{
time_total.txt+="0"
}
covx sys2,va0.txt,0,0
time_total.txt+=va0.txt
// Progress - Current
sys0=prg_current.val/3600 //hours
sys2=prg_current.val%3600 //remainder
sys1=sys2/60 //minutes
sys2%=60 //seconds
time_current.txt=""
if(sys0>0)
{
covx sys0,time_current.txt,0,0
time_current.txt+=":"
if(sys1<10)
{
time_current.txt+="0"
}
}
covx sys1,va0.txt,0,0
time_current.txt+=va0.txt+":"
if(sys2<10)
{
time_current.txt+="0"
}
covx sys2,va0.txt,0,0
time_current.txt+=va0.txt

View File

@@ -0,0 +1,183 @@
Page notification
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) lastclick
Attributes
ID : 5
Scope : local
Text :
Max. Text Size: 100
Text notifi_text01
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 512
Text notifi_label
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Button bt_accept
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î— 
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"notification\", \"component\": \"accept\", \"value\": \"release\"}"
printh 92
prints "nspanelevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Button bt_clear
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…™
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"notification\", \"component\": \"clear\", \"value\": \"release\"}"
printh 92
prints "nspanelevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer swipestore
Attributes
ID : 4
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 9
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 3
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,129 @@
Page qrcode
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
Text qrcode_label
Attributes
ID : 3
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
QR Code qrcode_value
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID: on press and release
Text :
Max. Text Size : 75
Button button_back
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 6
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,101 @@
Page screensaver
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : disabled
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
dim=brightness_sleep
Touch Release Event
page back_page_id
Text text
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 1000
Events
Touch Press Event
page back_page_id
Timer swipestore
Attributes
ID : 3
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
TouchCap wakeup
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
page back_page_id
TouchCap swipe
Attributes
ID : 2
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx&&api==1)
{
page buttonpage04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2&&api==1)
{
page buttonpage01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100&&api==1)
{
page buttonpage02
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100&&api==1)
{
page buttonpage03
}
}

View File

@@ -0,0 +1,417 @@
Page settings
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
vis lbl_sleep,0
vis bt_sleep,0
Text bright_text
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 80%
Max. Text Size : 4
Text dim_text
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 20%
Max. Text Size : 4
Text lbl_reboot
Attributes
ID : 5
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Reboot
Max. Text Size : 25
Events
Touch Press Event
tm_boot_page.en=1
Touch Release Event
tm_boot_page.en=0
Text lbl_sleep
Attributes
ID : 6
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Sleep mode
Max. Text Size : 25
Text lbl_bright
Attributes
ID : 7
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Bright
Max. Text Size : 25
Text lbl_dim
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Dim
Max. Text Size : 25
Text lbl_brightness
Attributes
ID : 16
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Brightness
Max. Text Size : 25
Text t0
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î–§
Max. Text Size : 10
Events
Touch Release Event
if(brightslider.val<100)
{
brightslider.val++
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Text t1
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î–§
Max. Text Size : 10
Events
Touch Release Event
if(dimslider.val<100)
{
dimslider.val++
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Text t2
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î–§
Max. Text Size : 10
Events
Touch Release Event
if(dimslider.val>0)
{
dimslider.val--
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Text t3
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î–§
Max. Text Size : 10
Events
Touch Release Event
if(brightslider.val>0)
{
brightslider.val--
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Slider brightslider
Attributes
ID : 1
Scope : global
Dragging : 0
Send Component ID: on press and release
Position : 80
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
if(tm_bright.en==0)
{
tm_bright.en=1
}
Slider dimslider
Attributes
ID : 2
Scope : global
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
if(tm_dim.en==0)
{
tm_dim.en=1
}
Button button_back
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Dual-state Button bt_reboot
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Dual-state Button bt_sleep
Attributes
ID : 10
Scope : global
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Hotspot bt_bright_down
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(brightslider.val>0)
{
brightslider.val--
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Hotspot bt_bright_up
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(brightslider.val<100)
{
brightslider.val++
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
}
Hotspot bt_dim_down
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(dimslider.val>0)
{
dimslider.val--
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Hotspot bt_dim_up
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Release Event
if(dimslider.val<100)
{
dimslider.val++
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
}
Timer wakeup_timer
Attributes
ID : 21
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer tm_bright
Attributes
ID : 22
Scope : local
Period (ms): 100
Enabled : no
Events
Timer Event
covx brightslider.val,bright_text.txt,0,0
bright_text.txt+="%"
printh 91
prints "brightslider",0
printh 00
prints brightslider.val,0
printh FF FF FF
tm_bright.en=0
Timer tm_dim
Attributes
ID : 23
Scope : local
Period (ms): 100
Enabled : no
Events
Timer Event
covx dimslider.val,dim_text.txt,0,0
dim_text.txt+="%"
printh 91
prints "dimslider",0
printh 00
prints dimslider.val,0
printh FF FF FF
tm_dim.en=0
Timer tm_boot_page
Attributes
ID : 24
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
page boot

View File

@@ -0,0 +1,263 @@
Page weather01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather05
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●○
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather05
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,263 @@
Page weather05
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Text day
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 20
Text date
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text temperature
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value05
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value04
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value02
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value03
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 15
Text value01_icon
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03_icon
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value05_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_index
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○○●
Max. Text Size : 15
Picture weather_icon
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
Button button_back
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer wakeup_timer
Attributes
ID : 19
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page weather04
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page weather01
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,21 @@
Program.s
//The following code is only run once when power on, and is generally used for global variable definition and power on initialization data
int sys0=0,sys1=0,sys2=0,swipex=0,swipey=0,swipex2=0,swipey2=0,swipec=0,swipec2=0,swipedx=100,swipedy=100 //At present, the definition of global variable only supports 4-byte signed integer (int), and other types of global quantity declaration are not supported. If you want to use string type, you can use variable control in the page to implement
int r=0,g=0,b=0
int h=0,s=0,v=0
int p=0,q=0,t=0,f=0
int back_page_id=0
int dimdelta=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40,brightness_sleep=0
int display_mode=3 // 1 = EU, 2 = US, 3 = US landscape, 4 = blank
int charset=2 // 1 = International (original), 2 = CJK
//bauds=115200//Configure baudrate
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port
if(display_mode==1)
{
lcd_dev fffb 0002 0000 0020// Fix touch offset for EU Version
}
page 8//Power on start page boot

View File

@@ -0,0 +1,411 @@
Page alarm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis bt_home,0
vis bt_away,0
vis bt_night,0
vis bt_vacat,0
vis bt_bypass,0
}
Variable (string) lastclick
Attributes
ID : 3
Scope : local
Text :
Max. Text Size: 255
Variable (string) code_format
Attributes
ID : 28
Scope : local
Text :
Max. Text Size: 15
Variable (string) code_arm_req
Attributes
ID : 29
Scope : local
Text :
Max. Text Size: 1
Text page_label
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Alarm Control Panel
Max. Text Size : 100
Text icon_state
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : î’—
Max. Text Size : 10
Text bt_home_text
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Home
Max. Text Size : 22
Text bt_away_text
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Away
Max. Text Size : 22
Text bt_night_text
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Night
Max. Text Size : 22
Text bt_vacat_text
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Vacation
Max. Text Size : 22
Text bt_bypass_text
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Bypass
Max. Text Size : 22
Text bt_disarm_text
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Disarm
Max. Text Size : 22
Text bt_home_icon
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_away_icon
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_night_icon
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : ï §
Max. Text Size : 3
Text bt_vacat_icon
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_bypass_icon
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Text bt_disarm_icon
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 3
Picture bt_home_pic
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_away_pic
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_night_pic
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_vacat_pic
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_bypass_pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Picture bt_disarm_pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID: disabled
Button button_back
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot bt_home
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_home_pic.pic=44
bt_home_text.bco=65024
bt_home_text.pco=0
bt_home_icon.bco=65024
bt_home_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"home\", \"value\": \"click\", \"mui\": \""+bt_home_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_away
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_away_pic.pic=44
bt_away_text.bco=65024
bt_away_text.pco=0
bt_away_icon.bco=65024
bt_away_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"away\", \"value\": \"click\", \"mui\": \""+bt_away_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_night
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_night_pic.pic=44
bt_night_text.bco=65024
bt_night_text.pco=0
bt_night_icon.bco=65024
bt_night_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"night\", \"value\": \"click\", \"mui\": \""+bt_night_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_vacat
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_vacat_pic.pic=44
bt_vacat_text.bco=65024
bt_vacat_text.pco=0
bt_vacat_icon.bco=65024
bt_vacat_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"vacation\", \"value\": \"click\", \"mui\": \""+bt_vacat_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_bypass
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_bypass_pic.pic=44
bt_bypass_text.bco=65024
bt_bypass_text.pco=0
bt_bypass_icon.bco=65024
bt_bypass_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"bypass\", \"value\": \"click\", \"mui\": \""+bt_bypass_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot bt_disarm
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
bt_disarm_pic.pic=44
bt_disarm_text.bco=65024
bt_disarm_text.pco=0
bt_disarm_icon.bco=65024
bt_disarm_icon.pco=0
Touch Release Event
lastclick.txt="{\"page\": \"alarm\", \"key\": \"disarm\", \"value\": \"click\", \"mui\": \""+bt_disarm_text.txt+"\", \"code_format\": \""+code_format.txt+"\", \"code_arm_req\": \""+code_arm_req.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Timer wakeup_timer
Attributes
ID : 31
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,200 @@
Page boot
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
sendme
dim=100
vis bt_reboot,0
sendme
dim=100
vis bt_reboot,0
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"
Page Exit Event
dim=0
Variable (int32) counter
Attributes
ID : 11
Scope: local
Value: 0
Variable (string) aux1
Attributes
ID : 12
Scope : local
Text :
Max. Text Size: 10
Text ip_addr
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Initializing...
Max. Text Size : 15
Text t0
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please wait...
Max. Text Size : 15
Text t1
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : The process can take several seconds!
Max. Text Size : 50
Text tft_label
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : TFT:
Max. Text Size : 4
Text esph_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ESPHome:
Max. Text Size : 8
Text bluep_label
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Blueprint:
Max. Text Size : 10
Text tft_version
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 4.2beta.2
Max. Text Size : 9
Text esph_version
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text bluep_version
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 9
Text baud_rate
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text framework
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Dual-state Button bt_reboot
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : Reboot
Max. Text Size : 6
Timer tm_esphome
Attributes
ID : 13
Scope : local
Period (ms): 30000
Enabled : yes
Events
Timer Event
counter.val++
if(counter.val>60)
{
rest
}
sendme
printh 91
prints "display_mode",0
printh 00
prints display_mode,0
printh FF FF FF
printh 91
prints "charset",0
printh 00
prints charset,0
printh FF FF FF
printh 92
prints "tft_version",0
printh 00
prints tft_version.txt,0
printh 00
printh FF FF FF
covx counter.val,aux1.txt,0,0
esph_version.txt="Retry #"+aux1.txt
sys0=counter.val%10
if(sys0==0)
{
baud=115200
}
covx baud,baud_rate.txt,0,0
baud_rate.txt+=" bps"

View File

@@ -0,0 +1,792 @@
Page buttonpage01
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage01
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ●○○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page home
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage02
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage02
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage02
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○●○○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage01
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage03
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage03
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage03
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○●○
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage02
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page buttonpage04
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,792 @@
Page buttonpage04
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
vis 255,0
vis button_back,1
vis page_index,1
}
Variable (string) lastclick
Attributes
ID : 4
Scope : local
Text :
Max. Text Size: 100
Variable (string) click_comp
Attributes
ID : 7
Scope : local
Text :
Max. Text Size: 8
Variable (string) page_name
Attributes
ID : 9
Scope : local
Text : buttonpage04
Max. Text Size: 12
Variable (int32) confirm
Attributes
ID : 11
Scope: local
Value: 0
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text page_index
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : ○○○●
Max. Text Size : 12
Text button01pic
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button02pic
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button03pic
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button04pic
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button05pic
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button06pic
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button07pic
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button08pic
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 0
Text button01text
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button02text
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button03text
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button04text
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button05text
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button06text
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button07text
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button08text
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 22
Text button01icon
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button02icon
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button03icon
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button04icon
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button05icon
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button06icon
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button07icon
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button08icon
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Text button01bri
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button02bri
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button03bri
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button04bri
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button05bri
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button06bri
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button07bri
Attributes
ID : 42
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Text button08bri
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 4
Button button_back
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page home
Hotspot button01
Attributes
ID : 44
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button01"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&1
if(sys0>0)
{
confirm.body.txt=button01text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button02
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button02"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&2
if(sys0>0)
{
confirm.body.txt=button02text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button03
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button03"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&4
if(sys0>0)
{
confirm.body.txt=button03text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button04
Attributes
ID : 47
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button04"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&8
if(sys0>0)
{
confirm.body.txt=button04text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button05
Attributes
ID : 48
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button05"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&16
if(sys0>0)
{
confirm.body.txt=button05text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button06
Attributes
ID : 49
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button06"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&32
if(sys0>0)
{
confirm.body.txt=button06text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button07
Attributes
ID : 50
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button07"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&64
if(sys0>0)
{
confirm.body.txt=button07text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Hotspot button08
Attributes
ID : 51
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
sys0=confirm.val&128
if(sys0>0)
{
confirm.body.txt=button08text.txt
confirm.page_id.val=dp
confirm.page_name.txt=page_name.txt
confirm.component.txt=click_comp.txt
page confirm
}else
{
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer click_timer
Attributes
ID : 8
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 10
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
page buttonpage03
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
page home
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,867 @@
Page climate
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==1||embedded.val==1)
{
sendme
vis target_icon,0
vis target_high,0
vis target_low,0
vis current_temp,0
vis climateslider,0
vis slider_high,0
vis slider_low,0
vis button01,0
vis button02,0
vis button03,0
vis button04,0
vis button05,0
vis button06,0
vis button07,0
}else
{
page home
}
Page Exit Event
covx embedded.val,va2.txt,0,0
if(timer0.en==1)
{
timer0.en=0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer1.en==1)
{
timer1.en=0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
if(timer2.en==1)
{
timer2.en=0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
}
Variable (string) va1
Attributes
ID : 24
Scope : local
Text :
Max. Text Size: 10
Variable (string) climatesetting
Attributes
ID : 25
Scope : local
Text :
Max. Text Size: 255
Variable (string) lastclick
Attributes
ID : 26
Scope : local
Text :
Max. Text Size: 255
Variable (int32) temp_offset
Attributes
ID : 28
Scope: local
Value: 0
Variable (int32) temp_step
Attributes
ID : 29
Scope: local
Value: 0
Variable (int32) temp_number0
Attributes
ID : 33
Scope: local
Value: 0
Variable (int32) va0
Attributes
ID : 34
Scope: local
Value: 0
Variable (int32) embedded
Attributes
ID : 35
Scope: global
Value: 0
Variable (string) va2
Attributes
ID : 36
Scope : local
Text :
Max. Text Size: 10
Variable (string) click_comp
Attributes
ID : 38
Scope : local
Text :
Max. Text Size: 8
Variable (int32) active_slider
Attributes
ID : 42
Scope: local
Value: 1
Variable (int32) is_temp_range
Attributes
ID : 44
Scope: local
Value: 0
Variable (int32) temp_number1
Attributes
ID : 48
Scope: local
Value: 0
Variable (int32) temp_number2
Attributes
ID : 49
Scope: local
Value: 0
Text current_temp
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 25
Text page_label
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text target_icon
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01_icon
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value01
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value02_icon
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value02
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value03_icon
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value03
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text value04_icon
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text value04
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 6
Text button01
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button02
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button03
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button04
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button05
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button06
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button07
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 3
Events
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button08
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button09
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text target_high
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
active_slider.val=is_temp_range.val
Text target_low
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Release Event
active_slider.val=2
Slider slider_high
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=1
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer1.en=1
Slider slider_low
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=2
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
timer2.en=1
Slider climateslider
Attributes
ID : 45
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Release Event
active_slider.val=0
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer0.en=1
Button button_back
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Hotspot decrease_temp
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val>0)
{
climateslider.val--
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val>0)
{
slider_high.val--
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val>0)
{
slider_low.val--
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Hotspot increase_temp
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
Events
Touch Press Event
if(active_slider.val==0)
{
if(climateslider.val<climateslider.maxval)
{
climateslider.val++
temp_number0.val=climateslider.val*temp_step.val
temp_number0.val+=temp_offset.val
va0.val=temp_number0.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==1)
{
if(slider_high.val<slider_high.maxval)
{
slider_high.val++
temp_number1.val=slider_high.val*temp_step.val
temp_number1.val+=temp_offset.val
va0.val=temp_number1.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
}
}else if(active_slider.val==2)
{
if(slider_low.val<slider_low.maxval)
{
slider_low.val++
temp_number2.val=slider_low.val*temp_step.val
temp_number2.val+=temp_offset.val
va0.val=temp_number2.val/10
covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt
}
}
Touch Release Event
if(active_slider.val==0)
{
timer0.en=1
}else if(active_slider.val==1)
{
timer1.en=1
}else if(active_slider.val==2)
{
timer2.en=1
}
Timer swipestore
Attributes
ID : 2
Scope : local
Period (ms): 50
Enabled : no
Events
Timer Event
swipex=tch0
swipey=tch1
Timer timer0
Attributes
ID : 27
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer0.en=0
covx embedded.val,va2.txt,0,0
covx temp_number0.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"temperature\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer click_timer
Attributes
ID : 39
Scope : local
Period (ms): 800
Enabled : no
Events
Timer Event
lastclick.txt="{\"page\": \"climate\", \"event\": \"long_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
click_timer.en=0
Timer wakeup_timer
Attributes
ID : 40
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}
Timer timer1
Attributes
ID : 46
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer1.en=0
covx embedded.val,va2.txt,0,0
covx temp_number1.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_high\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
Timer timer2
Attributes
ID : 47
Scope : local
Period (ms): 1000
Enabled : no
Events
Timer Event
timer2.en=0
covx embedded.val,va2.txt,0,0
covx temp_number2.val,va1.txt,0,0
climatesetting.txt="{\"page\": \"climate\", \"key\": \"target_temp_low\", \"value\": "+va1.txt+", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints climatesetting.txt,0
printh 00
printh FF FF FF
TouchCap swipe
Attributes
ID : 1
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
Touch Release Event
swipestore.en=0
// Touch has ended, x
if(tch0==0)
{
swipec=swipex-tch2
// From Left to Right
if(swipec>swipedx)
{
//page
}
// Right to Left
swipec2=0-swipedx
if(swipec<swipec2)
{
//page
}
}
// Touch has ended, y
if(tch1==0)
{
swipec=swipey-tch3
// From Up to Down
if(swipec>100)
{
//page
}
// Down to Up
swipec2=0-swipedy
if(swipec<-100)
{
//page
}
}

View File

@@ -0,0 +1,151 @@
Page confirm
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (int32) page_id
Attributes
ID : 3
Scope: global
Value: 0
Variable (string) aux
Attributes
ID : 5
Scope : local
Text :
Max. Text Size: 255
Variable (string) page_name
Attributes
ID : 9
Scope : global
Text :
Max. Text Size: 12
Variable (string) component
Attributes
ID : 10
Scope : global
Text :
Max. Text Size: 10
Text t0
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text title
Attributes
ID : 4
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 100
Text body
Attributes
ID : 8
Scope : global
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Please confirm
Max. Text Size : 255
Button bclose
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Button bt_accept
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î— 
Max. Text Size : 3
Events
Touch Release Event
aux.txt="{\"page\": \""+page_name.txt+"\", \"event\": \"short_click\", \"component\": \""+component.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints aux.txt,0
printh 00
printh FF FF FF
page page_id.val
Button bt_clear
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…™
Max. Text Size : 10
Events
Touch Release Event
page page_id.val
Timer wakeup_timer
Attributes
ID : 11
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

View File

@@ -0,0 +1,202 @@
Page cover
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}else
{
sendme
}
Variable (string) va1
Attributes
ID : 7
Scope : local
Text : newtxt
Max. Text Size: 10
Variable (string) coversetting
Attributes
ID : 11
Scope : local
Text :
Max. Text Size: 255
Text battery_value
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text cover_value
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text page_label
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 100
Text icon_state
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Text battery_icon
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text :
Max. Text Size : 10
Slider coverslider
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID: on press and release
Position : 0
Upper range limit: 100
Lower range limit: 0
Events
Touch Release Event
covx coverslider.val,va1.txt,0,0
cover_value.txt=va1.txt+"%"
coversetting.txt="{\"page\": \"cover\", \"key\": \"position\", \"value\": "+va1.txt+"}"
printh 92
prints "localevent",0
printh 00
prints coversetting.txt,0
printh 00
printh FF FF FF
Button cover_open
Attributes
ID : 4
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"open_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_close
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : ï„›
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"close_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button cover_stop
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : 
Max. Text Size : 3
Events
Touch Press Event
printh 92
prints "localevent",0
printh 00
prints "{\"page\": \"cover\", \"key\": \"stop_cover\", \"value\": \"press\"}",0
printh 00
printh FF FF FF
Button button_back
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 13
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}

Some files were not shown because too many files have changed in this diff Show More