Move brightness control to global var

Clean up page Home
This commit is contained in:
Edward Firmo
2023-08-30 15:08:28 +02:00
parent f29eeda845
commit 4748739155
79 changed files with 228 additions and 261 deletions

View File

@@ -393,7 +393,7 @@ api:
id(disp1).send_command_printf("page home");
} else {
if (page == "home"){
id(disp1).send_command_printf("dim=brightness.val");
id(disp1).send_command_printf("dim=brightness");
}
}
- if:
@@ -1337,7 +1337,7 @@ number:
state: 'screensaver'
then:
- lambda: 'id(disp1).set_backlight_brightness(x/100);'
- lambda: 'id(disp1).send_command_printf("home.brightness.val=%i", int(x));'
- lambda: 'id(disp1).send_command_printf("brightness=%i", int(x));'
- globals.set:
id: display_brightness_global
value: !lambda 'return int(x);'
@@ -1355,7 +1355,7 @@ number:
optimistic: true
set_action:
then:
- lambda: 'id(disp1).send_command_printf("home.brightdd.val=%i", int(x));'
- lambda: 'id(disp1).send_command_printf("brightness_dim=%i", int(x));'
- globals.set:
id: display_dim_brightness_global
value: !lambda 'return int(x);'

Binary file not shown.

Binary file not shown.

View File

@@ -6,6 +6,7 @@ Program.s
int p=0,q=0,t=0,f=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_alarm=0,is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40
bauds=115200//Configure baudrat
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port

View File

