1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-08 14:22:21 +01:00

fix: add lamp index to active lamps in DynamicLamp management

This commit is contained in:
Oliver Kleinecke
2025-02-15 12:54:39 +01:00
parent 3e9710c4d6
commit 3b3449b3ec
2 changed files with 3 additions and 1 deletions

View File

@@ -115,6 +115,7 @@ void DynamicLamp::add_lamp_(std::string name) {
this->lamp_count_++;
this->active_lamps_[this->lamp_count_].active = true;
this->active_lamps_[this->lamp_count_].name = name;
this->active_lamps_[this->lamp_count_].lamp_index = this->lamp_count_;
return;
}
ESP_LOGW(TAG, "No more lamps available, max 16 lamps supported!");