diff --git a/weconnect/elements/temperature_battery_status.py b/weconnect/elements/temperature_battery_status.py index 55f85d6..9baa0bc 100644 --- a/weconnect/elements/temperature_battery_status.py +++ b/weconnect/elements/temperature_battery_status.py @@ -2,6 +2,7 @@ from weconnect.addressable import AddressableAttribute from weconnect.elements.generic_status import GenericStatus +from weconnect.util import kelvinToCelsius LOG = logging.getLogger("weconnect") @@ -38,5 +39,6 @@ def update(self, fromDict, ignoreAttributes=None): def __str__(self): string = super().__str__() if self.temperatureHvBatteryMin_K.enabled and self.temperatureHvBatteryMax_K.enabled: - string += f'\n\tBattery temperature between {self.temperatureHvBatteryMin_K.value} and {self.temperatureHvBatteryMax_K.value}°C' + string += f'\n\tBattery temperature between {kelvinToCelsius(self.temperatureHvBatteryMin_K.value)} and' \ + + f' {kelvinToCelsius(self.temperatureHvBatteryMax_K.value)}°C' return string