@@ -12,7 +12,7 @@ Page alarm
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page climate
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==1||home.entity.txt=="embedded_climate")
{
climatesetting.txt="{\"page\": \"climate\", \"component\": \"currentpage\", \"value\": \"pagechange\", \"entity\": \""+home.entity.txt+"\"}"

View File

@@ -12,7 +12,7 @@ Page cover
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page fan
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page home
Events
Preinitialize Event
dim=brightness.val
dim=brightness
dimtimer.en=1
sleeptimer.en=1
printh 92
@@ -26,47 +26,35 @@ Page home
vis bt_entities,is_entities
vis bt_alarm,is_alarm
Variable (int32) brightness
Attributes
ID : 2
Scope: global
Value: 100
Variable (int32) brightdd
Attributes
ID : 3
Scope: global
Value: 40
Variable (int32) disdim
Attributes
ID : 4
ID : 2
Scope: global
Value: 0
Variable (int32) sleepmodus
Attributes
ID : 16
ID : 14
Scope: global
Value: 0
Variable (string) lastclick
Attributes
ID : 50
ID : 48
Scope : local
Text :
Max. Text Size: 100
Variable (string) entity
Attributes
ID : 51
ID : 49
Scope : global
Text :
Max. Text Size: 100
Text time
Attributes
ID : 7
ID : 5
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -76,7 +64,7 @@ Text time
Text current_temp
Attributes
ID : 8
ID : 6
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -86,7 +74,7 @@ Text current_temp
Text outdoor_temp
Attributes
ID : 9
ID : 7
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -96,7 +84,7 @@ Text outdoor_temp
Text date
Attributes
ID : 10
ID : 8
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -106,7 +94,7 @@ Text date
Text value01_state
Attributes
ID : 12
ID : 10
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -116,7 +104,7 @@ Text value01_state
Text left_bt_text
Attributes
ID : 17
ID : 15
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -126,7 +114,7 @@ Text left_bt_text
Text right_bt_text
Attributes
ID : 18
ID : 16
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -136,7 +124,7 @@ Text right_bt_text
Text icon_top_01
Attributes
ID : 21
ID : 19
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -146,7 +134,7 @@ Text icon_top_01
Text icon_top_02
Attributes
ID : 22
ID : 20
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -156,7 +144,7 @@ Text icon_top_02
Text icon_top_03
Attributes
ID : 23
ID : 21
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -166,7 +154,7 @@ Text icon_top_03
Text icon_top_04
Attributes
ID : 24
ID : 22
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -176,7 +164,7 @@ Text icon_top_04
Text icon_top_05
Attributes
ID : 25
ID : 23
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -186,7 +174,7 @@ Text icon_top_05
Text icon_top_06
Attributes
ID : 26
ID : 24
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -196,7 +184,7 @@ Text icon_top_06
Text icon_top_07
Attributes
ID : 27
ID : 25
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -206,7 +194,7 @@ Text icon_top_07
Text icon_top_08
Attributes
ID : 28
ID : 26
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -216,7 +204,7 @@ Text icon_top_08
Text icon_top_09
Attributes
ID : 29
ID : 27
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -226,7 +214,7 @@ Text icon_top_09
Text icon_top_10
Attributes
ID : 30
ID : 28
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -236,7 +224,7 @@ Text icon_top_10
Text value01_icon
Attributes
ID : 31
ID : 29
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -246,7 +234,7 @@ Text value01_icon
Text value03_state
Attributes
ID : 32
ID : 30
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -256,7 +244,7 @@ Text value03_state
Text value03_icon
Attributes
ID : 33
ID : 31
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -266,7 +254,7 @@ Text value03_icon
Text value02_icon
Attributes
ID : 34
ID : 32
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -276,7 +264,7 @@ Text value02_icon
Text value02_state
Attributes
ID : 35
ID : 33
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -286,7 +274,7 @@ Text value02_state
Text wifi_icon
Attributes
ID : 36
ID : 34
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -296,7 +284,7 @@ Text wifi_icon
Text indoortempicon
Attributes
ID : 37
ID : 35
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -306,7 +294,7 @@ Text indoortempicon
Text button01_icon
Attributes
ID : 38
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
@@ -316,7 +304,7 @@ Text button01_icon
Text button02_icon
Attributes
ID : 39
ID : 37
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -326,7 +314,7 @@ Text button02_icon
Text button03_icon
Attributes
ID : 40
ID : 38
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -336,7 +324,7 @@ Text button03_icon
Text bt_notific
Attributes
ID : 41
ID : 39
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -353,7 +341,7 @@ Text bt_notific
Text bt_qrcode
Attributes
ID : 42
ID : 40
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -367,7 +355,7 @@ Text bt_qrcode
Text bt_entities
Attributes
ID : 43
ID : 41
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -384,7 +372,7 @@ Text bt_entities
Text bt_alarm
Attributes
ID : 44
ID : 42
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -402,7 +390,7 @@ Text bt_alarm
Text meridiem
Attributes
ID : 49
ID : 47
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -412,28 +400,28 @@ Text meridiem
Picture weather
Attributes
ID : 11
ID : 9
Scope : global
Dragging : 0
Send Component ID: disabled
Picture left_bt_pic
Attributes
ID : 19
ID : 17
Scope : global
Dragging : 0
Send Component ID: disabled
Picture right_bt_pic
Attributes
ID : 20
ID : 18
Scope : global
Dragging : 0
Send Component ID: disabled
Hotspot fc_weather
Attributes
ID : 13
ID : 11
Scope : global
Dragging : 0
Send Component ID: on press and release
@@ -447,7 +435,7 @@ Hotspot fc_weather
Hotspot jump_climate
Attributes
ID : 14
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
@@ -485,7 +473,7 @@ Hotspot jump_climate
Hotspot button01
Attributes
ID : 45
ID : 43
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -502,7 +490,7 @@ Hotspot button01
Hotspot button02
Attributes
ID : 46
ID : 44
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -519,7 +507,7 @@ Hotspot button02
Hotspot button03
Attributes
ID : 47
ID : 45
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -536,7 +524,7 @@ Hotspot button03
Hotspot settings_click
Attributes
ID : 48
ID : 46
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -559,12 +547,12 @@ Timer dimtimer
Timer Event
if(disdim.val==0)
{
dim=brightdd.val // Dim down screen to val set from HA
dim=brightness_dim // Dim down screen to val set from HA
}
Timer swipestore
Attributes
ID : 6
ID : 4
Scope : local
Period (ms): 50
Enabled : no
@@ -576,7 +564,7 @@ Timer swipestore
Timer sleeptimer
Attributes
ID : 15
ID : 13
Scope : local
Period (ms): 65000
Enabled : no
@@ -592,7 +580,7 @@ Timer sleeptimer
Timer settings_timer
Attributes
ID : 52
ID : 50
Scope : local
Period (ms): 1000
Enabled : no
@@ -603,14 +591,14 @@ Timer settings_timer
TouchCap swipe
Attributes
ID : 5
ID : 3
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
dim=brightness.val // Set brightness to saved value (from HA)
dim=brightness // Set brightness to saved value (from HA)
dimtimer.en=1 // Enable timer to calc down for dimming screen
sleeptimer.en=1

View File

@@ -12,7 +12,7 @@ Page keyb_num
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page page_id.val

View File

@@ -12,7 +12,7 @@ Page light
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page notification
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page qrcode
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page settings
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page weather01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather05
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

Binary file not shown.

Binary file not shown.

View File

@@ -6,6 +6,7 @@ Program.s
int p=0,q=0,t=0,f=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_alarm=0,is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40
bauds=115200//Configure baudrat
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port

View File

@@ -12,7 +12,7 @@ Page alarm
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page climate
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==1||home.entity.txt=="embedded_climate")
{
climatesetting.txt="{\"page\": \"climate\", \"component\": \"currentpage\", \"value\": \"pagechange\", \"entity\": \""+home.entity.txt+"\"}"

View File

@@ -12,7 +12,7 @@ Page cover
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page fan
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page home
Events
Preinitialize Event
dim=brightness.val
dim=brightness
dimtimer.en=1
sleeptimer.en=1
printh 92
@@ -26,47 +26,35 @@ Page home
vis bt_entities,is_entities
vis bt_alarm,is_alarm
Variable (int32) brightness
Attributes
ID : 2
Scope: global
Value: 100
Variable (int32) brightdd
Attributes
ID : 3
Scope: global
Value: 40
Variable (int32) disdim
Attributes
ID : 4
ID : 2
Scope: global
Value: 0
Variable (int32) sleepmodus
Attributes
ID : 16
ID : 14
Scope: global
Value: 0
Variable (string) lastclick
Attributes
ID : 50
ID : 48
Scope : local
Text :
Max. Text Size: 100
Variable (string) entity
Attributes
ID : 51
ID : 49
Scope : global
Text :
Max. Text Size: 100
Text time
Attributes
ID : 7
ID : 5
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -76,7 +64,7 @@ Text time
Text current_temp
Attributes
ID : 8
ID : 6
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -86,7 +74,7 @@ Text current_temp
Text outdoor_temp
Attributes
ID : 9
ID : 7
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -96,7 +84,7 @@ Text outdoor_temp
Text date
Attributes
ID : 10
ID : 8
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -106,7 +94,7 @@ Text date
Text value01_state
Attributes
ID : 12
ID : 10
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -116,7 +104,7 @@ Text value01_state
Text left_bt_text
Attributes
ID : 17
ID : 15
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -126,7 +114,7 @@ Text left_bt_text
Text right_bt_text
Attributes
ID : 18
ID : 16
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -136,7 +124,7 @@ Text right_bt_text
Text icon_top_01
Attributes
ID : 21
ID : 19
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -146,7 +134,7 @@ Text icon_top_01
Text icon_top_02
Attributes
ID : 22
ID : 20
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -156,7 +144,7 @@ Text icon_top_02
Text icon_top_03
Attributes
ID : 23
ID : 21
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -166,7 +154,7 @@ Text icon_top_03
Text icon_top_04
Attributes
ID : 24
ID : 22
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -176,7 +164,7 @@ Text icon_top_04
Text icon_top_05
Attributes
ID : 25
ID : 23
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -186,7 +174,7 @@ Text icon_top_05
Text icon_top_06
Attributes
ID : 26
ID : 24
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -196,7 +184,7 @@ Text icon_top_06
Text icon_top_07
Attributes
ID : 27
ID : 25
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -206,7 +194,7 @@ Text icon_top_07
Text icon_top_08
Attributes
ID : 28
ID : 26
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -216,7 +204,7 @@ Text icon_top_08
Text icon_top_09
Attributes
ID : 29
ID : 27
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -226,7 +214,7 @@ Text icon_top_09
Text icon_top_10
Attributes
ID : 30
ID : 28
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -236,7 +224,7 @@ Text icon_top_10
Text value01_icon
Attributes
ID : 31
ID : 29
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -246,7 +234,7 @@ Text value01_icon
Text value03_state
Attributes
ID : 32
ID : 30
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -256,7 +244,7 @@ Text value03_state
Text value03_icon
Attributes
ID : 33
ID : 31
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -266,7 +254,7 @@ Text value03_icon
Text value02_icon
Attributes
ID : 34
ID : 32
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -276,7 +264,7 @@ Text value02_icon
Text value02_state
Attributes
ID : 35
ID : 33
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -286,7 +274,7 @@ Text value02_state
Text wifi_icon
Attributes
ID : 36
ID : 34
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -296,7 +284,7 @@ Text wifi_icon
Text indoortempicon
Attributes
ID : 37
ID : 35
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -306,7 +294,7 @@ Text indoortempicon
Text button01_icon
Attributes
ID : 38
ID : 36
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -316,7 +304,7 @@ Text button01_icon
Text button02_icon
Attributes
ID : 39
ID : 37
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -326,7 +314,7 @@ Text button02_icon
Text button03_icon
Attributes
ID : 40
ID : 38
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -336,7 +324,7 @@ Text button03_icon
Text bt_notific
Attributes
ID : 41
ID : 39
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -353,7 +341,7 @@ Text bt_notific
Text bt_qrcode
Attributes
ID : 42
ID : 40
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -367,7 +355,7 @@ Text bt_qrcode
Text bt_entities
Attributes
ID : 43
ID : 41
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -384,7 +372,7 @@ Text bt_entities
Text bt_alarm
Attributes
ID : 44
ID : 42
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -402,7 +390,7 @@ Text bt_alarm
Text meridiem
Attributes
ID : 49
ID : 47
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -412,28 +400,28 @@ Text meridiem
Picture weather
Attributes
ID : 11
ID : 9
Scope : global
Dragging : 0
Send Component ID: disabled
Picture left_bt_pic
Attributes
ID : 19
ID : 17
Scope : global
Dragging : 0
Send Component ID: disabled
Picture right_bt_pic
Attributes
ID : 20
ID : 18
Scope : global
Dragging : 0
Send Component ID: disabled
Hotspot fc_weather
Attributes
ID : 13
ID : 11
Scope : global
Dragging : 0
Send Component ID: on press and release
@@ -447,7 +435,7 @@ Hotspot fc_weather
Hotspot jump_climate
Attributes
ID : 14
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
@@ -485,7 +473,7 @@ Hotspot jump_climate
Hotspot button01
Attributes
ID : 45
ID : 43
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -502,7 +490,7 @@ Hotspot button01
Hotspot button02
Attributes
ID : 46
ID : 44
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -519,7 +507,7 @@ Hotspot button02
Hotspot button03
Attributes
ID : 47
ID : 45
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -536,7 +524,7 @@ Hotspot button03
Hotspot settings_click
Attributes
ID : 48
ID : 46
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -559,12 +547,12 @@ Timer dimtimer
Timer Event
if(disdim.val==0)
{
dim=brightdd.val // Dim down screen to val set from HA
dim=brightness_dim // Dim down screen to val set from HA
}
Timer swipestore
Attributes
ID : 6
ID : 4
Scope : local
Period (ms): 50
Enabled : no
@@ -576,7 +564,7 @@ Timer swipestore
Timer sleeptimer
Attributes
ID : 15
ID : 13
Scope : local
Period (ms): 65000
Enabled : no
@@ -592,7 +580,7 @@ Timer sleeptimer
Timer settings_timer
Attributes
ID : 52
ID : 50
Scope : local
Period (ms): 1000
Enabled : no
@@ -603,14 +591,14 @@ Timer settings_timer
TouchCap swipe
Attributes
ID : 5
ID : 3
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
dim=brightness.val // Set brightness to saved value (from HA)
dim=brightness // Set brightness to saved value (from HA)
dimtimer.en=1 // Enable timer to calc down for dimming screen
sleeptimer.en=1

View File

@@ -12,7 +12,7 @@ Page keyb_num
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page page_id.val

View File

@@ -12,7 +12,7 @@ Page light
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page notification
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page qrcode
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page settings
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page weather01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather05
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

Binary file not shown.

Binary file not shown.

View File

@@ -6,6 +6,7 @@ Program.s
int p=0,q=0,t=0,f=0
int api=0 // 0 = disconnected from HA, 1 = connected to HA
int is_alarm=0,is_entities=0,is_qrcode=0,is_notification=0
int brightness=100,brightness_dim=40
bauds=115200//Configure baudrat
recmod=0//Serial data parsing mode:0-Passive mode;1-Active mode
printh 00 00 00 ff ff ff 88 ff ff ff//Output power on information to serial port

View File

@@ -12,7 +12,7 @@ Page alarm
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page buttonpage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page climate
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==1||home.entity.txt=="embedded_climate")
{
climatesetting.txt="{\"page\": \"climate\", \"component\": \"currentpage\", \"value\": \"pagechange\", \"entity\": \""+home.entity.txt+"\"}"

View File

@@ -12,7 +12,7 @@ Page cover
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page entitypage04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page fan
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page home
Events
Preinitialize Event
dim=brightness.val
dim=brightness
dimtimer.en=1
sleeptimer.en=1
printh 92
@@ -28,47 +28,35 @@ Page home
vis left_bt_text,0
vis right_bt_text,0
Variable (int32) brightness
Attributes
ID : 2
Scope: global
Value: 100
Variable (int32) brightdd
Attributes
ID : 3
Scope: global
Value: 40
Variable (int32) disdim
Attributes
ID : 4
ID : 2
Scope: global
Value: 0
Variable (int32) sleepmodus
Attributes
ID : 16
ID : 14
Scope: global
Value: 0
Variable (string) lastclick
Attributes
ID : 50
ID : 48
Scope : local
Text :
Max. Text Size: 100
Variable (string) entity
Attributes
ID : 51
ID : 49
Scope : global
Text :
Max. Text Size: 100
Text time
Attributes
ID : 7
ID : 5
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -78,7 +66,7 @@ Text time
Text current_temp
Attributes
ID : 8
ID : 6
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -88,7 +76,7 @@ Text current_temp
Text outdoor_temp
Attributes
ID : 9
ID : 7
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -98,7 +86,7 @@ Text outdoor_temp
Text date
Attributes
ID : 10
ID : 8
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -108,7 +96,7 @@ Text date
Text value01_state
Attributes
ID : 12
ID : 10
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -118,7 +106,7 @@ Text value01_state
Text left_bt_text
Attributes
ID : 17
ID : 15
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -128,7 +116,7 @@ Text left_bt_text
Text right_bt_text
Attributes
ID : 18
ID : 16
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -138,7 +126,7 @@ Text right_bt_text
Text icon_top_01
Attributes
ID : 21
ID : 19
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -148,7 +136,7 @@ Text icon_top_01
Text icon_top_02
Attributes
ID : 22
ID : 20
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -158,7 +146,7 @@ Text icon_top_02
Text icon_top_03
Attributes
ID : 23
ID : 21
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -168,7 +156,7 @@ Text icon_top_03
Text icon_top_04
Attributes
ID : 24
ID : 22
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -178,7 +166,7 @@ Text icon_top_04
Text icon_top_05
Attributes
ID : 25
ID : 23
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -188,7 +176,7 @@ Text icon_top_05
Text icon_top_06
Attributes
ID : 26
ID : 24
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -198,7 +186,7 @@ Text icon_top_06
Text icon_top_07
Attributes
ID : 27
ID : 25
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -208,7 +196,7 @@ Text icon_top_07
Text icon_top_08
Attributes
ID : 28
ID : 26
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -218,7 +206,7 @@ Text icon_top_08
Text icon_top_09
Attributes
ID : 29
ID : 27
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -228,7 +216,7 @@ Text icon_top_09
Text icon_top_10
Attributes
ID : 30
ID : 28
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -238,7 +226,7 @@ Text icon_top_10
Text value01_icon
Attributes
ID : 31
ID : 29
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -248,7 +236,7 @@ Text value01_icon
Text value03_state
Attributes
ID : 32
ID : 30
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -258,7 +246,7 @@ Text value03_state
Text value03_icon
Attributes
ID : 33
ID : 31
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -268,7 +256,7 @@ Text value03_icon
Text value02_icon
Attributes
ID : 34
ID : 32
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -278,7 +266,7 @@ Text value02_icon
Text value02_state
Attributes
ID : 35
ID : 33
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -288,7 +276,7 @@ Text value02_state
Text wifi_icon
Attributes
ID : 36
ID : 34
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -298,7 +286,7 @@ Text wifi_icon
Text indoortempicon
Attributes
ID : 37
ID : 35
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -308,7 +296,7 @@ Text indoortempicon
Text button01_icon
Attributes
ID : 38
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
@@ -318,7 +306,7 @@ Text button01_icon
Text button02_icon
Attributes
ID : 39
ID : 37
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -328,7 +316,7 @@ Text button02_icon
Text button03_icon
Attributes
ID : 40
ID : 38
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -338,7 +326,7 @@ Text button03_icon
Text bt_notific
Attributes
ID : 41
ID : 39
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -355,7 +343,7 @@ Text bt_notific
Text bt_qrcode
Attributes
ID : 42
ID : 40
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -369,7 +357,7 @@ Text bt_qrcode
Text bt_entities
Attributes
ID : 43
ID : 41
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -386,7 +374,7 @@ Text bt_entities
Text bt_alarm
Attributes
ID : 44
ID : 42
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -404,7 +392,7 @@ Text bt_alarm
Text meridiem
Attributes
ID : 49
ID : 47
Scope : global
Dragging : 0
Send Component ID : disabled
@@ -414,28 +402,28 @@ Text meridiem
Picture weather
Attributes
ID : 11
ID : 9
Scope : global
Dragging : 0
Send Component ID: disabled
Picture left_bt_pic
Attributes
ID : 19
ID : 17
Scope : global
Dragging : 0
Send Component ID: disabled
Picture right_bt_pic
Attributes
ID : 20
ID : 18
Scope : global
Dragging : 0
Send Component ID: disabled
Hotspot fc_weather
Attributes
ID : 13
ID : 11
Scope : global
Dragging : 0
Send Component ID: on press and release
@@ -449,7 +437,7 @@ Hotspot fc_weather
Hotspot jump_climate
Attributes
ID : 14
ID : 12
Scope : local
Dragging : 0
Send Component ID: on press and release
@@ -487,7 +475,7 @@ Hotspot jump_climate
Hotspot button01
Attributes
ID : 45
ID : 43
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -504,7 +492,7 @@ Hotspot button01
Hotspot button02
Attributes
ID : 46
ID : 44
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -521,7 +509,7 @@ Hotspot button02
Hotspot button03
Attributes
ID : 47
ID : 45
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -538,7 +526,7 @@ Hotspot button03
Hotspot settings_click
Attributes
ID : 48
ID : 46
Scope : local
Dragging : 0
Send Component ID: disabled
@@ -561,12 +549,12 @@ Timer dimtimer
Timer Event
if(disdim.val==0)
{
dim=brightdd.val // Dim down screen to val set from HA
dim=brightness_dim // Dim down screen to val set from HA
}
Timer swipestore
Attributes
ID : 6
ID : 4
Scope : local
Period (ms): 50
Enabled : no
@@ -578,7 +566,7 @@ Timer swipestore
Timer sleeptimer
Attributes
ID : 15
ID : 13
Scope : local
Period (ms): 65000
Enabled : no
@@ -594,7 +582,7 @@ Timer sleeptimer
Timer settings_timer
Attributes
ID : 52
ID : 50
Scope : local
Period (ms): 1000
Enabled : no
@@ -605,14 +593,14 @@ Timer settings_timer
TouchCap swipe
Attributes
ID : 5
ID : 3
Scope: local
Value: 0
Events
Touch Press Event
swipestore.en=1 // Start swipestore timer
dim=brightness.val // Set brightness to saved value (from HA)
dim=brightness // Set brightness to saved value (from HA)
dimtimer.en=1 // Enable timer to calc down for dimming screen
sleeptimer.en=1

View File

@@ -12,7 +12,7 @@ Page keyb_num
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page page_id.val

View File

@@ -12,7 +12,7 @@ Page light
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page notification
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page qrcode
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page settings
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
printh 92
prints "nspanelevent",0
printh 00

View File

@@ -12,7 +12,7 @@ Page weather01
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather02
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather03
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather04
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home

View File

@@ -12,7 +12,7 @@ Page weather05
Events
Preinitialize Event
dim=home.brightness.val
dim=brightness
if(api==0)
{
page home