Custom decimal separator on climate page

Solves #1161
This commit is contained in:
Edward Firmo
2024-02-27 13:47:08 +01:00
parent f819c1fe33
commit 9ff59624e0
17 changed files with 516 additions and 34 deletions

View File

@@ -2518,20 +2518,27 @@ script:
- lambda: |- - lambda: |-
if (id(is_uploading_tft)) set_climate->stop(); if (id(is_uploading_tft)) set_climate->stop();
if (current_page->state == "climate") { if (current_page->state == "climate") {
bool useDecimal = (temp_step % 10 != 0);
char buffer[15];
disp1->send_command_printf("climateslider.maxval=%i", total_steps); disp1->send_command_printf("climateslider.maxval=%i", total_steps);
disp1->send_command_printf("slider_high.maxval=%i", total_steps); disp1->send_command_printf("slider_high.maxval=%i", total_steps);
disp1->send_command_printf("slider_low.maxval=%i", total_steps); disp1->send_command_printf("slider_low.maxval=%i", total_steps);
disp1->set_component_value("temp_offset", temp_offset); disp1->set_component_value("temp_offset", temp_offset);
disp1->set_component_value("temp_step", temp_step); disp1->set_component_value("temp_step", temp_step);
char dec_separator_str[2] = {id(mui_decimal_separator), '\0'};
disp1->set_component_text("dec_separator", dec_separator_str);
set_component_visibility->execute("current_temp", true); set_component_visibility->execute("current_temp", true);
if (current_temp > -999) if (current_temp > -999) {
disp1->set_component_text_printf("current_temp", "%.1f°", current_temp); snprintf(buffer, sizeof(buffer), (useDecimal) ? "%.1f°" : "%.0f°", current_temp);
disp1->set_component_text("current_temp", adjustDecimalSeparator(buffer, id(mui_decimal_separator)).c_str());
}
else else
disp1->set_component_text_printf("current_temp", id(mui_unavailable_global).c_str()); disp1->set_component_text_printf("current_temp", id(mui_unavailable_global).c_str());
if (target_temp > -999) { // Target temp enabled if (target_temp > -999) { // Target temp enabled
disp1->set_component_value("active_slider", 0); disp1->set_component_value("active_slider", 0);
disp1->set_component_text_printf("target_high", "%.1f°", target_temp); snprintf(buffer, sizeof(buffer), (useDecimal) ? "%.1f°" : "%.0f°", target_temp);
disp1->set_component_text("target_high", adjustDecimalSeparator(buffer, id(mui_decimal_separator)).c_str());
disp1->set_component_value("climateslider", round(((10*target_temp) - temp_offset) / temp_step)); disp1->set_component_value("climateslider", round(((10*target_temp) - temp_offset) / temp_step));
set_component_visibility->execute("slider_high", false); set_component_visibility->execute("slider_high", false);
set_component_visibility->execute("slider_low", false); set_component_visibility->execute("slider_low", false);
@@ -2542,7 +2549,8 @@ script:
set_component_visibility->execute("climate.slider_high", false); set_component_visibility->execute("climate.slider_high", false);
if (target_temp_low > -999) { // Target temp low enabled if (target_temp_low > -999) { // Target temp low enabled
disp1->set_component_value("active_slider", 2); disp1->set_component_value("active_slider", 2);
disp1->set_component_text_printf("target_low", "%.1f°", target_temp_low); snprintf(buffer, sizeof(buffer), (useDecimal) ? "%.1f°" : "%.0f°", target_temp_low);
disp1->set_component_text("target_low", adjustDecimalSeparator(buffer, id(mui_decimal_separator)).c_str());
disp1->set_component_value("slider_low", round(((10*target_temp_low) - temp_offset) / temp_step)); disp1->set_component_value("slider_low", round(((10*target_temp_low) - temp_offset) / temp_step));
set_component_visibility->execute("target_low", true); set_component_visibility->execute("target_low", true);
set_component_visibility->execute("slider_low", true); set_component_visibility->execute("slider_low", true);
@@ -2552,7 +2560,8 @@ script:
} }
if (target_temp_high > -999) { // Target temp high enabled if (target_temp_high > -999) { // Target temp high enabled
disp1->set_component_value("active_slider", 1); disp1->set_component_value("active_slider", 1);
disp1->set_component_text_printf("target_high", "%.1f°", target_temp_high); snprintf(buffer, sizeof(buffer), (useDecimal) ? "%.1f°" : "%.0f°", target_temp_high);
disp1->set_component_text("target_high", adjustDecimalSeparator(buffer, id(mui_decimal_separator)).c_str());
disp1->set_component_value("slider_high", round(((10*target_temp_high) - temp_offset) / temp_step)); disp1->set_component_value("slider_high", round(((10*target_temp_high) - temp_offset) / temp_step));
set_component_visibility->execute("target_high", true); set_component_visibility->execute("target_high", true);
set_component_visibility->execute("slider_high", true); set_component_visibility->execute("slider_high", true);
@@ -2562,7 +2571,7 @@ script:
} }
} }
if (target_temp > -999 or target_temp_high > -999 or target_temp_low > -999) { if (target_temp > -999 or target_temp_high > -999 or target_temp_low > -999) {
disp1->set_component_text_printf("target_icon", "%s", climate_icon.c_str()); disp1->set_component_text("target_icon", climate_icon.c_str());
set_component_visibility->execute("target_icon", true); set_component_visibility->execute("target_icon", true);
set_component_visibility->execute("decrease_temp", true); set_component_visibility->execute("decrease_temp", true);
set_component_visibility->execute("increase_temp", true); set_component_visibility->execute("increase_temp", true);
@@ -2625,7 +2634,7 @@ script:
then: # Wi-Fi connected then: # Wi-Fi connected
- lambda: |- - lambda: |-
if (current_page->state == "boot") { if (current_page->state == "boot") {
disp1->set_component_text_printf("boot.ip_addr", "%s", network::get_ip_address().str().c_str()); disp1->set_component_text("boot.ip_addr", network::get_ip_address().str().c_str());
set_brightness->execute(100); set_brightness->execute(100);
} }
- wait_until: - wait_until:

View File

@@ -20,6 +20,7 @@ Page buttonpage01
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage02
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage03
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage04
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -190,6 +190,13 @@ Variable (int32) temp_gap
Scope: local Scope: local
Value: 0 Value: 0
Variable (string) dec_separator
Attributes
ID : 55
Scope : local
Text : .
Max. Text Size: 5
Text current_temp Text current_temp
Attributes Attributes
ID : 3 ID : 3
@@ -567,7 +574,7 @@ Slider slider_high
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
timer1.en=1 timer1.en=1
active_slider.val=1 active_slider.val=1
@@ -600,7 +607,7 @@ Slider slider_low
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
timer2.en=1 timer2.en=1
active_slider.val=2 active_slider.val=2
@@ -625,7 +632,7 @@ Slider climateslider
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
active_slider.val=0 active_slider.val=0
timer0.en=1 timer0.en=1
@@ -664,7 +671,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -678,7 +685,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -692,7 +699,7 @@ Hotspot decrease_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }
@@ -729,7 +736,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -743,7 +750,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -757,7 +764,7 @@ Hotspot increase_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }

