From 18adc0975e84e822c03eb90cfc614500564dd437 Mon Sep 17 00:00:00 2001 From: patagona Date: Mon, 11 Nov 2024 22:27:22 +0100 Subject: [PATCH] DALY Modbus BMS: fix cell voltage publish --- esphome/components/daly_hkms_bms/daly_hkms_bms.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esphome/components/daly_hkms_bms/daly_hkms_bms.cpp b/esphome/components/daly_hkms_bms/daly_hkms_bms.cpp index 495cbaddfa..6bbb9008b2 100644 --- a/esphome/components/daly_hkms_bms/daly_hkms_bms.cpp +++ b/esphome/components/daly_hkms_bms/daly_hkms_bms.cpp @@ -128,7 +128,7 @@ void DalyHkmsBmsComponent::on_modbus_data(const std::vector &data) { if (this->read_state_ == ReadState::READ_CELL_VOLTAGES) { #ifdef USE_SENSOR for (size_t i = 0; i < this->cell_voltage_sensors_max_; i++) { - publish_sensor_state(this->cell_voltage_sensors_[i], register_offset, DALY_MODBUS_ADDR_CELL_VOLT_1 + i, 0, 0.001); + publish_sensor_state(this->cell_voltage_sensors_[i], DALY_MODBUS_ADDR_CELL_VOLT_1 + i, 0, 0.001); } #endif } else if (this->read_state_ == ReadState::READ_DATA) {