Fix ethernet connection timeout issue caused by incorrect time value during setup (#8841)

This commit is contained in:
J. Nick Koston 2025-05-19 01:25:21 -04:00 committed by Jesse Hills
parent aed7ef481e
commit afa7414ee1
No known key found for this signature in database
GPG Key ID: BEAAE804EFD8E83A

View File

@ -35,6 +35,8 @@ void Application::setup() {
for (uint32_t i = 0; i < this->components_.size(); i++) {
Component *component = this->components_[i];
// Update loop_component_start_time_ before calling each component during setup
this->loop_component_start_time_ = millis();
component->call();
this->scheduler.process_to_add();
this->feed_wdt();
@ -49,6 +51,8 @@ void Application::setup() {
this->scheduler.call();
this->feed_wdt();
for (uint32_t j = 0; j <= i; j++) {
// Update loop_component_start_time_ right before calling each component
this->loop_component_start_time_ = millis();
this->components_[j]->call();
new_app_state |= this->components_[j]->get_component_state();
this->app_state_ |= new_app_state;