fixed screensaver pagetype (add nextion2text)

This commit is contained in:
joBr99
2022-03-31 10:46:03 +00:00
committed by GitHub Actions
parent 39c1aa6773
commit d908cb7d96
32 changed files with 680 additions and 173 deletions

View File

@@ -6,7 +6,7 @@ Program.s
int payloadLength=0
int par0=0,par1=0
// sleep timeout in s
int sleepTimeout=20
int sleepTimeout=2
int sleepValue=0
// dim value
int dimValue=40

View File

@@ -1145,35 +1145,48 @@ Timer tmSerial
//we are going to exit this page with this command, so we have to clear the buffer, so we are not getting into a stupid loop ...
udelete payloadLength-1
bufferPos=0
if(tId.txt=="popupLight")
if(tId.txt=="pageStartup")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
page pageStartup
}
if(tId.txt=="screensaver")
{
page screensaver
}
if(tId.txt=="cardEntities")
{
page cardEntities
}
if(tId.txt=="cardThermo")
if(tId.txt=="cardGrid")
{
page cardThermo
page cardGrid
}
if(tId.txt=="pageStartup")
if(tId.txt=="popupLight")
{
page pageStartup
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
}
if(tId.txt=="popupShutter")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupShutter
}
if(tId.txt=="popupNotify")
{
page popupNotify
}
if(tId.txt=="cardGrid")
if(tId.txt=="cardThermo")
{
page cardGrid
page cardThermo
}
if(tId.txt=="cardMedia")
{
page cardMedia
}
if(tId.txt=="cardAlarm")
{
page cardAlarm
}
}
// end of user code
udelete payloadLength-1
@@ -1196,7 +1209,7 @@ Timer tmSleep
Events
Timer Event
if(sleepTimeout!=0)
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)

View File

@@ -2660,7 +2660,7 @@ Timer tmSleep
Events
Timer Event
if(sleepTimeout!=0)
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)

View File

@@ -1242,7 +1242,7 @@ Timer tmSleep
Events
Timer Event
if(sleepTimeout!=0)
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)

View File

@@ -1005,30 +1005,43 @@ Timer tmSerial
//we are going to exit this page with this command, so we have to clear the buffer, so we are not getting into a stupid loop ...
udelete payloadLength-1
bufferPos=0
if(tId.txt=="popupLight")
if(tId.txt=="pageStartup")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
page pageStartup
}
if(tId.txt=="screensaver")
{
page screensaver
}
if(tId.txt=="cardEntities")
{
page cardEntities
}
if(tId.txt=="cardThermo")
if(tId.txt=="cardGrid")
{
page cardThermo
page cardGrid
}
if(tId.txt=="pageStartup")
if(tId.txt=="popupLight")
{
page pageStartup
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
}
if(tId.txt=="popupShutter")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupShutter
}
if(tId.txt=="popupNotify")
{
page popupNotify
}
if(tId.txt=="cardGrid")
if(tId.txt=="cardThermo")
{
page cardGrid
page cardThermo
}
if(tId.txt=="cardMedia")
{
page cardMedia
}
if(tId.txt=="cardAlarm")
{
@@ -1065,7 +1078,7 @@ Timer tmSleep
Events
Timer Event
if(sleepTimeout!=0)
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)

View File

@@ -1419,30 +1419,43 @@ Timer tmSerial
//we are going to exit this page with this command, so we have to clear the buffer, so we are not getting into a stupid loop ...
udelete payloadLength-1
bufferPos=0
if(tId.txt=="popupLight")
if(tId.txt=="pageStartup")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
page pageStartup
}
if(tId.txt=="screensaver")
{
page screensaver
}
if(tId.txt=="cardEntities")
{
page cardEntities
}
if(tId.txt=="cardMedia")
if(tId.txt=="cardGrid")
{
page cardMedia
page cardGrid
}
if(tId.txt=="pageStartup")
if(tId.txt=="popupLight")
{
page pageStartup
pageIcons.tTmp1.txt=tTmp.txt
page popupLight
}
if(tId.txt=="popupShutter")
{
pageIcons.tTmp1.txt=tTmp.txt
page popupShutter
}
if(tId.txt=="popupNotify")
{
page popupNotify
}
if(tId.txt=="cardGrid")
if(tId.txt=="cardThermo")
{
page cardGrid
page cardThermo
}
if(tId.txt=="cardMedia")
{
page cardMedia
}
if(tId.txt=="cardAlarm")
{
@@ -1470,7 +1483,7 @@ Timer tmSleep
Events
Timer Event
if(sleepTimeout!=0)
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)

View File

@@ -22,26 +22,30 @@ popupShutter
19 Component(s)
178 Line(s) of event code
101 Unique line(s) of event code
cardThermo
41 Component(s)
427 Line(s) of event code
232 Unique line(s) of event code
pageStartup
19 Component(s)
150 Line(s) of event code
113 Unique line(s) of event code
cardAlarm
35 Component(s)
285 Line(s) of event code
181 Unique line(s) of event code
popupLight
27 Component(s)
322 Line(s) of event code
173 Unique line(s) of event code
cardMedia
30 Component(s)
287 Line(s) of event code
148 Unique line(s) of event code
300 Line(s) of event code
154 Unique line(s) of event code
cardAlarm
35 Component(s)
298 Line(s) of event code
187 Unique line(s) of event code
screensaver
28 Component(s)
172 Line(s) of event code
131 Unique line(s) of event code
29 Component(s)
182 Line(s) of event code
137 Unique line(s) of event code
cardGrid
39 Component(s)
397 Line(s) of event code
@@ -50,13 +54,9 @@ cardEntities
62 Component(s)
939 Line(s) of event code
397 Unique line(s) of event code
cardThermo
41 Component(s)
414 Line(s) of event code
226 Unique line(s) of event code
Total
13 Page(s)
350 Component(s)
3394 Line(s) of event code
920 Unique line(s) of event code
351 Component(s)
3443 Line(s) of event code
922 Unique line(s) of event code

View File

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

View File

@@ -917,6 +917,26 @@ Timer tmSerial
}
}
Timer tmSleep
Attributes
ID : 28
Scope : local
Period (ms): 1000
Enabled : yes
Events
Timer Event
if(sleepTimeout!=0&&dimValue!=dim)
{
sleepValue+=1
if(sleepTimeout<=sleepValue)
{
sleepValue=0
dim=dimValue
vaTap.val=0
}
}
TouchCap tc0
Attributes
ID : 2