-
Notifications
You must be signed in to change notification settings - Fork 7
Description
The climate entity in Home Assistant defines the temperature_unit for °C or °F. According to the documentation this should be a required property.
In Remote Two, the correct unit handling is prepared, but not yet verified (#10).
However, the generic thermostat does not support custom temperature units, and simply takes the configured HA system unit:
- https://github.com/home-assistant/core/blob/2023.10.1/homeassistant/components/generic_thermostat/climate.py#L146
- Generic Thermostat unit does not match the unit of its sensor home-assistant/core#74998
This can be verified with the Remote Two Core-simulator and the prepared thermostat entities.
The temperature unit works as long as the HA unit system matches the Remote Two localization. For mixed environments or special use cases, this doesn't work correctly.
Proposed enhancements:
- To use the same unit system, the HA configuration needs to be read and set into all climate entities, which don't specify a
temperature_unitoption.
This will force the temperature values of all entities to the configured HA unit system and display the same value as in the HA dashboard. Switching the Remote Two units, won't change the temperature label anymore. - Add a configuration option in the HA integration setup to choose the temperature unit behaviour:
- Use Remote Two setting if entity is missing
temperature_unit(current behaviour) - Use Home Assistant setting if entity is missing
temperature_unit - Force Celsius if missing
- Force Fahrenheit if missing
- Use Remote Two setting if entity is missing
How to get the HA configuration:
- WS request:
get_config - https://developers.home-assistant.io/docs/api/websocket/#fetching-config
- The HA configuration could be fetched once after integration startup. The unit system shouldn't be reconfigured all the time.
Note: the °C / °F handling is not yet fully working in firmware 1.3.x. This is currently being worked on.