1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-20 12:12:24 +01:00

Optimize Component and Application state storage from uint32_t to uint8_t (#9082)

This commit is contained in:
J. Nick Koston
2025-06-14 21:48:53 -05:00
committed by GitHub
parent dcfe7af9d3
commit 374c33e8dc
9 changed files with 65 additions and 36 deletions

View File

@@ -66,7 +66,7 @@ void Application::setup() {
[](Component *a, Component *b) { return a->get_loop_priority() > b->get_loop_priority(); });
do {
uint32_t new_app_state = STATUS_LED_WARNING;
uint8_t new_app_state = STATUS_LED_WARNING;
this->scheduler.call();
this->feed_wdt();
for (uint32_t j = 0; j <= i; j++) {
@@ -87,7 +87,7 @@ void Application::setup() {
this->calculate_looping_components_();
}
void Application::loop() {
uint32_t new_app_state = 0;
uint8_t new_app_state = 0;
this->scheduler.call();