Lovelace Climate Card with alternative temperature entity

In my Bathroom I’m using an electric heater. There is a temperature sensor on board, nevetheless this is not accurate. I added a separate temperature sensor in the bathroom which is placed on a better position.

Now I would like to use the Climate Card (as I use for other rooms/thermostats as well) but would like to change the actual temperature of the Heater with the measurement from the sensor. Is that possible in any way?

image

Heater: Eurom Alutherm, controlled by Tuya
Integration: Tuya Local
Sensor: Aqara temperature sensor

Ok ok, I managed to get it working myself (with lot’s of try-ing and error-ing). Perhaps as input for other HA starters?

First of all I learned not to use the ‘normal’ Thermostat card, instead I used the Generic Thermostat

# Thermostat
climate:
  - platform: generic_thermostat
    name: Thermostat Bathroom
    heater: switch.bathroom_heater_switch
    target_sensor: sensor.bathroom_sensor_temperature
    target_temp_step: 0.5
    precision: 0.1

Target Sensor off course is the separate sensor in the bathroom.

I had to apply one trick here. As this Generic Thermostat in designed to be used with a wall switch, not directly with a tuya controlled heater. I’ve created a ‘switch’ which changes the attribute of my heater:

#Bathroom Heater to Switch
- platform: template
  switches:
    bathroom_heater_switch:
      turn_on:
        service: climate.set_hvac_mode
        data:
          hvac_mode: heat
        target:
          entity_id: climate.bathroom_heater
      turn_off:
        service: climate.set_hvac_mode
        data:
          hvac_mode: "off"
        target:
          entity_id: climate.bathroom_heater

The set temperature I’ve controlled from another automation (time / location / etc. based). By calling the ‘climate.set_temperature’ service in that automation.

      - service: climate.set_temperature
        data:
          temperature: 18
        target:
          entity_id: climate.thermostat_bathroom

Hopefully this post is clear enough to understand what I’ve been doing here. In best case it lead up to some inspiration :wink:

1 Like