diff --git a/custom_components/solaredge_modbus/__init__.py b/custom_components/solaredge_modbus/__init__.py index 740223d..4f2d606 100644 --- a/custom_components/solaredge_modbus/__init__.py +++ b/custom_components/solaredge_modbus/__init__.py @@ -419,11 +419,11 @@ def read_modbus_data_meter(self, meter_prefix, start_address): importedc = decoder.decode_32bit_uint() energywsf = decoder.decode_16bit_int() - exported = validate(self.calculate_value(exported, energywsf), ">=", 0) + exported = validate(self.calculate_value(exported, energywsf), ">", 0) exporteda = self.calculate_value(exporteda, energywsf) exportedb = self.calculate_value(exportedb, energywsf) exportedc = self.calculate_value(exportedc, energywsf) - imported = validate(self.calculate_value(imported, energywsf), ">=", 0) + imported = validate(self.calculate_value(imported, energywsf), ">", 0) importeda = self.calculate_value(importeda, energywsf) importedb = self.calculate_value(importedb, energywsf) importedc = self.calculate_value(importedc, energywsf) @@ -641,7 +641,7 @@ def read_modbus_data_inverter(self): acenergy = decoder.decode_32bit_uint() acenergysf = decoder.decode_16bit_uint() - acenergy = validate(self.calculate_value(acenergy, acenergysf), ">=", 0) + acenergy = validate(self.calculate_value(acenergy, acenergysf), ">", 0) self.data["acenergy"] = round(acenergy * 0.001, 3) @@ -852,7 +852,7 @@ def decode_string(decoder): #0x82 - 2 - SoH % battery_SoH = decoder.decode_32bit_float() #0x84 - 2 - SoC % - battery_SoC = validate(decoder.decode_32bit_float(), ">=", 0.0) + battery_SoC = validate(decoder.decode_32bit_float(), ">", 0.0) battery_SoC = validate(battery_SoC, "<", 101) self.data[battery_prefix + 'temp_avg'] = round(tempavg, 1)