@@ -1005,15 +1005,15 @@ namespace esphome
10051005 return result;
10061006 }
10071007
1008- void SEN5XComponent::set_ambient_pressure_compensation (float pressure_in_hpa)
1008+ bool SEN5XComponent::set_ambient_pressure_compensation (float pressure_in_hpa)
10091009 {
10101010 if (this ->model_ .value () == SEN63C || this ->model_ .value () == SEN66)
10111011 {
10121012 uint16_t new_ambient_pressure = (uint16_t )pressure_in_hpa;
10131013 if (!this ->initialized_ )
10141014 {
10151015 this ->co2_ambient_pressure_ = new_ambient_pressure;
1016- return ;
1016+ return false ;
10171017 }
10181018 // Only send pressure value if it has changed since last update
10191019 if (new_ambient_pressure != this ->co2_ambient_pressure_ )
@@ -1026,6 +1026,7 @@ namespace esphome
10261026 {
10271027 ESP_LOGD (TAG, " Ambient Pressure compensation skipped - no change required" );
10281028 }
1029+ return true ;
10291030 }
10301031 else
10311032 {
@@ -1043,7 +1044,7 @@ namespace esphome
10431044 {
10441045 ESP_LOGE (TAG, ESP_LOG_MSG_FAN_CLEAN_FAIL);
10451046 this ->initialized_ = true ;
1046- return true ;
1047+ return false ;
10471048 }
10481049 this ->set_timeout (1000 , [this ]()
10491050 {
@@ -1093,7 +1094,7 @@ namespace esphome
10931094 {
10941095 ESP_LOGE (TAG, ESP_LOG_MSG_ACT_SHT_HEATER_FAIL);
10951096 this ->initialized_ = true ;
1096- return true ;
1097+ return false ;
10971098 }
10981099 this ->set_timeout (1000 , [this ]()
10991100 {
@@ -1139,7 +1140,7 @@ namespace esphome
11391140 {
11401141 ESP_LOGE (TAG, ESP_LOG_MSG_CO2_CAL_FAIL);
11411142 this ->initialized_ = true ;
1142- return true ;
1143+ return false ;
11431144 }
11441145 this ->set_timeout (1000 , [this , co2]()
11451146 {
0 commit comments