Compare commits

...

24 Commits

Author SHA1 Message Date
joBr99
7ee16ef2e6 added some icons #120 (add nextion2text) 2022-04-03 16:02:25 +00:00
Johannes
22b4b7ccf1 added some icons #120 2022-04-03 18:01:57 +02:00
Johannes
7196dbd90e Update README.md 2022-04-03 16:28:18 +02:00
Johannes
9ba4d04ccc change date parser 2022-04-03 14:30:32 +02:00
Johannes
2f072a4e68 Update pages.py 2022-04-03 14:09:56 +02:00
joBr99
06ed5d721e Merge branch 'main' of https://github.com/joBr99/nspanel-lovelace-ui (add nextion2text) 2022-04-03 11:36:29 +00:00
Johannes
3b2db021f8 Merge branch 'main' of https://github.com/joBr99/nspanel-lovelace-ui 2022-04-03 13:36:05 +02:00
Johannes
33c7b8850a added some icons 2022-04-03 13:35:46 +02:00
Johannes
e1bc46f26e Update README.md 2022-04-03 12:55:25 +02:00
Johannes
8f520f1bc9 Update README.md 2022-04-03 12:41:14 +02:00
Johannes
95905e18cb Create README.md 2022-04-03 12:12:23 +02:00
Johannes
8b7d196721 fix doubletap config location 2022-04-03 11:46:25 +02:00
Johannes
aadebf801a added default card after screensaver exit 2022-04-03 11:28:11 +02:00
Johannes
ab74c80ab2 Merge branch 'main' of https://github.com/joBr99/nspanel-lovelace-ui 2022-04-03 09:53:04 +02:00
Johannes
b9ddb24a6d bump version 2022-04-03 09:49:00 +02:00
Johannes
0df505a0eb fix media page 2022-04-03 09:47:44 +02:00
joBr99
ebafe52f39 Merge branch 'main' of https://github.com/joBr99/nspanel-lovelace-ui (add nextion2text) 2022-04-03 07:35:49 +00:00
Johannes
265c95845f Merge branch 'main' of https://github.com/joBr99/nspanel-lovelace-ui 2022-04-03 09:35:25 +02:00
Johannes
218148bcfb change msg format media page 2022-04-03 09:35:14 +02:00
joBr99
d46a4ea46f fixed navigation on subpages for cardThermo cardMedia and cardAlarm (add nextion2text) 2022-04-03 07:18:00 +00:00
Johannes
767ed78c40 fixed navigation on subpages for cardThermo cardMedia and cardAlarm 2022-04-03 09:17:33 +02:00
Johannes
89669f68f0 Update README.md 2022-04-02 23:27:36 +02:00
Johannes
18805ccae2 Update README.md 2022-04-02 22:50:32 +02:00
Johannes
c4d920b3b7 Update README.md 2022-04-02 22:50:00 +02:00
39 changed files with 217 additions and 170 deletions

View File

