Climate 2-setpoints preparation

This commit is contained in:
Edward Firmo
2023-12-11 13:57:36 +01:00
parent 77bd6addc4
commit 0ef83e9ba8
4 changed files with 602 additions and 590 deletions

View File

@@ -134,13 +134,13 @@ script:
disp1->hide_component("button06"); disp1->hide_component("button06");
disp1->show_component("button07"); //Off disp1->show_component("button07"); //Off
// Set buttons colors // Set buttons colors
disp1->set_component_font_color("climate.button01_icon", 6339); disp1->set_component_font_color("climate.button01", 6339);
disp1->set_component_font_color("climate.button02_icon", 6339); disp1->set_component_font_color("climate.button02", 6339);
disp1->set_component_font_color("climate.button03_icon", (thermostat_embedded->mode==climate::CLIMATE_MODE_HEAT) ? 64164 : ((${addon_climate_heat}) ? 48631 : 6339)); disp1->set_component_font_color("climate.button03", (thermostat_embedded->mode==climate::CLIMATE_MODE_HEAT) ? 64164 : ((${addon_climate_heat}) ? 48631 : 6339));
disp1->set_component_font_color("climate.button04_icon", (thermostat_embedded->mode==climate::CLIMATE_MODE_COOL) ? 1055 : ((${addon_climate_cool}) ? 48631 : 6339)); disp1->set_component_font_color("climate.button04", (thermostat_embedded->mode==climate::CLIMATE_MODE_COOL) ? 1055 : ((${addon_climate_cool}) ? 48631 : 6339));
disp1->set_component_font_color("climate.button05_icon", 6339); disp1->set_component_font_color("climate.button05", 6339);
disp1->set_component_font_color("climate.button06_icon", 6339); disp1->set_component_font_color("climate.button06", 6339);
disp1->set_component_font_color("climate.button07_icon", (thermostat_embedded->mode==climate::CLIMATE_MODE_OFF) ? 10597 : 35921); disp1->set_component_font_color("climate.button07", (thermostat_embedded->mode==climate::CLIMATE_MODE_OFF) ? 10597 : 35921);
} }
- id: !extend addon_climate_set_climate_friendly_name - id: !extend addon_climate_set_climate_friendly_name

View File

@@ -2370,13 +2370,13 @@ script:
static const char *const TAG = "script.page_climate"; static const char *const TAG = "script.page_climate";
if (construct_page) { if (construct_page) {
ESP_LOGV(TAG, "Construct climate page"); ESP_LOGV(TAG, "Construct climate page");
disp1->set_component_text_printf("climate.button01_icon", "%s", "\uEE8D"); //mdi:calendar-sync disp1->set_component_text_printf("climate.button01", "%s", "\uEE8D"); //mdi:calendar-sync
disp1->set_component_text_printf("climate.button02_icon", "%s", "\uE069"); //mdi:autorenew disp1->set_component_text_printf("climate.button02", "%s", "\uE069"); //mdi:autorenew
disp1->set_component_text_printf("climate.button03_icon", "%s", "\uE237"); //mdi:fire disp1->set_component_text_printf("climate.button03", "%s", "\uE237"); //mdi:fire
disp1->set_component_text_printf("climate.button04_icon", "%s", "\uE716"); //mdi:snowflake disp1->set_component_text_printf("climate.button04", "%s", "\uE716"); //mdi:snowflake
disp1->set_component_text_printf("climate.button05_icon", "%s", "\uE58D"); //mdi:water-percent disp1->set_component_text_printf("climate.button05", "%s", "\uE58D"); //mdi:water-percent
disp1->set_component_text_printf("climate.button06_icon", "%s", "\uE20F"); //mdi:fan disp1->set_component_text_printf("climate.button06", "%s", "\uE20F"); //mdi:fan
disp1->set_component_text_printf("climate.button07_icon", "%s", "\uE424"); //mdi:power disp1->set_component_text_printf("climate.button07", "%s", "\uE424"); //mdi:power
} }
addon_climate_update_page_climate->execute(); addon_climate_update_page_climate->execute();

View File