View File

@@ -20,6 +20,7 @@ Page buttonpage01
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage02
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage03
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage04
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -190,6 +190,13 @@ Variable (int32) temp_gap
Scope: local Scope: local
Value: 0 Value: 0
Variable (string) dec_separator
Attributes
ID : 55
Scope : local
Text : .
Max. Text Size: 5
Text current_temp Text current_temp
Attributes Attributes
ID : 3 ID : 3
@@ -567,7 +574,7 @@ Slider slider_high
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
timer1.en=1 timer1.en=1
active_slider.val=1 active_slider.val=1
@@ -600,7 +607,7 @@ Slider slider_low
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
timer2.en=1 timer2.en=1
active_slider.val=2 active_slider.val=2
@@ -625,7 +632,7 @@ Slider climateslider
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
active_slider.val=0 active_slider.val=0
timer0.en=1 timer0.en=1
@@ -664,7 +671,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -678,7 +685,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -692,7 +699,7 @@ Hotspot decrease_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }
@@ -729,7 +736,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -743,7 +750,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -757,7 +764,7 @@ Hotspot increase_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }

View File

@@ -20,6 +20,7 @@ Page buttonpage01
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage02
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage03
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -20,6 +20,7 @@ Page buttonpage04
vis 255,0 vis 255,0
vis button_back,1 vis button_back,1
vis page_index,1 vis page_index,1
vis page_label,1
} }
Postinitialize Event Postinitialize Event

View File

@@ -190,6 +190,13 @@ Variable (int32) temp_gap
Scope: local Scope: local
Value: 0 Value: 0
Variable (string) dec_separator
Attributes
ID : 55
Scope : local
Text : .
Max. Text Size: 5
Text current_temp Text current_temp
Attributes Attributes
ID : 3 ID : 3
@@ -567,7 +574,7 @@ Slider slider_high
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
timer1.en=1 timer1.en=1
active_slider.val=1 active_slider.val=1
@@ -600,7 +607,7 @@ Slider slider_low
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
timer2.en=1 timer2.en=1
active_slider.val=2 active_slider.val=2
@@ -625,7 +632,7 @@ Slider climateslider
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
active_slider.val=0 active_slider.val=0
timer0.en=1 timer0.en=1
@@ -664,7 +671,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -678,7 +685,7 @@ Hotspot decrease_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -692,7 +699,7 @@ Hotspot decrease_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }
@@ -729,7 +736,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number0.val%10 va0.val=temp_number0.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==1) }else if(active_slider.val==1)
@@ -743,7 +750,7 @@ Hotspot increase_temp
covx va0.val,target_high.txt,0,0 covx va0.val,target_high.txt,0,0
va0.val=temp_number1.val%10 va0.val=temp_number1.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_high.txt+="."+va1.txt target_high.txt+=dec_separator.txt+va1.txt
target_high.txt+=temp_unit.txt target_high.txt+=temp_unit.txt
} }
}else if(active_slider.val==2) }else if(active_slider.val==2)
@@ -757,7 +764,7 @@ Hotspot increase_temp
covx va0.val,target_low.txt,0,0 covx va0.val,target_low.txt,0,0
va0.val=temp_number2.val%10 va0.val=temp_number2.val%10
covx va0.val,va1.txt,0,0 covx va0.val,va1.txt,0,0
target_low.txt+="."+va1.txt target_low.txt+=dec_separator.txt+va1.txt
target_low.txt+=temp_unit.txt target_low.txt+=temp_unit.txt
} }
} }