@@ -123,7 +123,7 @@ The following message can be used to update the content on the cardEntities Page
### cardMedia Page
`entityUpd~|*heading*|*navigation*|*internalNameEntiy*|*icon*|*title*|*author*|*volume*|*playpauseicon*|currentSpeaker|speakerList-seperated-by-?`
`entityUpd~*heading*~*navigation*~*internalNameEntiy*~*icon*~*title*~*author*~*volume*~*playpauseicon*~currentSpeaker~speakerList-seperated-by-?`
### cardAlarm Page
@@ -132,83 +132,83 @@ The following message can be used to update the content on the cardEntities Page
## Messages from Nextion Display
`event~buttonPress2~pageName~bNext`
`event,buttonPress2,pageName,bNext`
`event~buttonPress2~pageName~bPrev`
`event,buttonPress2,pageName,bPrev`
`event~buttonPress2~pageName~bExit~number_of_taps`
`event,buttonPress2,pageName,bExit,number_of_taps`
`event~buttonPress2~pageName~sleepReached`
`event,buttonPress2,pageName,sleepReached`
### startup page
`event~startup~version~model`
`event,startup,version,model`
### screensaver page
`event~buttonPress2~screensaver~exit` - Touch Event on Screensaver
`event,buttonPress2,screensaver,exit` - Touch Event on Screensaver
`event~screensaverOpen` - Screensaver has opened
`event,screensaverOpen` - Screensaver has opened
### cardEntities Page
`event~*eventName*~*entityName*~*actionName*~*optionalValue*`
`event,*eventName*,*entityName*,*actionName*,*optionalValue*`
`event~buttonPress2~internalNameEntity~up`
`event,buttonPress2,internalNameEntity,up`
`event~buttonPress2~internalNameEntity~down`
`event,buttonPress2,internalNameEntity,down`
`event~buttonPress2~internalNameEntity~stop`
`event,buttonPress2,internalNameEntity,stop`
`event~buttonPress2~internalNameEntity~OnOff~1`
`event,buttonPress2,internalNameEntity,OnOff,1`
`event~buttonPress2~internalNameEntity~button`
`event,buttonPress2,internalNameEntity,button`
### popupLight Page
`event~pageOpenDetail~popupLight~internalNameEntity`
`event,pageOpenDetail,popupLight,internalNameEntity`
`event~buttonPress2~internalNameEntity~OnOff~1`
`event,buttonPress2,internalNameEntity,OnOff,1`
`event~buttonPress2~internalNameEntity~brightnessSlider~50`
`event,buttonPress2,internalNameEntity,brightnessSlider,50`
`event~buttonPress2~internalNameEntity~colorTempSlider~50`
`event,buttonPress2,internalNameEntity,colorTempSlider,50`
`event~buttonPress2~internalNameEntity~colorWheel~x|y`
`event,buttonPress2,internalNameEntity,colorWheel,x|y`
### popupShutter Page
`event~pageOpenDetail~popupShutter~internalNameEntity`
`event,pageOpenDetail,popupShutter,internalNameEntity`
`event~buttonPress2~internalNameEntity~positionSlider~50`
`event,buttonPress2,internalNameEntity,positionSlider,50`
### popupNotify Page
`event~buttonPress2~*internalName*~notifyAction~yes`
`event,buttonPress2,*internalName*,notifyAction,yes`
`event~buttonPress2~*internalName*~notifyAction~no`
`event,buttonPress2,*internalName*,notifyAction,no`
### cardThermo Page
`event~buttonPress2~*entityName*~tempUpd~*temperature*`
`event,buttonPress2,*entityName*,tempUpd,*temperature*`
`event~buttonPress2~*entityName*~hvac_action~*hvac_action*`
`event,buttonPress2,*entityName*,hvac_action,*hvac_action*`
### cardMedia Page
`event~buttonPress2~internalNameEntity~media-back`
`event,buttonPress2,internalNameEntity,media-back`
`event~buttonPress2~internalNameEntity~media-pause`
`event,buttonPress2,internalNameEntity,media-pause`
`event~buttonPress2~internalNameEntity~media-next`
`event,buttonPress2,internalNameEntity,media-next`
`event~buttonPress2~internalNameEntity~volumeSlider~75`
`event,buttonPress2,internalNameEntity,volumeSlider,75`
### cardAlarm Page
`event~buttonPress2~internalNameEntity~actionName~code`
`event,buttonPress2,internalNameEntity,actionName,code`
# Icons IDs
@@ -218,7 +218,7 @@ Please see Icon's int the [icons.md file](icons.md)
# Design Guidelines for Nextion HMI Project
Background Color is
- RGB565: 6371 [18e3] (HEX: #1C1C1C~ RGB: 28~28~28)
- RGB565: 6371 [18e3] (HEX: #1C1C1C, RGB: 28,28,28)
Source for Icons is the Material Design Font~ used by HASPone
Source for Icons is the Material Design Font, used by HASPone
https://github.com/HASwitchPlate/HASPone

View File

@@ -1,6 +1,6 @@
diff -bur HMI/n2t-out/Program.s.txt HMI/US/landscape/n2t-out/Program.s.txt
--- HMI/n2t-out/Program.s.txt 2022-04-02 17:52:28.361158189 +0000
+++ HMI/US/landscape/n2t-out/Program.s.txt 2022-04-02 17:52:29.069163241 +0000
--- HMI/n2t-out/Program.s.txt 2022-04-03 16:02:24.464717607 +0000
+++ HMI/US/landscape/n2t-out/Program.s.txt 2022-04-03 16:02:25.284722859 +0000
@@ -11,6 +11,6 @@
// dim value
int dimValue=40
@@ -11,8 +11,8 @@ diff -bur HMI/n2t-out/Program.s.txt HMI/US/landscape/n2t-out/Program.s.txt
+ //lcd_dev fffb 0002 0000 0020
page pageStartup
diff -bur HMI/n2t-out/pageStartup.txt HMI/US/landscape/n2t-out/pageStartup.txt
--- HMI/n2t-out/pageStartup.txt 2022-04-02 17:52:28.361158189 +0000
+++ HMI/US/landscape/n2t-out/pageStartup.txt 2022-04-02 17:52:29.069163241 +0000
--- HMI/n2t-out/pageStartup.txt 2022-04-03 16:02:24.464717607 +0000
+++ HMI/US/landscape/n2t-out/pageStartup.txt 2022-04-03 16:02:25.288722884 +0000
@@ -177,7 +177,7 @@
recmod=1
bauds=115200

View File

@@ -931,7 +931,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -960,25 +960,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -987,14 +987,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -2,6 +2,10 @@ Program.s
0 Component(s)
10 Line(s) of event code
10 Unique line(s) of event code
pageIcons
7 Component(s)
0 Line(s) of event code
0 Unique line(s) of event code
pageTest
13 Component(s)
13 Line(s) of event code
@@ -10,10 +14,6 @@ pageSerialTest
13 Component(s)
48 Line(s) of event code
43 Unique line(s) of event code
pageIcons
7 Component(s)
0 Line(s) of event code
0 Unique line(s) of event code
popupNotify
17 Component(s)
178 Line(s) of event code
@@ -22,10 +22,6 @@ pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
popupShutter
19 Component(s)
178 Line(s) of event code
@@ -42,6 +38,10 @@ screensaver
33 Component(s)
207 Line(s) of event code
158 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
cardAlarm
35 Component(s)
345 Line(s) of event code
@@ -59,4 +59,4 @@ Total
13 Page(s)
355 Component(s)
3646 Line(s) of event code
1045 Unique line(s) of event code
1039 Unique line(s) of event code

View File

@@ -56,8 +56,8 @@ Text tIcons
Horizontal Alignment : left
Vertical Alignment : top
Input Type : character
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Word wrap : enabled
Horizontal Spacing : 0
Vertical Spacing : 0

View File

@@ -402,7 +402,7 @@ Text tVersion
Horizontal Alignment : center
Vertical Alignment : center
Input Type : character
Text : 27
Text : 29
Max. Text Size : 10
Word wrap : disabled
Horizontal Spacing : 0

View File

@@ -509,7 +509,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -538,25 +538,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -565,14 +565,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -29,8 +29,8 @@ Text tIcons
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Text tTmp1
Attributes

View File

@@ -152,7 +152,7 @@ Text tVersion
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 27
Text : 29
Max. Text Size : 10
Picture p0

Binary file not shown.

Binary file not shown.

View File

@@ -1,6 +1,6 @@
diff -bur HMI/n2t-out/Program.s.txt HMI/US/portrait/n2t-out/Program.s.txt
--- HMI/n2t-out/Program.s.txt 2022-04-02 17:52:28.361158189 +0000
+++ HMI/US/portrait/n2t-out/Program.s.txt 2022-04-02 17:52:28.717160730 +0000
--- HMI/n2t-out/Program.s.txt 2022-04-03 16:02:24.464717607 +0000
+++ HMI/US/portrait/n2t-out/Program.s.txt 2022-04-03 16:02:24.872720220 +0000
@@ -11,6 +11,6 @@
// dim value
int dimValue=40
@@ -11,8 +11,8 @@ diff -bur HMI/n2t-out/Program.s.txt HMI/US/portrait/n2t-out/Program.s.txt
+ //lcd_dev fffb 0002 0000 0020
page pageStartup
diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt
--- HMI/n2t-out/cardEntities.txt 2022-04-02 17:52:28.361158189 +0000
+++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-04-02 17:52:28.721160758 +0000
--- HMI/n2t-out/cardEntities.txt 2022-04-03 16:02:24.468717633 +0000
+++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-04-03 16:02:24.872720220 +0000
@@ -62,6 +62,26 @@
vis bText4,0
vis hSlider4,0
@@ -781,8 +781,8 @@ diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt
if(tInstruction.txt=="pageType")
{
diff -bur HMI/n2t-out/pageStartup.txt HMI/US/portrait/n2t-out/pageStartup.txt
--- HMI/n2t-out/pageStartup.txt 2022-04-02 17:52:28.361158189 +0000
+++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-04-02 17:52:28.717160730 +0000
--- HMI/n2t-out/pageStartup.txt 2022-04-03 16:02:24.464717607 +0000
+++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-04-03 16:02:24.872720220 +0000
@@ -142,7 +142,7 @@
Disable release event after dragging: 0
Send Component ID : disabled

View File

@@ -931,7 +931,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -960,25 +960,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -987,14 +987,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -6,18 +6,14 @@ pageSerialTest
13 Component(s)
48 Line(s) of event code
43 Unique line(s) of event code
pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
pageIcons
7 Component(s)
0 Line(s) of event code
0 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
popupNotify
17 Component(s)
178 Line(s) of event code
@@ -34,6 +30,10 @@ screensaver
33 Component(s)
207 Line(s) of event code
158 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
popupShutter
19 Component(s)
178 Line(s) of event code
@@ -59,4 +59,4 @@ Total
13 Page(s)
379 Component(s)
4036 Line(s) of event code
1159 Unique line(s) of event code
1153 Unique line(s) of event code

View File

@@ -56,8 +56,8 @@ Text tIcons
Horizontal Alignment : left
Vertical Alignment : top
Input Type : character
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Word wrap : enabled
Horizontal Spacing : 0
Vertical Spacing : 0

View File

@@ -402,7 +402,7 @@ Text tVersion
Horizontal Alignment : center
Vertical Alignment : center
Input Type : character
Text : 27
Text : 29
Max. Text Size : 10
Word wrap : disabled
Horizontal Spacing : 0

View File

@@ -509,7 +509,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -538,25 +538,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -565,14 +565,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -29,8 +29,8 @@ Text tIcons
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Text tTmp1
Attributes

View File

@@ -152,7 +152,7 @@ Text tVersion
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 27
Text : 29
Max. Text Size : 10
Picture p0

Binary file not shown.

Binary file not shown.

View File

@@ -55,7 +55,14 @@ icons = [
"cast-audio",
"cast",
"radio",
"fireplace"
"fireplace",
"arrow-left-bold",
"arrow-right-bold",
"sofa",
"garage-variant",
"bed",
"soccer",
"silverware-variant"
]

View File

@@ -58,3 +58,10 @@ ID | MD Icon Name | Icon
51 | cast | ![cast](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/cast.svg)
52 | radio | ![radio](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/radio.svg)
53 | fireplace | ![fireplace](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/fireplace.svg)
54 | arrow-left-bold | ![arrow-left-bold](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/arrow-left-bold.svg)
55 | arrow-right-bold | ![arrow-right-bold](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/arrow-right-bold.svg)
56 | sofa | ![sofa](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/sofa.svg)
57 | garage-variant | ![garage-variant](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/garage-variant.svg)
58 | bed | ![bed](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/bed.svg)
59 | soccer | ![soccer](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/soccer.svg)
60 | silverware-variant | ![silverware-variant](https://raw.githubusercontent.com/Templarian/MaterialDesign-SVG/0aeb4d612644d80d9d1fe242f705f362985de5dc/svg/silverware-variant.svg)

View File

@@ -931,7 +931,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -960,25 +960,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -987,14 +987,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -2,6 +2,10 @@ Program.s
0 Component(s)
11 Line(s) of event code
11 Unique line(s) of event code
pageIcons
7 Component(s)
0 Line(s) of event code
0 Unique line(s) of event code
pageTest
13 Component(s)
13 Line(s) of event code
@@ -10,10 +14,10 @@ pageSerialTest
13 Component(s)
48 Line(s) of event code
43 Unique line(s) of event code
pageIcons
7 Component(s)
0 Line(s) of event code
0 Unique line(s) of event code
pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
popupNotify
17 Component(s)
178 Line(s) of event code
@@ -22,22 +26,18 @@ popupShutter
19 Component(s)
178 Line(s) of event code
101 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
popupLight
27 Component(s)
322 Line(s) of event code
173 Unique line(s) of event code
pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
cardThermo
41 Component(s)
460 Line(s) of event code
284 Unique line(s) of event code
cardMedia
30 Component(s)
333 Line(s) of event code
170 Unique line(s) of event code
screensaver
33 Component(s)
207 Line(s) of event code
@@ -59,4 +59,4 @@ Total
13 Page(s)
355 Component(s)
3647 Line(s) of event code
1046 Unique line(s) of event code
1040 Unique line(s) of event code

View File

@@ -56,8 +56,8 @@ Text tIcons
Horizontal Alignment : left
Vertical Alignment : top
Input Type : character
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Word wrap : enabled
Horizontal Spacing : 0
Vertical Spacing : 0

View File

@@ -402,7 +402,7 @@ Text tVersion
Horizontal Alignment : center
Vertical Alignment : center
Input Type : character
Text : 27
Text : 29
Max. Text Size : 10
Word wrap : disabled
Horizontal Spacing : 0

View File

@@ -509,7 +509,7 @@ Timer tmSerial
if(tInstruction.txt=="entityUpd")
{
//heading
spstr strCommand.txt,tHeading.txt,"|",1
spstr strCommand.txt,tHeading.txt,"~",1
// navigation icons
spstr strCommand.txt,tId.txt,"~",2
spstr tId.txt,tTmp.txt,"|",0
@@ -538,25 +538,25 @@ Timer tmSerial
bNext.txt=""
}
//entity name
spstr strCommand.txt,entn.txt,"|",3
spstr strCommand.txt,entn.txt,"~",3
//icon
spstr strCommand.txt,tTmp.txt,"|",4
spstr strCommand.txt,tTmp.txt,"~",4
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tIcon.txt,sys0,1
//title
spstr strCommand.txt,tTitle.txt,"|",5
spstr strCommand.txt,tTitle.txt,"~",5
//author
spstr strCommand.txt,tAuthor.txt,"|",6
spstr strCommand.txt,tAuthor.txt,"~",6
//volume
spstr strCommand.txt,tTmp.txt,"|",7
spstr strCommand.txt,tTmp.txt,"~",7
covx tTmp.txt,sys0,0,0
hVolume.val=sys0
//icon
spstr strCommand.txt,tTmp.txt,"|",8
spstr strCommand.txt,tTmp.txt,"~",8
covx tTmp.txt,sys0,0,0
substr pageIcons.tIcons.txt,tPlayPause.txt,sys0,1
//speaker current
spstr strCommand.txt,tSpeaker.txt,"|",9
spstr strCommand.txt,tSpeaker.txt,"~",9
if(tSpeaker.txt!="")
{
tSpeaker.pco=1374
@@ -565,14 +565,14 @@ Timer tmSerial
tSpeaker.pco=65535
}
//speaker list
spstr strCommand.txt,vaSpeakerList.txt,"|",10
spstr strCommand.txt,vaSpeakerList.txt,"~",10
if(vaSpeakerList.txt=="")
{
vis t6,0
}
vaSpeakerPos.val=0
// on off button
spstr strCommand.txt,tTmp.txt,"|",11
spstr strCommand.txt,tTmp.txt,"~",11
if(tTmp.txt=="disable")
{
vis t5,0

View File

@@ -29,8 +29,8 @@ Text tIcons
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 
Max. Text Size : 170
Text : 
Max. Text Size : 185
Text tTmp1
Attributes

View File

@@ -152,7 +152,7 @@ Text tVersion
Disable release event after dragging: 0
Send Component ID : disabled
Associated Keyboard : none
Text : 27
Text : 29
Max. Text Size : 10
Picture p0

Binary file not shown.

Binary file not shown.

View File

@@ -4,6 +4,7 @@ If you like this project consider buying me a pizza 🍕 <a href="https://paypal
[![hacs_badge](https://img.shields.io/badge/HACS-Default-41BDF5.svg)](https://github.com/hacs/integration)
![hacs validation](https://github.com/joBr99/nspanel-lovelace-ui/actions/workflows/hacs-validation.yaml/badge.svg)
[![Man Hours](https://img.shields.io/endpoint?url=https%3A%2F%2Fmh.jessemillar.com%2Fhours%3Frepo%3Dhttps%3A%2F%2Fgithub.com%2FjoBr99%2Fnspanel-lovelace-ui.git)](https://jessemillar.com/r/man-hours)
NsPanel Lovelace UI is a Firmware for the nextion screen inside of NSPanel in the Design of [HomeAssistant](https://www.home-assistant.io/)'s Lovelace UI Design.
@@ -313,6 +314,7 @@ nspanel-1:
- entity: delete
- entity: button.example_item
- entity: cover.example_item
- entity: delete # delete at the end is optional
title: Exmaple Gird
- type: cardThermo
entity: climate.example_item
@@ -369,6 +371,7 @@ key | optional | type | default | description
`weatherOverrideForecast4` | True | complex | `None` | sensor entity from home assistant here to override the forth weather forecast item on the screensaver
`doubleTapToUnlock` | True | boolean | `False` | requires to tap screensaver two times
`alternativeLayout` | True | boolean | `False` | alternative layout with humidity
`defaultCard` | True | string | `None` | default page after exiting screensaver; only works with top level cards defined in cards; needs to be a navigation item, see subpages (navigate.type_key)
`key` | True | string | `None` | Used by navigate items
Example for the weatherOverride config options:
@@ -406,7 +409,7 @@ Only the icons listed in the [Icon Table](HMI#icons-ids) are useable.
#### Subpages
You can configure entities with with the prefix `navigate`, that are navigating to cards, in case it's hidden page, the navigation items will change and the arrow is bringing you back to the current page on the top level.
You can configure entities with with the prefix `navigate`, that are navigating to cards, in case it's hidden card, the navigation items will change and the arrow is bringing you back to the privious page.
```yaml
- entity: navigate.cardGrid_testKey

12
appdaemon/README.md Normal file
View File

@@ -0,0 +1,12 @@
# Example configurations
This folder contains some example configs
## appdaemon.yaml
Example config for appademon itself
## apps.yaml
"Simple" Example Config with all possible entity types

View File

@@ -84,7 +84,8 @@ class LuiBackendConfig(object):
'weatherOverrideForecast3': None,
'weatherOverrideForecast4': None,
'doubleTapToUnlock': False,
'alternativeLayout': False
'alternativeLayout': False,
'defaultCard': None
},
'hiddenCards': []
}

View File

@@ -15,6 +15,7 @@ class LuiController(object):
# first card (default, after startup)
self._current_card = self._config.getCard(0)
self._previous_cards = []
self._pages_gen = LuiPagesGen(ha_api, config, send_mqtt_msg)
@@ -132,9 +133,16 @@ class LuiController(object):
LOGGER.info(f"Button Press Event; entity_id: {entity_id}; button_type: {button_type}; value: {value} ")
# internal buttons
if entity_id == "screensaver" and button_type == "bExit":
if self._config.get("doubleTapToUnlock") and int(value) >= 2:
# get default card if there is one
if self._config.get("screensaver.defaultCard") is not None:
dstCard = self._config.searchCard(self._config.get("screensaver.defaultCard"))
if dstCard is not None:
self._previous_cards = []
self._current_card = dstCard
# check for duouble tap if configured and render current page
if self._config.get("screensaver.doubleTapToUnlock") and int(value) >= 2:
self._pages_gen.render_card(self._current_card)
elif not self._config.get("doubleTapToUnlock"):
elif not self._config.get("screensaver.doubleTapToUnlock"):
self._pages_gen.render_card(self._current_card)
return
@@ -145,8 +153,8 @@ class LuiController(object):
if button_type == "bExit":
self._pages_gen.render_card(self._current_card)
if button_type == "bUp":
self._current_card = self._previous_card
self._pages_gen.render_card(self._previous_card)
self._current_card = self._previous_cards.pop()
self._pages_gen.render_card(self._current_card)
if button_type == "bNext":
card = self._config.getCard(self._current_card.pos+1)
@@ -184,7 +192,7 @@ class LuiController(object):
if button_type == "button":
if entity_id.startswith('navigate'):
# internal for navigation to nested pages
self._previous_card = self._current_card
self._previous_cards.append(self._current_card)
self._current_card = self._config.searchCard(entity_id)
self._pages_gen.render_card(self._current_card)
elif entity_id.startswith('scene'):

View File

@@ -53,6 +53,13 @@ icons = {
'cast': 51,
'radio': 52,
'fireplace': 53,
'arrow-left-bold': 54,
'arrow-right-bold': 55,
'sofa': 56,
'garage-variant': 57,
'bed': 58,
'soccer': 59,
'silverware-variant': 60,
}
def get_icon_id(ma_name):

View File

@@ -1,5 +1,6 @@
import logging
import datetime
import dateutil.parser as dp
from icon_mapping import get_icon_id
from icons import get_icon_id_ha
@@ -78,7 +79,8 @@ class LuiPagesGen(object):
wOF = self._config._config_screensaver.raw_config.get(f"weatherOverrideForecast{i}")
if wOF is None:
up = we.attributes.forecast[i-1]['datetime']
up = datetime.datetime.fromisoformat(up)
#up = datetime.datetime.fromisoformat(up)
up = dp.parse(up)
if babel_spec is not None:
up = babel.dates.format_date(up, "E", locale=self._locale)
else:
@@ -116,7 +118,7 @@ class LuiPagesGen(object):
if entityType == "navigate":
page_search_res = self._config.searchCard(entityId)
if page_search_res is not None:
name = page_search_res.title
name = name if name is not None else page_search_res.title
text = get_translation(self._locale,"PRESS")
icon_id = get_icon_id(icon) if icon is not None else get_icon_id("gesture-tap-button")
return f"~button~{entityId}~{icon_id}~17299~{name}~{text}"
@@ -165,6 +167,7 @@ class LuiPagesGen(object):
min_v = entity.attributes.get("min", 0)
max_v = entity.attributes.get("max", 100)
return f"~number~{entityId}~{icon_id}~17299~{name}~{entity.state}|{min_v}|{max_v}"
return f"~text~{entityId}~{get_icon_id('alert-circle-outline')}~17299~error~"
def generate_entities_page(self, navigation, heading, items):
command = f"entityUpd~{heading}~{navigation}"
@@ -178,7 +181,7 @@ class LuiPagesGen(object):
def generate_thermo_page(self, navigation, entity):
item = entity.entityId
if not self._ha_api.entity_exists(item):
command = f"entityUpd~{item}~Not found~220~220~Not found~150~300~5"
command = f"entityUpd~{heading}~{navigation}~{item}~220~220~Not found~150~300~5"
else:
entity = self._ha_api.get_entity(item)
heading = entity.attributes.friendly_name
@@ -230,13 +233,13 @@ class LuiPagesGen(object):
icon_res = "~"*4*padding_len + icon_res + "~"*4*padding_len
# use first 5 icons
icon_res = icon_res + "~"*4*4
command = f"entityUpd~{heading}~~{item}~{current_temp}~{dest_temp}~{status}~{min_temp}~{max_temp}~{step_temp}{icon_res}"
command = f"entityUpd~{heading}~{navigation}~{item}~{current_temp}~{dest_temp}~{status}~{min_temp}~{max_temp}~{step_temp}{icon_res}"
self._send_mqtt_msg(command)
def generate_media_page(self, navigation, entity):
item = entity.entityId
if not self._ha_api.entity_exists(item):
command = f"entityUpd~|{item}|Not found|{get_icon_id('alert-circle-outline')}|Please check your|apps.yaml in AppDaemon|50|{get_icon_id('alert-circle-outline')}"
command = f"entityUpd~|Not found||{item}|{get_icon_id('alert-circle-outline')}|Please check your|apps.yaml in AppDaemon|50|{get_icon_id('alert-circle-outline')}"
else:
entity = self._ha_api.get_entity(item)
heading = entity.attributes.friendly_name
@@ -264,13 +267,13 @@ class LuiPagesGen(object):
onoffbutton = 1374
else:
onoffbutton = rgb_dec565([255,255,255])
command = f"entityUpd~|{heading}||{item}|{icon}|{title}|{author}|{volume}|{iconplaypause}|{source}|{speakerlist[:200]}|{onoffbutton}"
command = f"entityUpd~{heading}~{navigation}~{item}~{icon}~{title}~{author}~{volume}~{iconplaypause}~{source}~{speakerlist[:200]}~{onoffbutton}"
self._send_mqtt_msg(command)
def generate_alarm_page(self, navigation, entity):
item = entity.entityId
if not self._ha_api.entity_exists(item):
command = f"entityUpd~{item}~Not found~Not found~Check your~Check your~apps.~apps.~yaml~yaml~0~~0"
command = f"entityUpd~{item}~~Not found~Not found~Check your~Check your~apps.~apps.~yaml~yaml~0~~0"
else:
entity = self._ha_api.get_entity(item)
icon = get_icon_id("shield-off")
@@ -324,7 +327,6 @@ class LuiPagesGen(object):
arm_buttons += f"~{get_translation(self._locale, b)}~{b}"
if len(supported_modes) < 4:
arm_buttons += "~"*((4-len(supported_modes))*2)
navigation = ""
command = f"entityUpd~{item}~{navigation}{arm_buttons}~{icon}~{color}~{numpad}~{flashing}"
self._send_mqtt_msg(command)
@@ -388,4 +390,4 @@ class LuiPagesGen(object):
def send_message_page(self, id, heading, msg, b1, b2):
self._send_mqtt_msg(f"pageType~popupNotify")
self._send_mqtt_msg(f"entityUpdateDetail~{id}~{heading}~65535~{b1}~65535~{b2}~65535~{msg}~65535~0")
self._send_mqtt_msg(f"entityUpdateDetail~{id}~{heading}~65535~{b1}~65535~{b2}~65535~{msg}~65535~0")

View File

@@ -63,8 +63,8 @@ class NsPanelLovelaceUIManager(hass.Hass):
controller = LuiController(self, cfg, send_mqtt_msg)
desired_display_firmware_version = 27
version = "v2.4.6"
desired_display_firmware_version = 29
version = "v2.5.5"
model = cfg.get("model")
if model == "us-l":