My problem is that even when I have a temperature set (let’s say 25ºC when room temperature is 23ºC), it still shows ‘Idle’ and it doesn’t seem to turn on the plug (in my example switch.tomada_sala).
Can you try changing the temperature, just to check what should appear next to the temperature (should be Heat?)?
Yes, I do get “Heat” instead of Idle, when the ambient temperature is LOWER than the set temperature. But what you have is a different issue then your first one You have to post your generic thermostat configuration, and also let us know what plug are you using to control (I presume) the electric heater.
Please use the preformatted text in the editor when posting the configuration (the </> icon).
Does the switch actually turn on? I’ve had issues with tp-link switches where they just stop responding to commands and queries. Can you check whether you can turn the switch at all, maybe it’s crashed. Inspecting the log (located in .homeassistant/home-assistant.log) can help as well
I think that’s the problem - remove the quotation marks around 20! This way you are passing a string, and not a number. Remove the quotes and give it another try and report back
Even if that was the case, once I would change the temperature to one that should trigger the switch - from within the UI (not via automation), plug should be turned on… and it is not!
I think I have been playing before with set_away and set_mode methods and that may have caused any issue. I already tried changing the entity name, to see if it would make a difference, but also no…
I tried adding min_cycle_duration and it actually seems to have started to work.
I will need to test more when I have the time, namely the usage you suggested of the input_boolean to turn the thermostat off/on (on restart, even if the previous input_boolean state is being reinstated after a restart using recorder, the thermostat temperature value is not being set accordingly).
My “thermostat” is per-room. I.e. there’s a temperature sensor that reports the room’s ambient temperature and a “smart socket” - e.g. TP-Link HS110 - that turns on an electric heater. Heaters are rated at 1.250 kWs so they don’t exceed the HS110s power rating.
Yes, I do use electric heaters. If you have a central gas heater, I don’t think you should be using an electric switch to control the gas heater itself.
It is really clear if I can use service climate.turn_on or climate.turn_off to turn the thermostat on or off. set_operation_mode to HEAT or OFF is not very straight forward.
I set mine to off whenever someone arrives home (for WAF reasons)
- alias: set temp when home
trigger:
platform: state
entity_id: group.tracking
from: 'not_home'
to: 'home'
action:
- service: climate.set_operation_mode
data:
entity_id: climate.thermostat
operation_mode: "off"