From f8c91b8900cbfd4fca47062f334b0081d59a8e66 Mon Sep 17 00:00:00 2001 From: joBr99 <29555657+joBr99@users.noreply.github.com> Date: Sat, 21 May 2022 14:37:12 +0000 Subject: [PATCH] sync us-p (add nextion2text) --- HMI/US/landscape/diff-eu-version.txt | 8 +- HMI/US/portrait/diff-eu-version.txt | 738 ++++++++--------- HMI/US/portrait/diff-filtered.txt | 740 ++++++++---------- HMI/US/portrait/n2t-out-visual/cardAlarm.txt | 4 + .../portrait/n2t-out-visual/cardEntities.txt | 114 +++ HMI/US/portrait/n2t-out-visual/cardGrid.txt | 4 + HMI/US/portrait/n2t-out-visual/cardMedia.txt | 4 + HMI/US/portrait/n2t-out-visual/cardQR.txt | 155 +++- HMI/US/portrait/n2t-out-visual/cardThermo.txt | 4 + .../n2t-out-visual/nspanel_US_P_Stats.txt | 70 +- .../portrait/n2t-out-visual/pageStartup.txt | 2 +- HMI/US/portrait/n2t-out-visual/popupLight.txt | 275 ++++++- .../portrait/n2t-out-visual/popupNotify.txt | 4 + .../portrait/n2t-out-visual/popupShutter.txt | 4 + HMI/US/portrait/n2t-out/cardAlarm.txt | 4 + HMI/US/portrait/n2t-out/cardEntities.txt | 114 +++ HMI/US/portrait/n2t-out/cardGrid.txt | 4 + HMI/US/portrait/n2t-out/cardMedia.txt | 4 + HMI/US/portrait/n2t-out/cardQR.txt | 153 +++- HMI/US/portrait/n2t-out/cardThermo.txt | 4 + HMI/US/portrait/n2t-out/pageStartup.txt | 2 +- HMI/US/portrait/n2t-out/popupLight.txt | 275 ++++++- HMI/US/portrait/n2t-out/popupNotify.txt | 4 + HMI/US/portrait/n2t-out/popupShutter.txt | 4 + 24 files changed, 1726 insertions(+), 968 deletions(-) diff --git a/HMI/US/landscape/diff-eu-version.txt b/HMI/US/landscape/diff-eu-version.txt index 416ec265..241112af 100644 --- a/HMI/US/landscape/diff-eu-version.txt +++ b/HMI/US/landscape/diff-eu-version.txt @@ -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-05-21 14:30:06.481412328 +0000 -+++ HMI/US/landscape/n2t-out/Program.s.txt 2022-05-21 14:30:07.333409902 +0000 +--- HMI/n2t-out/Program.s.txt 2022-05-21 14:37:10.876301404 +0000 ++++ HMI/US/landscape/n2t-out/Program.s.txt 2022-05-21 14:37:11.776302770 +0000 @@ -11,6 +11,4 @@ // dim value int dimValue=40 @@ -9,8 +9,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-05-21 14:30:06.481412328 +0000 -+++ HMI/US/landscape/n2t-out/pageStartup.txt 2022-05-21 14:30:07.337409891 +0000 +--- HMI/n2t-out/pageStartup.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/landscape/n2t-out/pageStartup.txt 2022-05-21 14:37:11.776302770 +0000 @@ -177,7 +177,7 @@ recmod=1 bauds=115200 diff --git a/HMI/US/portrait/diff-eu-version.txt b/HMI/US/portrait/diff-eu-version.txt index 96e4e956..ad5aae42 100644 --- a/HMI/US/portrait/diff-eu-version.txt +++ b/HMI/US/portrait/diff-eu-version.txt @@ -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-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/Program.s.txt 2022-05-21 14:30:06.897411144 +0000 +--- HMI/n2t-out/Program.s.txt 2022-05-21 14:37:10.876301404 +0000 ++++ HMI/US/portrait/n2t-out/Program.s.txt 2022-05-21 14:37:11.312302066 +0000 @@ -11,6 +11,6 @@ // dim value int dimValue=40 @@ -10,23 +10,9 @@ diff -bur HMI/n2t-out/Program.s.txt HMI/US/portrait/n2t-out/Program.s.txt + // fix touch offset (Removed for US version) + //lcd_dev fffb 0002 0000 0020 page pageStartup -diff -bur HMI/n2t-out/cardAlarm.txt HMI/US/portrait/n2t-out/cardAlarm.txt ---- HMI/n2t-out/cardAlarm.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/cardAlarm.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -788,10 +788,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - // end of user code - udelete payloadLength-1 diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt ---- HMI/n2t-out/cardEntities.txt 2022-05-21 14:30:06.485412317 +0000 -+++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-05-21 14:30:06.901411132 +0000 +--- HMI/n2t-out/cardEntities.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-05-21 14:37:11.316302072 +0000 @@ -62,6 +62,16 @@ vis bText4,0 vis hSlider4,0 @@ -311,123 +297,7 @@ diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt Hotspot mSwipeNext Attributes Scope : local -@@ -1277,28 +1505,6 @@ - vis bText1,0 - vis hSlider1,0 - vis nNum1,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tId.txt,"~",8 -- spstr tId.txt,tTmp.txt,"|",0 -- if(tTmp.txt=="0") -- { -- bUp1.pco=27501 -- tsw bUp1,0 -- }else -- { -- bUp1.pco=65535 -- tsw bUp1,1 -- } -- spstr tId.txt,tTmp.txt,"|",1 -- if(tTmp.txt=="0") -- { -- bDown1.pco=27501 -- tsw bDown1,0 -- }else -- { -- bDown1.pco=65535 -- tsw bDown1,1 -- } - } - if(type1.txt=="light") - { -@@ -1421,28 +1627,6 @@ - vis bText2,0 - vis hSlider2,0 - vis nNum2,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tId.txt,"~",14 -- spstr tId.txt,tTmp.txt,"|",0 -- if(tTmp.txt=="0") -- { -- bUp2.pco=27501 -- tsw bUp2,0 -- }else -- { -- bUp2.pco=65535 -- tsw bUp2,1 -- } -- spstr tId.txt,tTmp.txt,"|",1 -- if(tTmp.txt=="0") -- { -- bDown2.pco=27501 -- tsw bDown2,0 -- }else -- { -- bDown2.pco=65535 -- tsw bDown2,1 -- } - } - if(type2.txt=="light") - { -@@ -1565,28 +1749,6 @@ - vis bText3,0 - vis hSlider3,0 - vis nNum3,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tId.txt,"~",20 -- spstr tId.txt,tTmp.txt,"|",0 -- if(tTmp.txt=="0") -- { -- bUp3.pco=27501 -- tsw bUp3,0 -- }else -- { -- bUp3.pco=65535 -- tsw bUp3,1 -- } -- spstr tId.txt,tTmp.txt,"|",1 -- if(tTmp.txt=="0") -- { -- bDown3.pco=27501 -- tsw bDown3,0 -- }else -- { -- bDown3.pco=65535 -- tsw bDown3,1 -- } - } - if(type3.txt=="light") - { -@@ -1709,28 +1871,6 @@ - vis bText4,0 - vis hSlider4,0 - vis nNum4,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tId.txt,"~",26 -- spstr tId.txt,tTmp.txt,"|",0 -- if(tTmp.txt=="0") -- { -- bUp4.pco=27501 -- tsw bUp4,0 -- }else -- { -- bUp4.pco=65535 -- tsw bUp4,1 -- } -- spstr tId.txt,tTmp.txt,"|",1 -- if(tTmp.txt=="0") -- { -- bDown4.pco=27501 -- tsw bDown4,0 -- }else -- { -- bDown4.pco=65535 -- tsw bDown4,1 -- } - } - if(type4.txt=="light") - { -@@ -1816,6 +1956,128 @@ +@@ -1816,6 +2044,150 @@ covx tTmp.txt,sys0,0,0 hSlider4.maxval=sys0 } @@ -468,6 +338,28 @@ diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt + vis bText5,0 + vis hSlider5,0 + vis nNum5,0 ++ // get Button State (optional Value) ++ spstr strCommand.txt,tId.txt,"~",32 ++ spstr tId.txt,tTmp.txt,"|",0 ++ if(tTmp.txt=="0") ++ { ++ bUp5.pco=27501 ++ tsw bUp5,0 ++ }else ++ { ++ bUp5.pco=65535 ++ tsw bUp5,1 ++ } ++ spstr tId.txt,tTmp.txt,"|",1 ++ if(tTmp.txt=="0") ++ { ++ bDown5.pco=27501 ++ tsw bDown5,0 ++ }else ++ { ++ bDown5.pco=65535 ++ tsw bDown5,1 ++ } + } + if(type5.txt=="light") + { @@ -556,85 +448,10 @@ diff -bur HMI/n2t-out/cardEntities.txt HMI/US/portrait/n2t-out/cardEntities.txt } if(tInstruction.txt=="pageType") { -@@ -1871,10 +2133,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - if(tInstruction.txt=="time") - { -diff -bur HMI/n2t-out/cardGrid.txt HMI/US/portrait/n2t-out/cardGrid.txt ---- HMI/n2t-out/cardGrid.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/cardGrid.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -869,10 +869,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - if(tInstruction.txt=="time") - { -diff -bur HMI/n2t-out/cardMedia.txt HMI/US/portrait/n2t-out/cardMedia.txt ---- HMI/n2t-out/cardMedia.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/cardMedia.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -740,10 +740,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - // end of user code - udelete payloadLength-1 diff -bur HMI/n2t-out/cardQR.txt HMI/US/portrait/n2t-out/cardQR.txt ---- HMI/n2t-out/cardQR.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/cardQR.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -19,16 +19,6 @@ - vis tId,0 - vis bPrev,0 - vis bNext,0 -- //ui e1 -- vis btOnOff1,0 -- vis tIcon1,0 -- vis tEntity1,0 -- vis bText1,0 -- //ui e2 -- vis btOnOff2,0 -- vis tIcon2,0 -- vis tEntity2,0 -- vis bText2,0 - - Variable (string) strCommand - Attributes -@@ -78,18 +68,6 @@ - Text : - Max. Text Size: 80 - --Variable (string) type1 -- Attributes -- Scope : local -- Text : -- Max. Text Size: 10 -- --Variable (string) type2 -- Attributes -- Scope : local -- Text : -- Max. Text Size: 10 -- - Text tEntity1 - Attributes - Scope : local -@@ -137,7 +115,7 @@ +--- HMI/n2t-out/cardQR.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/portrait/n2t-out/cardQR.txt 2022-05-21 14:37:11.316302072 +0000 +@@ -137,7 +137,7 @@ Disable release event after dragging: 0 Send Component ID : disabled Associated Keyboard : none @@ -643,7 +460,7 @@ diff -bur HMI/n2t-out/cardQR.txt HMI/US/portrait/n2t-out/cardQR.txt Max. Text Size : 40 Picture p0 -@@ -153,7 +131,7 @@ +@@ -153,7 +153,7 @@ Dragging : 0 Disable release event after dragging: 0 Send Component ID : disabled @@ -652,175 +469,9 @@ diff -bur HMI/n2t-out/cardQR.txt HMI/US/portrait/n2t-out/cardQR.txt Max. Text Size : 105 Button bNext -@@ -454,9 +432,8 @@ - spstr strCommand.txt,tInstruction.txt,"~",0 - if(tInstruction.txt=="entityUpd") - { -- // command format: entityUpd,heading,navigation,textQR[,type,internalName,iconId,displayName,optionalValue]x2 -- //tHeading -- spstr strCommand.txt,tHeading.txt,"~",1 -+ //entn -+ spstr strCommand.txt,entn.txt,"~",1 - // navigation icons - spstr strCommand.txt,tId.txt,"~",2 - spstr tId.txt,tTmp.txt,"|",0 -@@ -486,128 +463,6 @@ - } - //text qrcode - spstr strCommand.txt,qr0.txt,"~",3 -- // get Type -- spstr strCommand.txt,type1.txt,"~",4 -- // get internal name -- spstr strCommand.txt,entn1.txt,"~",5 -- if(type1.txt=="delete"||type1.txt=="") -- { -- vis btOnOff1,0 -- vis tEntity1,0 -- vis tIcon1,0 -- vis bText1,0 -- }else -- { -- // change icon -- spstr strCommand.txt,tIcon1.txt,"~",6 -- vis tIcon1,1 -- // change icon color -- spstr strCommand.txt,tTmp.txt,"~",7 -- covx tTmp.txt,sys0,0,0 -- tIcon1.pco=sys0 -- // set name -- spstr strCommand.txt,tEntity1.txt,"~",8 -- vis tEntity1,1 -- } -- if(type1.txt=="light") -- { -- vis btOnOff1,1 -- vis bText1,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tTmp.txt,"~",9 -- covx tTmp.txt,sys0,0,0 -- btOnOff1.val=sys0 -- } -- if(type1.txt=="switch") -- { -- vis btOnOff1,1 -- vis bText1,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tTmp.txt,"~",9 -- covx tTmp.txt,sys0,0,0 -- btOnOff1.val=sys0 -- } -- if(type1.txt=="text") -- { -- vis btOnOff1,0 -- vis bText1,1 -- tsw bText1,0 -- bText1.pco=65535 -- bText1.pco2=65535 -- // get Text (optional Value) -- spstr strCommand.txt,bText1.txt,"~",9 -- } -- if(type1.txt=="button") -- { -- vis btOnOff1,0 -- vis bText1,1 -- tsw bText1,1 -- bText1.pco=1374 -- bText1.pco2=1374 -- // get Text (optional Value) -- spstr strCommand.txt,bText1.txt,"~",9 -- } -- // get Type -- spstr strCommand.txt,type2.txt,"~",10 -- // get internal name -- spstr strCommand.txt,entn2.txt,"~",11 -- if(type2.txt=="delete"||type2.txt=="") -- { -- vis btOnOff2,0 -- vis tEntity2,0 -- vis tIcon2,0 -- vis bText2,0 -- }else -- { -- // change icon -- spstr strCommand.txt,tIcon2.txt,"~",12 -- vis tIcon2,1 -- // change icon color -- spstr strCommand.txt,tTmp.txt,"~",13 -- covx tTmp.txt,sys0,0,0 -- tIcon2.pco=sys0 -- // set name -- spstr strCommand.txt,tEntity2.txt,"~",14 -- vis tEntity2,1 -- } -- if(type2.txt=="light") -- { -- vis btOnOff2,1 -- vis bText2,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tTmp.txt,"~",15 -- covx tTmp.txt,sys0,0,0 -- btOnOff2.val=sys0 -- } -- if(type2.txt=="switch") -- { -- vis btOnOff2,1 -- vis bText2,0 -- // get Button State (optional Value) -- spstr strCommand.txt,tTmp.txt,"~",15 -- covx tTmp.txt,sys0,0,0 -- btOnOff2.val=sys0 -- } -- if(type2.txt=="text") -- { -- vis btOnOff2,0 -- vis bText2,1 -- tsw bText2,0 -- bText2.pco=65535 -- bText2.pco2=65535 -- // get Text (optional Value) -- spstr strCommand.txt,bText2.txt,"~",15 -- } -- if(type2.txt=="button") -- { -- vis btOnOff2,0 -- vis bText2,1 -- tsw bText2,1 -- bText2.pco=1374 -- bText2.pco2=1374 -- // get Text (optional Value) -- spstr strCommand.txt,bText2.txt,"~",15 -- } - } - if(tInstruction.txt=="time") - { -@@ -686,10 +541,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - // end of user code - udelete payloadLength-1 -diff -bur HMI/n2t-out/cardThermo.txt HMI/US/portrait/n2t-out/cardThermo.txt ---- HMI/n2t-out/cardThermo.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/cardThermo.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -1192,10 +1192,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - if(tInstruction.txt=="time") - { diff -bur HMI/n2t-out/pageStartup.txt HMI/US/portrait/n2t-out/pageStartup.txt ---- HMI/n2t-out/pageStartup.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-05-21 14:30:06.897411144 +0000 +--- HMI/n2t-out/pageStartup.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-05-21 14:37:11.312302066 +0000 @@ -142,7 +142,7 @@ Disable release event after dragging: 0 Send Component ID : disabled @@ -830,15 +481,6 @@ diff -bur HMI/n2t-out/pageStartup.txt HMI/US/portrait/n2t-out/pageStartup.txt Max. Text Size : 100 Text tVersion -@@ -152,7 +152,7 @@ - Disable release event after dragging: 0 - Send Component ID : disabled - Associated Keyboard : none -- Text : 35 -+ Text : 34 - Max. Text Size : 10 - - Picture p0 @@ -177,7 +177,7 @@ recmod=1 bauds=115200 @@ -860,37 +502,285 @@ diff -bur HMI/n2t-out/pageStartup.txt HMI/US/portrait/n2t-out/pageStartup.txt // end of user code udelete payloadLength-1 diff -bur HMI/n2t-out/popupLight.txt HMI/US/portrait/n2t-out/popupLight.txt ---- HMI/n2t-out/popupLight.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/popupLight.txt 2022-05-21 14:30:06.901411132 +0000 -@@ -618,10 +618,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - // end of user code - udelete payloadLength-1 -diff -bur HMI/n2t-out/popupNotify.txt HMI/US/portrait/n2t-out/popupNotify.txt ---- HMI/n2t-out/popupNotify.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/popupNotify.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -381,10 +381,6 @@ - { - page cardAlarm - } -- if(tId.txt=="cardQR") -- { -- page cardQR -- } - } - // end of user code - udelete payloadLength-1 -diff -bur HMI/n2t-out/popupShutter.txt HMI/US/portrait/n2t-out/popupShutter.txt ---- HMI/n2t-out/popupShutter.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/popupShutter.txt 2022-05-21 14:30:06.897411144 +0000 -@@ -422,10 +422,6 @@ +--- HMI/n2t-out/popupLight.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/portrait/n2t-out/popupLight.txt 2022-05-21 14:37:11.312302066 +0000 +@@ -12,43 +12,244 @@ + + Events + Preinitialize Event +- //get entitiy name +- tEntity.txt=pageIcons.tTmp1.txt +- //get entity id +- entn.txt=pageIcons.tTmp2.txt +- vis p0,0 +- vis tSend,0 +- vis tTmp,0 +- vis tInstruction,0 +- vis tId,0 +- //page open event +- // event,pageOpenDetail,typeOfPage,tEntityName +- // craft command +- tSend.txt="event,pageOpenDetail,popupLight,"+entn.txt +- //send calc crc +- btlen tSend.txt,sys0 +- crcrest 1,0xffff // reset CRC +- crcputh 55 bb +- crcputs sys0,2 +- crcputs tSend.txt,0 +- //send cmd +- printh 55 bb +- prints sys0,2 +- prints tSend.txt,0 +- prints crcval,2 +- //disable brightness by default ++ // data available ++ if(usize>1) ++ { ++ bufferPos=0 ++ while(bufferPos isn't supported ++ if(tTmp.txt=="disable") ++ { + vis t0,0 ++ vis bColor,0 + vis pColorWheel,0 +- //vis t0,0 ++ }else ++ { ++ vis t0,1 ++ //only enable bColor button if color temp is also supported ++ if(mode_temp.val==1) ++ { ++ vis bColor,1 ++ } ++ if(mode.val==0) ++ { ++ vis pColorWheel,1 ++ } ++ } ++ // set t0 Color (Localization) ++ spstr strCommand.txt,t0.txt,"~",7 ++ // set t4 Temperature (Localization) ++ spstr strCommand.txt,t4.txt,"~",8 ++ // set t1 Brightness (Localization) ++ spstr strCommand.txt,t1.txt,"~",9 ++ } ++ if(tInstruction.txt=="time") ++ { ++ // get set time to global variable ++ spstr strCommand.txt,pageIcons.vaTime.txt,"~",1 ++ } ++ if(tInstruction.txt=="date") ++ { ++ // get set date to global variable ++ spstr strCommand.txt,pageIcons.vaDate.txt,"~",1 ++ } ++ if(tInstruction.txt=="dimmode") ++ { ++ // get value ++ spstr strCommand.txt,tTmp.txt,"~",1 ++ covx tTmp.txt,dimValue,0,0 ++ } ++ if(tInstruction.txt=="timeout") ++ { ++ //set timeout to global var ++ spstr strCommand.txt,tTmp.txt,"~",1 ++ covx tTmp.txt,sleepTimeout,0,0 ++ } ++ if(tInstruction.txt=="pageType") ++ { ++ //command format pageType,specialPageName ++ //write name of speical page to tId ++ spstr strCommand.txt,tId.txt,"~",1 ++ //save second arg if there's one ++ spstr strCommand.txt,tTmp.txt,"~",2 ++ //save third arg if there's one ++ spstr strCommand.txt,pageIcons.tTmp2.txt,"~",3 ++ //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=="pageStartup") ++ { ++ page pageStartup ++ } ++ if(tId.txt=="screensaver") ++ { ++ page screensaver ++ } ++ if(tId.txt=="cardEntities") ++ { ++ page cardEntities ++ } ++ if(tId.txt=="cardGrid") ++ { ++ page cardGrid ++ } ++ if(tId.txt=="popupLight") ++ { ++ 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=="cardThermo") ++ { ++ page cardThermo ++ } ++ if(tId.txt=="cardMedia") ++ { ++ page cardMedia ++ } ++ if(tId.txt=="cardAlarm") ++ { ++ page cardAlarm ++ } ++ if(tId.txt=="cardQR") ++ { ++ page cardQR ++ } ++ } ++ // end of user code ++ udelete payloadLength-1 ++ bufferPos=0 ++ } ++ } ++ } ++ } ++ // next character ++ bufferPos++ ++ } ++ } + + Variable (string) strCommand + Attributes +@@ -618,10 +819,6 @@ { page cardAlarm } @@ -902,8 +792,8 @@ diff -bur HMI/n2t-out/popupShutter.txt HMI/US/portrait/n2t-out/popupShutter.txt // end of user code udelete payloadLength-1 diff -bur HMI/n2t-out/screensaver.txt HMI/US/portrait/n2t-out/screensaver.txt ---- HMI/n2t-out/screensaver.txt 2022-05-21 14:30:06.481412328 +0000 -+++ HMI/US/portrait/n2t-out/screensaver.txt 2022-05-21 14:30:06.897411144 +0000 +--- HMI/n2t-out/screensaver.txt 2022-05-21 14:37:10.880301410 +0000 ++++ HMI/US/portrait/n2t-out/screensaver.txt 2022-05-21 14:37:11.316302072 +0000 @@ -607,10 +607,6 @@ { page cardAlarm diff --git a/HMI/US/portrait/diff-filtered.txt b/HMI/US/portrait/diff-filtered.txt index 8a011e23..a3a1a3ba 100644 --- a/HMI/US/portrait/diff-filtered.txt +++ b/HMI/US/portrait/diff-filtered.txt @@ -1,220 +1,37 @@ -+++ HMI/US/portrait/diff-eu-version.txt 2022-05-21 14:30:06.913411098 +0000 -+--- HMI/n2t-out/Program.s.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/Program.s.txt 2022-05-21 14:30:06.897411144 +0000 -+diff -bur HMI/n2t-out/cardAlarm.txt HMI/US/portrait/n2t-out/cardAlarm.txt -+--- HMI/n2t-out/cardAlarm.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/cardAlarm.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -788,10 +788,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ // end of user code -+ udelete payloadLength-1 -+--- HMI/n2t-out/cardEntities.txt 2022-05-21 14:30:06.485412317 +0000 -++++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-05-21 14:30:06.901411132 +0000 ++++ HMI/US/portrait/diff-eu-version.txt 2022-05-21 14:37:11.332302096 +0000 ++--- HMI/n2t-out/Program.s.txt 2022-05-21 14:37:10.876301404 +0000 +++++ HMI/US/portrait/n2t-out/Program.s.txt 2022-05-21 14:37:11.312302066 +0000 ++--- HMI/n2t-out/cardEntities.txt 2022-05-21 14:37:10.880301410 +0000 +++++ HMI/US/portrait/n2t-out/cardEntities.txt 2022-05-21 14:37:11.316302072 +0000 + Hotspot mSwipeNext + Scope : local -+@@ -1277,28 +1505,6 @@ -+ vis bText1,0 -+ vis hSlider1,0 -+ vis nNum1,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tId.txt,"~",8 -+- spstr tId.txt,tTmp.txt,"|",0 -+- if(tTmp.txt=="0") -+- { -+- bUp1.pco=27501 -+- tsw bUp1,0 -+- }else -+- { -+- bUp1.pco=65535 -+- tsw bUp1,1 -+- } -+- spstr tId.txt,tTmp.txt,"|",1 -+- if(tTmp.txt=="0") -+- { -+- bDown1.pco=27501 -+- tsw bDown1,0 -+- }else -+- { -+- bDown1.pco=65535 -+- tsw bDown1,1 -+- } -+ } -+ if(type1.txt=="light") -+ { -+@@ -1421,28 +1627,6 @@ -+ vis bText2,0 -+ vis hSlider2,0 -+ vis nNum2,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tId.txt,"~",14 -+- spstr tId.txt,tTmp.txt,"|",0 -+- if(tTmp.txt=="0") -+- { -+- bUp2.pco=27501 -+- tsw bUp2,0 -+- }else -+- { -+- bUp2.pco=65535 -+- tsw bUp2,1 -+- } -+- spstr tId.txt,tTmp.txt,"|",1 -+- if(tTmp.txt=="0") -+- { -+- bDown2.pco=27501 -+- tsw bDown2,0 -+- }else -+- { -+- bDown2.pco=65535 -+- tsw bDown2,1 -+- } -+ } -+ if(type2.txt=="light") -+ { -+@@ -1565,28 +1749,6 @@ -+ vis bText3,0 -+ vis hSlider3,0 -+ vis nNum3,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tId.txt,"~",20 -+- spstr tId.txt,tTmp.txt,"|",0 -+- if(tTmp.txt=="0") -+- { -+- bUp3.pco=27501 -+- tsw bUp3,0 -+- }else -+- { -+- bUp3.pco=65535 -+- tsw bUp3,1 -+- } -+- spstr tId.txt,tTmp.txt,"|",1 -+- if(tTmp.txt=="0") -+- { -+- bDown3.pco=27501 -+- tsw bDown3,0 -+- }else -+- { -+- bDown3.pco=65535 -+- tsw bDown3,1 -+- } -+ } -+ if(type3.txt=="light") -+ { -+@@ -1709,28 +1871,6 @@ -+ vis bText4,0 -+ vis hSlider4,0 -+ vis nNum4,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tId.txt,"~",26 -+- spstr tId.txt,tTmp.txt,"|",0 -+- if(tTmp.txt=="0") -+- { -+- bUp4.pco=27501 -+- tsw bUp4,0 -+- }else -+- { -+- bUp4.pco=65535 -+- tsw bUp4,1 -+- } -+- spstr tId.txt,tTmp.txt,"|",1 -+- if(tTmp.txt=="0") -+- { -+- bDown4.pco=27501 -+- tsw bDown4,0 -+- }else -+- { -+- bDown4.pco=65535 -+- tsw bDown4,1 -+- } -+ } -+ if(type4.txt=="light") -+ { -+@@ -1816,6 +1956,128 @@ -+@@ -1871,10 +2133,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ if(tInstruction.txt=="time") -+ { -+diff -bur HMI/n2t-out/cardGrid.txt HMI/US/portrait/n2t-out/cardGrid.txt -+--- HMI/n2t-out/cardGrid.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/cardGrid.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -869,10 +869,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ if(tInstruction.txt=="time") -+ { -+diff -bur HMI/n2t-out/cardMedia.txt HMI/US/portrait/n2t-out/cardMedia.txt -+--- HMI/n2t-out/cardMedia.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/cardMedia.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -740,10 +740,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ // end of user code -+ udelete payloadLength-1 ++@@ -1816,6 +2044,150 @@ +++ // get Button State (optional Value) +++ spstr strCommand.txt,tId.txt,"~",32 +++ spstr tId.txt,tTmp.txt,"|",0 +++ if(tTmp.txt=="0") +++ { +++ bUp5.pco=27501 +++ tsw bUp5,0 +++ }else +++ { +++ bUp5.pco=65535 +++ tsw bUp5,1 +++ } +++ spstr tId.txt,tTmp.txt,"|",1 +++ if(tTmp.txt=="0") +++ { +++ bDown5.pco=27501 +++ tsw bDown5,0 +++ }else +++ { +++ bDown5.pco=65535 +++ tsw bDown5,1 +++ } +diff -bur HMI/n2t-out/cardQR.txt HMI/US/portrait/n2t-out/cardQR.txt -+--- HMI/n2t-out/cardQR.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/cardQR.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -19,16 +19,6 @@ -+ vis tId,0 -+ vis bPrev,0 -+ vis bNext,0 -+- //ui e1 -+- vis btOnOff1,0 -+- vis tIcon1,0 -+- vis tEntity1,0 -+- vis bText1,0 -+- //ui e2 -+- vis btOnOff2,0 -+- vis tIcon2,0 -+- vis tEntity2,0 -+- vis bText2,0 -+ -+ Variable (string) strCommand -+ Attributes -+@@ -78,18 +68,6 @@ -+ Text : -+ Max. Text Size: 80 -+ -+-Variable (string) type1 -+- Attributes -+- Scope : local -+- Text : -+- Max. Text Size: 10 -+- -+-Variable (string) type2 -+- Attributes -+- Scope : local -+- Text : -+- Max. Text Size: 10 -+- -+ Text tEntity1 -+ Attributes -+ Scope : local -+@@ -137,7 +115,7 @@ ++--- HMI/n2t-out/cardQR.txt 2022-05-21 14:37:10.880301410 +0000 +++++ HMI/US/portrait/n2t-out/cardQR.txt 2022-05-21 14:37:11.316302072 +0000 ++@@ -137,7 +137,7 @@ + Disable release event after dragging: 0 + Send Component ID : disabled + Associated Keyboard : none @@ -223,7 +40,7 @@ + Max. Text Size : 40 + + Picture p0 -+@@ -153,7 +131,7 @@ ++@@ -153,7 +153,7 @@ + Dragging : 0 + Disable release event after dragging: 0 + Send Component ID : disabled @@ -232,183 +49,8 @@ + Max. Text Size : 105 + + Button bNext -+@@ -454,9 +432,8 @@ -+ spstr strCommand.txt,tInstruction.txt,"~",0 -+ if(tInstruction.txt=="entityUpd") -+ { -+- // command format: entityUpd,heading,navigation,textQR[,type,internalName,iconId,displayName,optionalValue]x2 -+- //tHeading -+- spstr strCommand.txt,tHeading.txt,"~",1 -++ //entn -++ spstr strCommand.txt,entn.txt,"~",1 -+ // navigation icons -+ spstr strCommand.txt,tId.txt,"~",2 -+ spstr tId.txt,tTmp.txt,"|",0 -+@@ -486,128 +463,6 @@ -+ } -+ //text qrcode -+ spstr strCommand.txt,qr0.txt,"~",3 -+- // get Type -+- spstr strCommand.txt,type1.txt,"~",4 -+- // get internal name -+- spstr strCommand.txt,entn1.txt,"~",5 -+- if(type1.txt=="delete"||type1.txt=="") -+- { -+- vis btOnOff1,0 -+- vis tEntity1,0 -+- vis tIcon1,0 -+- vis bText1,0 -+- }else -+- { -+- // change icon -+- spstr strCommand.txt,tIcon1.txt,"~",6 -+- vis tIcon1,1 -+- // change icon color -+- spstr strCommand.txt,tTmp.txt,"~",7 -+- covx tTmp.txt,sys0,0,0 -+- tIcon1.pco=sys0 -+- // set name -+- spstr strCommand.txt,tEntity1.txt,"~",8 -+- vis tEntity1,1 -+- } -+- if(type1.txt=="light") -+- { -+- vis btOnOff1,1 -+- vis bText1,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tTmp.txt,"~",9 -+- covx tTmp.txt,sys0,0,0 -+- btOnOff1.val=sys0 -+- } -+- if(type1.txt=="switch") -+- { -+- vis btOnOff1,1 -+- vis bText1,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tTmp.txt,"~",9 -+- covx tTmp.txt,sys0,0,0 -+- btOnOff1.val=sys0 -+- } -+- if(type1.txt=="text") -+- { -+- vis btOnOff1,0 -+- vis bText1,1 -+- tsw bText1,0 -+- bText1.pco=65535 -+- bText1.pco2=65535 -+- // get Text (optional Value) -+- spstr strCommand.txt,bText1.txt,"~",9 -+- } -+- if(type1.txt=="button") -+- { -+- vis btOnOff1,0 -+- vis bText1,1 -+- tsw bText1,1 -+- bText1.pco=1374 -+- bText1.pco2=1374 -+- // get Text (optional Value) -+- spstr strCommand.txt,bText1.txt,"~",9 -+- } -+- // get Type -+- spstr strCommand.txt,type2.txt,"~",10 -+- // get internal name -+- spstr strCommand.txt,entn2.txt,"~",11 -+- if(type2.txt=="delete"||type2.txt=="") -+- { -+- vis btOnOff2,0 -+- vis tEntity2,0 -+- vis tIcon2,0 -+- vis bText2,0 -+- }else -+- { -+- // change icon -+- spstr strCommand.txt,tIcon2.txt,"~",12 -+- vis tIcon2,1 -+- // change icon color -+- spstr strCommand.txt,tTmp.txt,"~",13 -+- covx tTmp.txt,sys0,0,0 -+- tIcon2.pco=sys0 -+- // set name -+- spstr strCommand.txt,tEntity2.txt,"~",14 -+- vis tEntity2,1 -+- } -+- if(type2.txt=="light") -+- { -+- vis btOnOff2,1 -+- vis bText2,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tTmp.txt,"~",15 -+- covx tTmp.txt,sys0,0,0 -+- btOnOff2.val=sys0 -+- } -+- if(type2.txt=="switch") -+- { -+- vis btOnOff2,1 -+- vis bText2,0 -+- // get Button State (optional Value) -+- spstr strCommand.txt,tTmp.txt,"~",15 -+- covx tTmp.txt,sys0,0,0 -+- btOnOff2.val=sys0 -+- } -+- if(type2.txt=="text") -+- { -+- vis btOnOff2,0 -+- vis bText2,1 -+- tsw bText2,0 -+- bText2.pco=65535 -+- bText2.pco2=65535 -+- // get Text (optional Value) -+- spstr strCommand.txt,bText2.txt,"~",15 -+- } -+- if(type2.txt=="button") -+- { -+- vis btOnOff2,0 -+- vis bText2,1 -+- tsw bText2,1 -+- bText2.pco=1374 -+- bText2.pco2=1374 -+- // get Text (optional Value) -+- spstr strCommand.txt,bText2.txt,"~",15 -+- } -+ } -+ if(tInstruction.txt=="time") -+ { -+@@ -686,10 +541,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ // end of user code -+ udelete payloadLength-1 -+diff -bur HMI/n2t-out/cardThermo.txt HMI/US/portrait/n2t-out/cardThermo.txt -+--- HMI/n2t-out/cardThermo.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/cardThermo.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -1192,10 +1192,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ if(tInstruction.txt=="time") -+ { -+--- HMI/n2t-out/pageStartup.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -152,7 +152,7 @@ -+ Disable release event after dragging: 0 -+ Send Component ID : disabled -+ Associated Keyboard : none -+- Text : 35 -++ Text : 34 -+ Max. Text Size : 10 -+ -+ Picture p0 ++--- HMI/n2t-out/pageStartup.txt 2022-05-21 14:37:10.880301410 +0000 +++++ HMI/US/portrait/n2t-out/pageStartup.txt 2022-05-21 14:37:11.312302066 +0000 +@@ -330,10 +330,6 @@ + { + page cardAlarm @@ -421,37 +63,285 @@ + // end of user code + udelete payloadLength-1 +diff -bur HMI/n2t-out/popupLight.txt HMI/US/portrait/n2t-out/popupLight.txt -+--- HMI/n2t-out/popupLight.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/popupLight.txt 2022-05-21 14:30:06.901411132 +0000 -+@@ -618,10 +618,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ // end of user code -+ udelete payloadLength-1 -+diff -bur HMI/n2t-out/popupNotify.txt HMI/US/portrait/n2t-out/popupNotify.txt -+--- HMI/n2t-out/popupNotify.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/popupNotify.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -381,10 +381,6 @@ -+ { -+ page cardAlarm -+ } -+- if(tId.txt=="cardQR") -+- { -+- page cardQR -+- } -+ } -+ // end of user code -+ udelete payloadLength-1 -+diff -bur HMI/n2t-out/popupShutter.txt HMI/US/portrait/n2t-out/popupShutter.txt -+--- HMI/n2t-out/popupShutter.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/popupShutter.txt 2022-05-21 14:30:06.897411144 +0000 -+@@ -422,10 +422,6 @@ ++--- HMI/n2t-out/popupLight.txt 2022-05-21 14:37:10.880301410 +0000 +++++ HMI/US/portrait/n2t-out/popupLight.txt 2022-05-21 14:37:11.312302066 +0000 ++@@ -12,43 +12,244 @@ ++ ++ Events ++ Preinitialize Event ++- //get entitiy name ++- tEntity.txt=pageIcons.tTmp1.txt ++- //get entity id ++- entn.txt=pageIcons.tTmp2.txt ++- vis p0,0 ++- vis tSend,0 ++- vis tTmp,0 ++- vis tInstruction,0 ++- vis tId,0 ++- //page open event ++- // event,pageOpenDetail,typeOfPage,tEntityName ++- // craft command ++- tSend.txt="event,pageOpenDetail,popupLight,"+entn.txt ++- //send calc crc ++- btlen tSend.txt,sys0 ++- crcrest 1,0xffff // reset CRC ++- crcputh 55 bb ++- crcputs sys0,2 ++- crcputs tSend.txt,0 ++- //send cmd ++- printh 55 bb ++- prints sys0,2 ++- prints tSend.txt,0 ++- prints crcval,2 ++- //disable brightness by default +++ // data available +++ if(usize>1) +++ { +++ bufferPos=0 +++ while(bufferPos isn't supported +++ if(tTmp.txt=="disable") +++ { ++ vis t0,0 +++ vis bColor,0 ++ vis pColorWheel,0 ++- //vis t0,0 +++ }else +++ { +++ vis t0,1 +++ //only enable bColor button if color temp is also supported +++ if(mode_temp.val==1) +++ { +++ vis bColor,1 +++ } +++ if(mode.val==0) +++ { +++ vis pColorWheel,1 +++ } +++ } +++ // set t0 Color (Localization) +++ spstr strCommand.txt,t0.txt,"~",7 +++ // set t4 Temperature (Localization) +++ spstr strCommand.txt,t4.txt,"~",8 +++ // set t1 Brightness (Localization) +++ spstr strCommand.txt,t1.txt,"~",9 +++ } +++ if(tInstruction.txt=="time") +++ { +++ // get set time to global variable +++ spstr strCommand.txt,pageIcons.vaTime.txt,"~",1 +++ } +++ if(tInstruction.txt=="date") +++ { +++ // get set date to global variable +++ spstr strCommand.txt,pageIcons.vaDate.txt,"~",1 +++ } +++ if(tInstruction.txt=="dimmode") +++ { +++ // get value +++ spstr strCommand.txt,tTmp.txt,"~",1 +++ covx tTmp.txt,dimValue,0,0 +++ } +++ if(tInstruction.txt=="timeout") +++ { +++ //set timeout to global var +++ spstr strCommand.txt,tTmp.txt,"~",1 +++ covx tTmp.txt,sleepTimeout,0,0 +++ } +++ if(tInstruction.txt=="pageType") +++ { +++ //command format pageType,specialPageName +++ //write name of speical page to tId +++ spstr strCommand.txt,tId.txt,"~",1 +++ //save second arg if there's one +++ spstr strCommand.txt,tTmp.txt,"~",2 +++ //save third arg if there's one +++ spstr strCommand.txt,pageIcons.tTmp2.txt,"~",3 +++ //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=="pageStartup") +++ { +++ page pageStartup +++ } +++ if(tId.txt=="screensaver") +++ { +++ page screensaver +++ } +++ if(tId.txt=="cardEntities") +++ { +++ page cardEntities +++ } +++ if(tId.txt=="cardGrid") +++ { +++ page cardGrid +++ } +++ if(tId.txt=="popupLight") +++ { +++ 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=="cardThermo") +++ { +++ page cardThermo +++ } +++ if(tId.txt=="cardMedia") +++ { +++ page cardMedia +++ } +++ if(tId.txt=="cardAlarm") +++ { +++ page cardAlarm +++ } +++ if(tId.txt=="cardQR") +++ { +++ page cardQR +++ } +++ } +++ // end of user code +++ udelete payloadLength-1 +++ bufferPos=0 +++ } +++ } +++ } +++ } +++ // next character +++ bufferPos++ +++ } +++ } ++ ++ Variable (string) strCommand ++ Attributes ++@@ -618,10 +819,6 @@ + { + page cardAlarm + } @@ -463,8 +353,8 @@ + // end of user code + udelete payloadLength-1 +diff -bur HMI/n2t-out/screensaver.txt HMI/US/portrait/n2t-out/screensaver.txt -+--- HMI/n2t-out/screensaver.txt 2022-05-21 14:30:06.481412328 +0000 -++++ HMI/US/portrait/n2t-out/screensaver.txt 2022-05-21 14:30:06.897411144 +0000 ++--- HMI/n2t-out/screensaver.txt 2022-05-21 14:37:10.880301410 +0000 +++++ HMI/US/portrait/n2t-out/screensaver.txt 2022-05-21 14:37:11.316302072 +0000 +@@ -607,10 +607,6 @@ + { + page cardAlarm diff --git a/HMI/US/portrait/n2t-out-visual/cardAlarm.txt b/HMI/US/portrait/n2t-out-visual/cardAlarm.txt index c8db2d3b..b25bdace 100644 --- a/HMI/US/portrait/n2t-out-visual/cardAlarm.txt +++ b/HMI/US/portrait/n2t-out-visual/cardAlarm.txt @@ -1345,6 +1345,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out-visual/cardEntities.txt b/HMI/US/portrait/n2t-out-visual/cardEntities.txt index b5f8a180..0a423321 100644 --- a/HMI/US/portrait/n2t-out-visual/cardEntities.txt +++ b/HMI/US/portrait/n2t-out-visual/cardEntities.txt @@ -2670,6 +2670,28 @@ Timer tmSerial vis bText1,0 vis hSlider1,0 vis nNum1,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",8 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp1.pco=27501 + tsw bUp1,0 + }else + { + bUp1.pco=65535 + tsw bUp1,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown1.pco=27501 + tsw bDown1,0 + }else + { + bDown1.pco=65535 + tsw bDown1,1 + } } if(type1.txt=="light") { @@ -2792,6 +2814,28 @@ Timer tmSerial vis bText2,0 vis hSlider2,0 vis nNum2,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",14 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp2.pco=27501 + tsw bUp2,0 + }else + { + bUp2.pco=65535 + tsw bUp2,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown2.pco=27501 + tsw bDown2,0 + }else + { + bDown2.pco=65535 + tsw bDown2,1 + } } if(type2.txt=="light") { @@ -2914,6 +2958,28 @@ Timer tmSerial vis bText3,0 vis hSlider3,0 vis nNum3,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",20 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp3.pco=27501 + tsw bUp3,0 + }else + { + bUp3.pco=65535 + tsw bUp3,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown3.pco=27501 + tsw bDown3,0 + }else + { + bDown3.pco=65535 + tsw bDown3,1 + } } if(type3.txt=="light") { @@ -3036,6 +3102,28 @@ Timer tmSerial vis bText4,0 vis hSlider4,0 vis nNum4,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",26 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp4.pco=27501 + tsw bUp4,0 + }else + { + bUp4.pco=65535 + tsw bUp4,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown4.pco=27501 + tsw bDown4,0 + }else + { + bDown4.pco=65535 + tsw bDown4,1 + } } if(type4.txt=="light") { @@ -3158,6 +3246,28 @@ Timer tmSerial vis bText5,0 vis hSlider5,0 vis nNum5,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",32 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp5.pco=27501 + tsw bUp5,0 + }else + { + bUp5.pco=65535 + tsw bUp5,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown5.pco=27501 + tsw bDown5,0 + }else + { + bDown5.pco=65535 + tsw bDown5,1 + } } if(type5.txt=="light") { @@ -3298,6 +3408,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out-visual/cardGrid.txt b/HMI/US/portrait/n2t-out-visual/cardGrid.txt index f7c2a06c..fd9109c9 100644 --- a/HMI/US/portrait/n2t-out-visual/cardGrid.txt +++ b/HMI/US/portrait/n2t-out-visual/cardGrid.txt @@ -1333,6 +1333,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out-visual/cardMedia.txt b/HMI/US/portrait/n2t-out-visual/cardMedia.txt index 7562c0ad..5a041859 100644 --- a/HMI/US/portrait/n2t-out-visual/cardMedia.txt +++ b/HMI/US/portrait/n2t-out-visual/cardMedia.txt @@ -1189,6 +1189,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out-visual/cardQR.txt b/HMI/US/portrait/n2t-out-visual/cardQR.txt index 6a60c504..0257ab9a 100644 --- a/HMI/US/portrait/n2t-out-visual/cardQR.txt +++ b/HMI/US/portrait/n2t-out-visual/cardQR.txt @@ -27,6 +27,16 @@ Page cardQR vis tId,0 vis bPrev,0 vis bNext,0 + //ui e1 + vis btOnOff1,0 + vis tIcon1,0 + vis tEntity1,0 + vis bText1,0 + //ui e2 + vis btOnOff2,0 + vis tIcon2,0 + vis tEntity2,0 + vis bText2,0 Variable (string) strCommand Attributes @@ -84,6 +94,20 @@ Variable (string) entn2 Text : Max. Text Size: 80 +Variable (string) type1 + Attributes + ID : 28 + Scope : local + Text : + Max. Text Size: 10 + +Variable (string) type2 + Attributes + ID : 29 + Scope : local + Text : + Max. Text Size: 10 + Text tEntity1 Attributes ID : 15 @@ -720,8 +744,9 @@ Timer tmSerial spstr strCommand.txt,tInstruction.txt,"~",0 if(tInstruction.txt=="entityUpd") { - //entn - spstr strCommand.txt,entn.txt,"~",1 + // command format: entityUpd,heading,navigation,textQR[,type,internalName,iconId,displayName,optionalValue]x2 + //tHeading + spstr strCommand.txt,tHeading.txt,"~",1 // navigation icons spstr strCommand.txt,tId.txt,"~",2 spstr tId.txt,tTmp.txt,"|",0 @@ -751,6 +776,128 @@ Timer tmSerial } //text qrcode spstr strCommand.txt,qr0.txt,"~",3 + // get Type + spstr strCommand.txt,type1.txt,"~",4 + // get internal name + spstr strCommand.txt,entn1.txt,"~",5 + if(type1.txt=="delete"||type1.txt=="") + { + vis btOnOff1,0 + vis tEntity1,0 + vis tIcon1,0 + vis bText1,0 + }else + { + // change icon + spstr strCommand.txt,tIcon1.txt,"~",6 + vis tIcon1,1 + // change icon color + spstr strCommand.txt,tTmp.txt,"~",7 + covx tTmp.txt,sys0,0,0 + tIcon1.pco=sys0 + // set name + spstr strCommand.txt,tEntity1.txt,"~",8 + vis tEntity1,1 + } + if(type1.txt=="light") + { + vis btOnOff1,1 + vis bText1,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",9 + covx tTmp.txt,sys0,0,0 + btOnOff1.val=sys0 + } + if(type1.txt=="switch") + { + vis btOnOff1,1 + vis bText1,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",9 + covx tTmp.txt,sys0,0,0 + btOnOff1.val=sys0 + } + if(type1.txt=="text") + { + vis btOnOff1,0 + vis bText1,1 + tsw bText1,0 + bText1.pco=65535 + bText1.pco2=65535 + // get Text (optional Value) + spstr strCommand.txt,bText1.txt,"~",9 + } + if(type1.txt=="button") + { + vis btOnOff1,0 + vis bText1,1 + tsw bText1,1 + bText1.pco=1374 + bText1.pco2=1374 + // get Text (optional Value) + spstr strCommand.txt,bText1.txt,"~",9 + } + // get Type + spstr strCommand.txt,type2.txt,"~",10 + // get internal name + spstr strCommand.txt,entn2.txt,"~",11 + if(type2.txt=="delete"||type2.txt=="") + { + vis btOnOff2,0 + vis tEntity2,0 + vis tIcon2,0 + vis bText2,0 + }else + { + // change icon + spstr strCommand.txt,tIcon2.txt,"~",12 + vis tIcon2,1 + // change icon color + spstr strCommand.txt,tTmp.txt,"~",13 + covx tTmp.txt,sys0,0,0 + tIcon2.pco=sys0 + // set name + spstr strCommand.txt,tEntity2.txt,"~",14 + vis tEntity2,1 + } + if(type2.txt=="light") + { + vis btOnOff2,1 + vis bText2,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",15 + covx tTmp.txt,sys0,0,0 + btOnOff2.val=sys0 + } + if(type2.txt=="switch") + { + vis btOnOff2,1 + vis bText2,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",15 + covx tTmp.txt,sys0,0,0 + btOnOff2.val=sys0 + } + if(type2.txt=="text") + { + vis btOnOff2,0 + vis bText2,1 + tsw bText2,0 + bText2.pco=65535 + bText2.pco2=65535 + // get Text (optional Value) + spstr strCommand.txt,bText2.txt,"~",15 + } + if(type2.txt=="button") + { + vis btOnOff2,0 + vis bText2,1 + tsw bText2,1 + bText2.pco=1374 + bText2.pco2=1374 + // get Text (optional Value) + spstr strCommand.txt,bText2.txt,"~",15 + } } if(tInstruction.txt=="time") { @@ -829,6 +976,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out-visual/cardThermo.txt b/HMI/US/portrait/n2t-out-visual/cardThermo.txt index afb06183..785f3d1d 100644 --- a/HMI/US/portrait/n2t-out-visual/cardThermo.txt +++ b/HMI/US/portrait/n2t-out-visual/cardThermo.txt @@ -1973,6 +1973,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out-visual/nspanel_US_P_Stats.txt b/HMI/US/portrait/n2t-out-visual/nspanel_US_P_Stats.txt index da0a9ed2..4bc509bc 100644 --- a/HMI/US/portrait/n2t-out-visual/nspanel_US_P_Stats.txt +++ b/HMI/US/portrait/n2t-out-visual/nspanel_US_P_Stats.txt @@ -10,53 +10,53 @@ pageTest 14 Component(s) 14 Line(s) of event code 14 Unique line(s) of event code +popupNotify + 17 Component(s) + 200 Line(s) of event code + 125 Unique line(s) of event code +popupShutter + 20 Component(s) + 197 Line(s) of event code + 111 Unique line(s) of event code +popupLight + 27 Component(s) + 507 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 -popupShutter - 20 Component(s) - 193 Line(s) of event code - 109 Unique line(s) of event code -cardMedia - 33 Component(s) - 346 Line(s) of event code - 177 Unique line(s) of event code -popupNotify - 17 Component(s) - 196 Line(s) of event code - 123 Unique line(s) of event code screensaver 35 Component(s) 292 Line(s) of event code 235 Unique line(s) of event code -cardQR - 28 Component(s) - 247 Line(s) of event code - 137 Unique line(s) of event code -cardAlarm - 38 Component(s) - 360 Line(s) of event code - 222 Unique line(s) of event code -cardGrid - 42 Component(s) - 435 Line(s) of event code - 252 Unique line(s) of event code cardThermo 56 Component(s) - 542 Line(s) of event code - 288 Unique line(s) of event code -popupLight - 27 Component(s) - 341 Line(s) of event code - 185 Unique line(s) of event code + 546 Line(s) of event code + 290 Unique line(s) of event code +cardAlarm + 38 Component(s) + 364 Line(s) of event code + 224 Unique line(s) of event code +cardMedia + 33 Component(s) + 350 Line(s) of event code + 179 Unique line(s) of event code +cardGrid + 42 Component(s) + 439 Line(s) of event code + 254 Unique line(s) of event code +cardQR + 30 Component(s) + 363 Line(s) of event code + 205 Unique line(s) of event code cardEntities 77 Component(s) - 1174 Line(s) of event code - 487 Unique line(s) of event code + 1283 Line(s) of event code + 540 Unique line(s) of event code Total 13 Page(s) - 412 Component(s) - 4300 Line(s) of event code - 1118 Unique line(s) of event code + 414 Component(s) + 4715 Line(s) of event code + 1172 Unique line(s) of event code diff --git a/HMI/US/portrait/n2t-out-visual/pageStartup.txt b/HMI/US/portrait/n2t-out-visual/pageStartup.txt index 6f0f54ed..f49219cc 100644 --- a/HMI/US/portrait/n2t-out-visual/pageStartup.txt +++ b/HMI/US/portrait/n2t-out-visual/pageStartup.txt @@ -402,7 +402,7 @@ Text tVersion Horizontal Alignment : center Vertical Alignment : center Input Type : character - Text : 34 + Text : 35 Max. Text Size : 10 Word wrap : disabled Horizontal Spacing : 0 diff --git a/HMI/US/portrait/n2t-out-visual/popupLight.txt b/HMI/US/portrait/n2t-out-visual/popupLight.txt index b0569462..6ef9636f 100644 --- a/HMI/US/portrait/n2t-out-visual/popupLight.txt +++ b/HMI/US/portrait/n2t-out-visual/popupLight.txt @@ -20,43 +20,244 @@ Page popupLight Events Preinitialize Event - //get entitiy name - tEntity.txt=pageIcons.tTmp1.txt - //get entity id - entn.txt=pageIcons.tTmp2.txt - vis p0,0 - vis tSend,0 - vis tTmp,0 - vis tInstruction,0 - vis tId,0 - //page open event - // event,pageOpenDetail,typeOfPage,tEntityName - // craft command - tSend.txt="event,pageOpenDetail,popupLight,"+entn.txt - //send calc crc - btlen tSend.txt,sys0 - crcrest 1,0xffff // reset CRC - crcputh 55 bb - crcputs sys0,2 - crcputs tSend.txt,0 - //send cmd - printh 55 bb - prints sys0,2 - prints tSend.txt,0 - prints crcval,2 - //disable brightness by default - vis t1,0 - vis t2,0 - vis hBrightness,0 - //disable color temp by default - vis t4,0 - vis t3,0 - vis hTempSlider,0 - //disable color wheel components by default - vis bColor,0 - vis t0,0 - vis pColorWheel,0 - //vis t0,0 + // data available + if(usize>1) + { + bufferPos=0 + while(bufferPos isn't supported + if(tTmp.txt=="disable") + { + vis t0,0 + vis bColor,0 + vis pColorWheel,0 + }else + { + vis t0,1 + //only enable bColor button if color temp is also supported + if(mode_temp.val==1) + { + vis bColor,1 + } + if(mode.val==0) + { + vis pColorWheel,1 + } + } + // set t0 Color (Localization) + spstr strCommand.txt,t0.txt,"~",7 + // set t4 Temperature (Localization) + spstr strCommand.txt,t4.txt,"~",8 + // set t1 Brightness (Localization) + spstr strCommand.txt,t1.txt,"~",9 + } + if(tInstruction.txt=="time") + { + // get set time to global variable + spstr strCommand.txt,pageIcons.vaTime.txt,"~",1 + } + if(tInstruction.txt=="date") + { + // get set date to global variable + spstr strCommand.txt,pageIcons.vaDate.txt,"~",1 + } + if(tInstruction.txt=="dimmode") + { + // get value + spstr strCommand.txt,tTmp.txt,"~",1 + covx tTmp.txt,dimValue,0,0 + } + if(tInstruction.txt=="timeout") + { + //set timeout to global var + spstr strCommand.txt,tTmp.txt,"~",1 + covx tTmp.txt,sleepTimeout,0,0 + } + if(tInstruction.txt=="pageType") + { + //command format pageType,specialPageName + //write name of speical page to tId + spstr strCommand.txt,tId.txt,"~",1 + //save second arg if there's one + spstr strCommand.txt,tTmp.txt,"~",2 + //save third arg if there's one + spstr strCommand.txt,pageIcons.tTmp2.txt,"~",3 + //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=="pageStartup") + { + page pageStartup + } + if(tId.txt=="screensaver") + { + page screensaver + } + if(tId.txt=="cardEntities") + { + page cardEntities + } + if(tId.txt=="cardGrid") + { + page cardGrid + } + if(tId.txt=="popupLight") + { + 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=="cardThermo") + { + page cardThermo + } + if(tId.txt=="cardMedia") + { + page cardMedia + } + if(tId.txt=="cardAlarm") + { + page cardAlarm + } + if(tId.txt=="cardQR") + { + page cardQR + } + } + // end of user code + udelete payloadLength-1 + bufferPos=0 + } + } + } + } + // next character + bufferPos++ + } + } Variable (string) strCommand Attributes diff --git a/HMI/US/portrait/n2t-out-visual/popupNotify.txt b/HMI/US/portrait/n2t-out-visual/popupNotify.txt index 05347b02..e3d8bf9a 100644 --- a/HMI/US/portrait/n2t-out-visual/popupNotify.txt +++ b/HMI/US/portrait/n2t-out-visual/popupNotify.txt @@ -590,6 +590,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out-visual/popupShutter.txt b/HMI/US/portrait/n2t-out-visual/popupShutter.txt index f777db70..d01c7c9c 100644 --- a/HMI/US/portrait/n2t-out-visual/popupShutter.txt +++ b/HMI/US/portrait/n2t-out-visual/popupShutter.txt @@ -707,6 +707,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out/cardAlarm.txt b/HMI/US/portrait/n2t-out/cardAlarm.txt index b29a12ea..f076f39d 100644 --- a/HMI/US/portrait/n2t-out/cardAlarm.txt +++ b/HMI/US/portrait/n2t-out/cardAlarm.txt @@ -788,6 +788,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out/cardEntities.txt b/HMI/US/portrait/n2t-out/cardEntities.txt index 0945b287..b12050d1 100644 --- a/HMI/US/portrait/n2t-out/cardEntities.txt +++ b/HMI/US/portrait/n2t-out/cardEntities.txt @@ -1505,6 +1505,28 @@ Timer tmSerial vis bText1,0 vis hSlider1,0 vis nNum1,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",8 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp1.pco=27501 + tsw bUp1,0 + }else + { + bUp1.pco=65535 + tsw bUp1,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown1.pco=27501 + tsw bDown1,0 + }else + { + bDown1.pco=65535 + tsw bDown1,1 + } } if(type1.txt=="light") { @@ -1627,6 +1649,28 @@ Timer tmSerial vis bText2,0 vis hSlider2,0 vis nNum2,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",14 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp2.pco=27501 + tsw bUp2,0 + }else + { + bUp2.pco=65535 + tsw bUp2,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown2.pco=27501 + tsw bDown2,0 + }else + { + bDown2.pco=65535 + tsw bDown2,1 + } } if(type2.txt=="light") { @@ -1749,6 +1793,28 @@ Timer tmSerial vis bText3,0 vis hSlider3,0 vis nNum3,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",20 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp3.pco=27501 + tsw bUp3,0 + }else + { + bUp3.pco=65535 + tsw bUp3,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown3.pco=27501 + tsw bDown3,0 + }else + { + bDown3.pco=65535 + tsw bDown3,1 + } } if(type3.txt=="light") { @@ -1871,6 +1937,28 @@ Timer tmSerial vis bText4,0 vis hSlider4,0 vis nNum4,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",26 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp4.pco=27501 + tsw bUp4,0 + }else + { + bUp4.pco=65535 + tsw bUp4,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown4.pco=27501 + tsw bDown4,0 + }else + { + bDown4.pco=65535 + tsw bDown4,1 + } } if(type4.txt=="light") { @@ -1993,6 +2081,28 @@ Timer tmSerial vis bText5,0 vis hSlider5,0 vis nNum5,0 + // get Button State (optional Value) + spstr strCommand.txt,tId.txt,"~",32 + spstr tId.txt,tTmp.txt,"|",0 + if(tTmp.txt=="0") + { + bUp5.pco=27501 + tsw bUp5,0 + }else + { + bUp5.pco=65535 + tsw bUp5,1 + } + spstr tId.txt,tTmp.txt,"|",1 + if(tTmp.txt=="0") + { + bDown5.pco=27501 + tsw bDown5,0 + }else + { + bDown5.pco=65535 + tsw bDown5,1 + } } if(type5.txt=="light") { @@ -2133,6 +2243,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out/cardGrid.txt b/HMI/US/portrait/n2t-out/cardGrid.txt index 4845c21b..12d623a0 100644 --- a/HMI/US/portrait/n2t-out/cardGrid.txt +++ b/HMI/US/portrait/n2t-out/cardGrid.txt @@ -869,6 +869,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out/cardMedia.txt b/HMI/US/portrait/n2t-out/cardMedia.txt index 08993e47..3cfbfe02 100644 --- a/HMI/US/portrait/n2t-out/cardMedia.txt +++ b/HMI/US/portrait/n2t-out/cardMedia.txt @@ -740,6 +740,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out/cardQR.txt b/HMI/US/portrait/n2t-out/cardQR.txt index 72b222c2..8d9166df 100644 --- a/HMI/US/portrait/n2t-out/cardQR.txt +++ b/HMI/US/portrait/n2t-out/cardQR.txt @@ -19,6 +19,16 @@ Page cardQR vis tId,0 vis bPrev,0 vis bNext,0 + //ui e1 + vis btOnOff1,0 + vis tIcon1,0 + vis tEntity1,0 + vis bText1,0 + //ui e2 + vis btOnOff2,0 + vis tIcon2,0 + vis tEntity2,0 + vis bText2,0 Variable (string) strCommand Attributes @@ -68,6 +78,18 @@ Variable (string) entn2 Text : Max. Text Size: 80 +Variable (string) type1 + Attributes + Scope : local + Text : + Max. Text Size: 10 + +Variable (string) type2 + Attributes + Scope : local + Text : + Max. Text Size: 10 + Text tEntity1 Attributes Scope : local @@ -432,8 +454,9 @@ Timer tmSerial spstr strCommand.txt,tInstruction.txt,"~",0 if(tInstruction.txt=="entityUpd") { - //entn - spstr strCommand.txt,entn.txt,"~",1 + // command format: entityUpd,heading,navigation,textQR[,type,internalName,iconId,displayName,optionalValue]x2 + //tHeading + spstr strCommand.txt,tHeading.txt,"~",1 // navigation icons spstr strCommand.txt,tId.txt,"~",2 spstr tId.txt,tTmp.txt,"|",0 @@ -463,6 +486,128 @@ Timer tmSerial } //text qrcode spstr strCommand.txt,qr0.txt,"~",3 + // get Type + spstr strCommand.txt,type1.txt,"~",4 + // get internal name + spstr strCommand.txt,entn1.txt,"~",5 + if(type1.txt=="delete"||type1.txt=="") + { + vis btOnOff1,0 + vis tEntity1,0 + vis tIcon1,0 + vis bText1,0 + }else + { + // change icon + spstr strCommand.txt,tIcon1.txt,"~",6 + vis tIcon1,1 + // change icon color + spstr strCommand.txt,tTmp.txt,"~",7 + covx tTmp.txt,sys0,0,0 + tIcon1.pco=sys0 + // set name + spstr strCommand.txt,tEntity1.txt,"~",8 + vis tEntity1,1 + } + if(type1.txt=="light") + { + vis btOnOff1,1 + vis bText1,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",9 + covx tTmp.txt,sys0,0,0 + btOnOff1.val=sys0 + } + if(type1.txt=="switch") + { + vis btOnOff1,1 + vis bText1,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",9 + covx tTmp.txt,sys0,0,0 + btOnOff1.val=sys0 + } + if(type1.txt=="text") + { + vis btOnOff1,0 + vis bText1,1 + tsw bText1,0 + bText1.pco=65535 + bText1.pco2=65535 + // get Text (optional Value) + spstr strCommand.txt,bText1.txt,"~",9 + } + if(type1.txt=="button") + { + vis btOnOff1,0 + vis bText1,1 + tsw bText1,1 + bText1.pco=1374 + bText1.pco2=1374 + // get Text (optional Value) + spstr strCommand.txt,bText1.txt,"~",9 + } + // get Type + spstr strCommand.txt,type2.txt,"~",10 + // get internal name + spstr strCommand.txt,entn2.txt,"~",11 + if(type2.txt=="delete"||type2.txt=="") + { + vis btOnOff2,0 + vis tEntity2,0 + vis tIcon2,0 + vis bText2,0 + }else + { + // change icon + spstr strCommand.txt,tIcon2.txt,"~",12 + vis tIcon2,1 + // change icon color + spstr strCommand.txt,tTmp.txt,"~",13 + covx tTmp.txt,sys0,0,0 + tIcon2.pco=sys0 + // set name + spstr strCommand.txt,tEntity2.txt,"~",14 + vis tEntity2,1 + } + if(type2.txt=="light") + { + vis btOnOff2,1 + vis bText2,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",15 + covx tTmp.txt,sys0,0,0 + btOnOff2.val=sys0 + } + if(type2.txt=="switch") + { + vis btOnOff2,1 + vis bText2,0 + // get Button State (optional Value) + spstr strCommand.txt,tTmp.txt,"~",15 + covx tTmp.txt,sys0,0,0 + btOnOff2.val=sys0 + } + if(type2.txt=="text") + { + vis btOnOff2,0 + vis bText2,1 + tsw bText2,0 + bText2.pco=65535 + bText2.pco2=65535 + // get Text (optional Value) + spstr strCommand.txt,bText2.txt,"~",15 + } + if(type2.txt=="button") + { + vis btOnOff2,0 + vis bText2,1 + tsw bText2,1 + bText2.pco=1374 + bText2.pco2=1374 + // get Text (optional Value) + spstr strCommand.txt,bText2.txt,"~",15 + } } if(tInstruction.txt=="time") { @@ -541,6 +686,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out/cardThermo.txt b/HMI/US/portrait/n2t-out/cardThermo.txt index a6a138e4..34644168 100644 --- a/HMI/US/portrait/n2t-out/cardThermo.txt +++ b/HMI/US/portrait/n2t-out/cardThermo.txt @@ -1192,6 +1192,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } if(tInstruction.txt=="time") { diff --git a/HMI/US/portrait/n2t-out/pageStartup.txt b/HMI/US/portrait/n2t-out/pageStartup.txt index 6c031dfa..bcd74fdc 100644 --- a/HMI/US/portrait/n2t-out/pageStartup.txt +++ b/HMI/US/portrait/n2t-out/pageStartup.txt @@ -152,7 +152,7 @@ Text tVersion Disable release event after dragging: 0 Send Component ID : disabled Associated Keyboard : none - Text : 34 + Text : 35 Max. Text Size : 10 Picture p0 diff --git a/HMI/US/portrait/n2t-out/popupLight.txt b/HMI/US/portrait/n2t-out/popupLight.txt index 5e24181f..2e0e207b 100644 --- a/HMI/US/portrait/n2t-out/popupLight.txt +++ b/HMI/US/portrait/n2t-out/popupLight.txt @@ -12,43 +12,244 @@ Page popupLight Events Preinitialize Event - //get entitiy name - tEntity.txt=pageIcons.tTmp1.txt - //get entity id - entn.txt=pageIcons.tTmp2.txt - vis p0,0 - vis tSend,0 - vis tTmp,0 - vis tInstruction,0 - vis tId,0 - //page open event - // event,pageOpenDetail,typeOfPage,tEntityName - // craft command - tSend.txt="event,pageOpenDetail,popupLight,"+entn.txt - //send calc crc - btlen tSend.txt,sys0 - crcrest 1,0xffff // reset CRC - crcputh 55 bb - crcputs sys0,2 - crcputs tSend.txt,0 - //send cmd - printh 55 bb - prints sys0,2 - prints tSend.txt,0 - prints crcval,2 - //disable brightness by default - vis t1,0 - vis t2,0 - vis hBrightness,0 - //disable color temp by default - vis t4,0 - vis t3,0 - vis hTempSlider,0 - //disable color wheel components by default - vis bColor,0 - vis t0,0 - vis pColorWheel,0 - //vis t0,0 + // data available + if(usize>1) + { + bufferPos=0 + while(bufferPos isn't supported + if(tTmp.txt=="disable") + { + vis t0,0 + vis bColor,0 + vis pColorWheel,0 + }else + { + vis t0,1 + //only enable bColor button if color temp is also supported + if(mode_temp.val==1) + { + vis bColor,1 + } + if(mode.val==0) + { + vis pColorWheel,1 + } + } + // set t0 Color (Localization) + spstr strCommand.txt,t0.txt,"~",7 + // set t4 Temperature (Localization) + spstr strCommand.txt,t4.txt,"~",8 + // set t1 Brightness (Localization) + spstr strCommand.txt,t1.txt,"~",9 + } + if(tInstruction.txt=="time") + { + // get set time to global variable + spstr strCommand.txt,pageIcons.vaTime.txt,"~",1 + } + if(tInstruction.txt=="date") + { + // get set date to global variable + spstr strCommand.txt,pageIcons.vaDate.txt,"~",1 + } + if(tInstruction.txt=="dimmode") + { + // get value + spstr strCommand.txt,tTmp.txt,"~",1 + covx tTmp.txt,dimValue,0,0 + } + if(tInstruction.txt=="timeout") + { + //set timeout to global var + spstr strCommand.txt,tTmp.txt,"~",1 + covx tTmp.txt,sleepTimeout,0,0 + } + if(tInstruction.txt=="pageType") + { + //command format pageType,specialPageName + //write name of speical page to tId + spstr strCommand.txt,tId.txt,"~",1 + //save second arg if there's one + spstr strCommand.txt,tTmp.txt,"~",2 + //save third arg if there's one + spstr strCommand.txt,pageIcons.tTmp2.txt,"~",3 + //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=="pageStartup") + { + page pageStartup + } + if(tId.txt=="screensaver") + { + page screensaver + } + if(tId.txt=="cardEntities") + { + page cardEntities + } + if(tId.txt=="cardGrid") + { + page cardGrid + } + if(tId.txt=="popupLight") + { + 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=="cardThermo") + { + page cardThermo + } + if(tId.txt=="cardMedia") + { + page cardMedia + } + if(tId.txt=="cardAlarm") + { + page cardAlarm + } + if(tId.txt=="cardQR") + { + page cardQR + } + } + // end of user code + udelete payloadLength-1 + bufferPos=0 + } + } + } + } + // next character + bufferPos++ + } + } Variable (string) strCommand Attributes diff --git a/HMI/US/portrait/n2t-out/popupNotify.txt b/HMI/US/portrait/n2t-out/popupNotify.txt index af719e18..0f032184 100644 --- a/HMI/US/portrait/n2t-out/popupNotify.txt +++ b/HMI/US/portrait/n2t-out/popupNotify.txt @@ -381,6 +381,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1 diff --git a/HMI/US/portrait/n2t-out/popupShutter.txt b/HMI/US/portrait/n2t-out/popupShutter.txt index 0542a922..f932736c 100644 --- a/HMI/US/portrait/n2t-out/popupShutter.txt +++ b/HMI/US/portrait/n2t-out/popupShutter.txt @@ -422,6 +422,10 @@ Timer tmSerial { page cardAlarm } + if(tId.txt=="cardQR") + { + page cardQR + } } // end of user code udelete payloadLength-1