View File

@@ -0,0 +1,440 @@
Page utilities2
Attributes
ID : 0
Scope : local
Dragging : 0
Send Component ID : on press and release
Locked : no
Swide up page ID : disabled
Swide down page ID : disabled
Swide left page ID : disabled
Swide right page ID: disabled
Events
Preinitialize Event
if(api==0)
{
page home
}
vis unavailable,0
Postinitialize Event
sendme
Text title
Attributes
ID : 1
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : Power Dashboard
Max. Text Size : 100
Text title_icon
Attributes
ID : 2
Scope : local
Dragging : 0
Send Component ID : on press and release
Associated Keyboard: none
Text : 
Max. Text Size : 10
Text unavailable
Attributes
ID : 5
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text :
Max. Text Size : 1
Text t1
Attributes
ID : 6
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 賈
Max. Text Size : 4
Text t2
Attributes
ID : 7
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 4
Text t3
Attributes
ID : 8
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 
Max. Text Size : 4
Text t4
Attributes
ID : 9
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Green
Max. Text Size : 10
Text t5
Attributes
ID : 10
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Fossil
Max. Text Size : 10
Text t7
Attributes
ID : 13
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 全
Max. Text Size : 4
Text t8
Attributes
ID : 14
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Solar
Max. Text Size : 10
Text t9
Attributes
ID : 16
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 98%
Max. Text Size : 10
Text t10
Attributes
ID : 17
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 2%
Max. Text Size : 10
Text t11
Attributes
ID : 18
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 豈
Max. Text Size : 4
Text t12
Attributes
ID : 19
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Battery
Max. Text Size : 10
Text t13
Attributes
ID : 21
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 暑
Max. Text Size : 4
Text t14
Attributes
ID : 22
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Heating
Max. Text Size : 10
Text t15
Attributes
ID : 24
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 1.7 kW
Max. Text Size : 10
Text t16
Attributes
ID : 25
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 21.7°C
Max. Text Size : 10
Text t17
Attributes
ID : 26
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 1.1 kW
Max. Text Size : 10
Text t18
Attributes
ID : 27
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : -2.1 kW
Max. Text Size : 10
Text t19
Attributes
ID : 28
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 0.8 kW
Max. Text Size : 10
Text t20
Attributes
ID : 29
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 慎
Max. Text Size : 4
Text t21
Attributes
ID : 30
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Wind
Max. Text Size : 10
Text t22
Attributes
ID : 32
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 1.1 kW
Max. Text Size : 10
Text t23
Attributes
ID : 33
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : î—°
Max. Text Size : 4
Text t24
Attributes
ID : 34
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Car
Max. Text Size : 10
Text t25
Attributes
ID : 36
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 1.1 kW
Max. Text Size : 10
Text t0
Attributes
ID : 37
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : î—°
Max. Text Size : 4
Text t6
Attributes
ID : 38
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Car
Max. Text Size : 10
Text t26
Attributes
ID : 40
Scope : local
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 1.1 kW
Max. Text Size : 10
Slider h1
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h2
Attributes
ID : 12
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h3
Attributes
ID : 15
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h4
Attributes
ID : 20
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h5
Attributes
ID : 23
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h6
Attributes
ID : 31
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h7
Attributes
ID : 35
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Slider h0
Attributes
ID : 39
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 50
Upper range limit: 100
Lower range limit: 0
Button button_back
Attributes
ID : 3
Scope : local
Dragging : 0
Send Component ID: on press and release
State : unpressed
Text : î…˜
Max. Text Size : 3
Events
Touch Press Event
page back_page_id
Timer wakeup_timer
Attributes
ID : 4
Scope : local
Period (ms): 100
Enabled : yes
Events
Timer Event
if(dim<brightness)
{
dimdelta=brightness-dim
dimdelta/=10
if(dimdelta<1)
{
dimdelta=1
}
dim+=dimdelta
}else
{
wakeup_timer.en=0
}