@@ -16,10 +16,12 @@ Page climate
{ {
sendme sendme
vis target_icon,0 vis target_icon,0
vis target_temp,0 vis target_high,0
vis target_low,0
vis current_temp,0 vis current_temp,0
vis current_icon,0 vis current_icon,0
vis climateslider,0 vis slider_high,0
vis slider_low,0
vis button01,0 vis button01,0
vis button02,0 vis button02,0
vis button03,0 vis button03,0
@@ -76,62 +78,74 @@ Variable (string) climatesetting
Variable (string) lastclick Variable (string) lastclick
Attributes Attributes
ID : 34 ID : 27
Scope : local Scope : local
Text : Text :
Max. Text Size: 255 Max. Text Size: 255
Variable (int32) temp_offset Variable (int32) temp_offset
Attributes Attributes
ID : 36 ID : 29
Scope: local Scope: local
Value: 0 Value: 0
Variable (int32) temp_step Variable (int32) temp_step
Attributes Attributes
ID : 37 ID : 30
Scope: local Scope: local
Value: 0 Value: 0
Variable (int32) temp_number Variable (int32) temp_number
Attributes Attributes
ID : 43 ID : 34
Scope: local Scope: local
Value: 0 Value: 0
Variable (int32) va0 Variable (int32) va0
Attributes Attributes
ID : 44 ID : 35
Scope: local Scope: local
Value: 0 Value: 0
Variable (string) back_page Variable (string) back_page
Attributes Attributes
ID : 45 ID : 36
Scope : local Scope : local
Text : home Text : home
Max. Text Size: 15 Max. Text Size: 15
Variable (int32) embedded Variable (int32) embedded
Attributes Attributes
ID : 46 ID : 37
Scope: global Scope: global
Value: 0 Value: 0
Variable (string) va2 Variable (string) va2
Attributes Attributes
ID : 47 ID : 38
Scope : local Scope : local
Text : Text :
Max. Text Size: 10 Max. Text Size: 10
Variable (string) click_comp Variable (string) click_comp
Attributes Attributes
ID : 49 ID : 40
Scope : local Scope : local
Text : Text :
Max. Text Size: 8 Max. Text Size: 8
Variable (int32) single_slider
Attributes
ID : 44
Scope: local
Value: 1
Variable (int32) active_slider
Attributes
ID : 45
Scope: local
Value: 1
Text current_temp Text current_temp
Attributes Attributes
ID : 3 ID : 3
@@ -348,99 +362,271 @@ Text value04
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
Text button01_icon Text button01
Attributes Attributes
ID : 18 ID : 18
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button02_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button02
Attributes Attributes
ID : 19 ID : 19
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button03_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button03
Attributes Attributes
ID : 20 ID : 20
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button04_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button04
Attributes Attributes
ID : 21 ID : 21
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button05_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button05
Attributes Attributes
ID : 22 ID : 22
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button06_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button06
Attributes Attributes
ID : 23 ID : 23
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button07_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button07
Attributes Attributes
ID : 24 ID : 24
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button08_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button08
Attributes Attributes
ID : 38 ID : 31
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button09_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button09
Attributes Attributes
ID : 40 ID : 32
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text target_temp Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text target_high
Attributes Attributes
ID : 42 ID : 33
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : disabled
@@ -456,7 +642,25 @@ Text target_temp
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
Slider climateslider Text target_low
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Slider slider_high
Attributes Attributes
ID : 7 ID : 7
Scope : local Scope : local
@@ -475,13 +679,46 @@ Slider climateslider
printh FF FF FF printh FF FF FF
Touch Release Event Touch Release Event
temp_number.val=climateslider.val*temp_step.val temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
timer01.en=1
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Slider slider_low
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 20
Upper range limit: 40
Lower range limit: 0
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val
va0.val=temp_number.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer01.en=1 timer01.en=1
printh 91 printh 91
prints "touchevent",0 prints "touchevent",0
@@ -491,7 +728,7 @@ Slider climateslider
Button button_back Button button_back
Attributes Attributes
ID : 48 ID : 39
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID: disabled Send Component ID: disabled
@@ -532,16 +769,16 @@ Hotspot decrease_temp
printh 00 printh 00
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
if(climateslider.val>0) if(slider_high.val>0)
{ {
climateslider.val-- slider_high.val--
temp_number.val=climateslider.val*temp_step.val temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
} }
Touch Release Event Touch Release Event
@@ -561,256 +798,21 @@ Hotspot increase_temp
printh 00 printh 00
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
if(climateslider.val<climateslider.maxval) if(slider_high.val<slider_high.maxval)
{ {
climateslider.val++ slider_high.val++
temp_number.val=climateslider.val*temp_step.val temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
} }
Touch Release Event Touch Release Event
timer01.en=1 timer01.en=1
Hotspot button01
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button02
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button03
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button04
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button05
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button06
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button07
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button08
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Hotspot button09
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Timer swipestore Timer swipestore
Attributes Attributes
ID : 2 ID : 2
@@ -825,7 +827,7 @@ Timer swipestore
Timer timer01 Timer timer01
Attributes Attributes
ID : 35 ID : 28
Scope : local Scope : local
Period (ms): 1000 Period (ms): 1000
Enabled : no Enabled : no
@@ -845,7 +847,7 @@ Timer timer01
Timer click_timer Timer click_timer
Attributes Attributes
ID : 50 ID : 41
Scope : local Scope : local
Period (ms): 800 Period (ms): 800
Enabled : no Enabled : no
@@ -863,7 +865,7 @@ Timer click_timer
Timer wakeup_timer Timer wakeup_timer
Attributes Attributes
ID : 51 ID : 42
Scope : local Scope : local
Period (ms): 100 Period (ms): 100
Enabled : yes Enabled : yes

View File

@@ -16,10 +16,12 @@ Page climate
{ {
sendme sendme
vis target_icon,0 vis target_icon,0
vis target_temp,0 vis target_high,0
vis target_low,0
vis current_temp,0 vis current_temp,0
vis current_icon,0 vis current_icon,0
vis climateslider,0 vis slider_high,0
vis slider_low,0
vis button01,0 vis button01,0
vis button02,0 vis button02,0
vis button03,0 vis button03,0
@@ -76,62 +78,74 @@ Variable (string) climatesetting
Variable (string) lastclick Variable (string) lastclick
Attributes Attributes
ID : 34 ID : 27
Scope : local Scope : local
Text : Text :
Max. Text Size: 255 Max. Text Size: 255
Variable (int32) temp_offset Variable (int32) temp_offset
Attributes Attributes
ID : 36 ID : 29
Scope: local Scope: local
Value: 0 Value: 0
Variable (int32) temp_step Variable (int32) temp_step
Attributes Attributes
ID : 37 ID : 30
Scope: local Scope: local
Value: 1 Value: 1
Variable (int32) temp_number Variable (int32) temp_number
Attributes Attributes
ID : 43 ID : 34
Scope: local Scope: local
Value: 0 Value: 0
Variable (int32) va0 Variable (int32) va0
Attributes Attributes
ID : 44 ID : 35
Scope: local Scope: local
Value: 0 Value: 0
Variable (string) back_page Variable (string) back_page
Attributes Attributes
ID : 45 ID : 36
Scope : local Scope : local
Text : home Text : home
Max. Text Size: 15 Max. Text Size: 15
Variable (int32) embedded Variable (int32) embedded
Attributes Attributes
ID : 46 ID : 37
Scope: global Scope: global
Value: 0 Value: 0
Variable (string) va2 Variable (string) va2
Attributes Attributes
ID : 47 ID : 38
Scope : local Scope : local
Text : Text :
Max. Text Size: 10 Max. Text Size: 10
Variable (string) click_comp Variable (string) click_comp
Attributes Attributes
ID : 49 ID : 40
Scope : local Scope : local
Text : Text :
Max. Text Size: 8 Max. Text Size: 8
Variable (int32) single_slider
Attributes
ID : 44
Scope: local
Value: 1
Variable (int32) active_slider
Attributes
ID : 45
Scope: local
Value: 1
Text current_temp Text current_temp
Attributes Attributes
ID : 3 ID : 3
@@ -348,99 +362,271 @@ Text value04
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
Text button01_icon Text button01
Attributes Attributes
ID : 18 ID : 18
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button02_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button02
Attributes Attributes
ID : 19 ID : 19
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button03_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button03
Attributes Attributes
ID : 20 ID : 20
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button04_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button04
Attributes Attributes
ID : 21 ID : 21
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button05_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button05
Attributes Attributes
ID : 22 ID : 22
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button06_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button06
Attributes Attributes
ID : 23 ID : 23
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button07_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button07
Attributes Attributes
ID : 24 ID : 24
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button08_icon Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text button08
Attributes Attributes
ID : 38 ID : 31
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text button09_icon Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text button09
Attributes Attributes
ID : 40 ID : 32
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : on press and release
Associated Keyboard: none Associated Keyboard: none
Text : Text :
Max. Text Size : 10 Max. Text Size : 10
Text target_temp Events
Touch Press Event
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Text target_high
Attributes Attributes
ID : 42 ID : 33
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID : disabled Send Component ID : disabled
@@ -456,14 +642,32 @@ Text target_temp
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
Slider climateslider Text target_low
Attributes
ID : 46
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 10
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Slider slider_high
Attributes Attributes
ID : 7 ID : 7
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID: disabled Send Component ID: disabled
Position : 20 Position : 200
Upper range limit: 40 Upper range limit: 400
Lower range limit: 0 Lower range limit: 0
Events Events
@@ -475,13 +679,54 @@ Slider climateslider
printh FF FF FF printh FF FF FF
Touch Release Event Touch Release Event
temp_number.val=climateslider.val*temp_step.val if(single_slider.val==1)
{
slider_low.val=slider_high.val
}
temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
timer01.en=1
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Slider slider_low
Attributes
ID : 43
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 200
Upper range limit: 400
Lower range limit: 0
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
if(single_slider.val==1)
{
slider_high.val=slider_low.val
}
temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val
va0.val=temp_number.val/10
covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt
timer01.en=1 timer01.en=1
printh 91 printh 91
prints "touchevent",0 prints "touchevent",0
@@ -491,7 +736,7 @@ Slider climateslider
Button button_back Button button_back
Attributes Attributes
ID : 48 ID : 39
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID: disabled Send Component ID: disabled
@@ -528,7 +773,7 @@ Hotspot decrease_temp
ID : 4 ID : 4
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID: disabled Send Component ID: on press and release
Events Events
Touch Press Event Touch Press Event
@@ -537,16 +782,16 @@ Hotspot decrease_temp
printh 00 printh 00
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
if(climateslider.val>0) if(slider_high.val>0)
{ {
climateslider.val-- slider_high.val--
temp_number.val=climateslider.val*temp_step.val temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
} }
Touch Release Event Touch Release Event
@@ -557,7 +802,7 @@ Hotspot increase_temp
ID : 5 ID : 5
Scope : local Scope : local
Dragging : 0 Dragging : 0
Send Component ID: disabled Send Component ID: on press and release
Events Events
Touch Press Event Touch Press Event
@@ -566,256 +811,21 @@ Hotspot increase_temp
printh 00 printh 00
prints rand,0 prints rand,0
printh FF FF FF printh FF FF FF
if(climateslider.val<climateslider.maxval) if(slider_high.val<slider_high.maxval)
{ {
climateslider.val++ slider_high.val++
temp_number.val=climateslider.val*temp_step.val temp_number.val=slider_high.val*temp_step.val
temp_number.val+=temp_offset.val temp_number.val+=temp_offset.val
va0.val=temp_number.val/10 va0.val=temp_number.val/10
covx va0.val,target_temp.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number.val%10 va0.val=temp_number.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_temp.txt+="."+va1.txt target_high.txt+="."+va1.txt
} }
Touch Release Event Touch Release Event
timer01.en=1 timer01.en=1
Hotspot button01
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"auto\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button02
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat_cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button03
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"heat\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button04
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"cool\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button05
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"dry\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button06
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"fan_only\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button07
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
Touch Release Event
covx embedded.val,va2.txt,0,0
lastclick.txt="{\"page\": \"climate\", \"key\": \"hvac_mode\", \"value\": \"off\", \"embedded\": "+va2.txt+"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Hotspot button08
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
click_comp.txt="button08"
click_timer.en=1
Touch Release Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Hotspot button09
Attributes
ID : 41
Scope : local
Dragging : 0
Send Component ID: disabled
Events
Touch Press Event
click_comp.txt="button09"
click_timer.en=1
Touch Release Event
printh 91
prints "touchevent",0
printh 00
prints rand,0
printh FF FF FF
if(click_timer.en==1)
{
click_timer.en=0
lastclick.txt="{\"page\": \"climate\", \"event\": \"short_click\", \"component\": \""+click_comp.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
}
Timer swipestore Timer swipestore
Attributes Attributes
ID : 2 ID : 2
@@ -830,7 +840,7 @@ Timer swipestore
Timer timer01 Timer timer01
Attributes Attributes
ID : 35 ID : 28
Scope : local Scope : local
Period (ms): 1000 Period (ms): 1000
Enabled : no Enabled : no
@@ -850,7 +860,7 @@ Timer timer01
Timer click_timer Timer click_timer
Attributes Attributes
ID : 50 ID : 41
Scope : local Scope : local
Period (ms): 800 Period (ms): 800
Enabled : no Enabled : no
@@ -868,7 +878,7 @@ Timer click_timer
Timer wakeup_timer Timer wakeup_timer
Attributes Attributes
ID : 51 ID : 42
Scope : local Scope : local
Period (ms): 100 Period (ms): 100
Enabled : yes Enabled : yes