Automation help climate.heating

Hi,

Looking for some help with an automation…

Basically, I want to send a notification to my LG TV when the heating is above a certain temperature…I have other automations that send a message to my tv so I know that works but I’m not sure if I’ve got this particular automation correct

- id: '1582565127427'
  alias: Heating Notify
  description: ''
  trigger:
  - above: '18'
    entity_id: climate.heating
    platform: numeric_state
  condition: []
  action:
  - data:
      data:
        icon: /config/images/hive.png
      message: Heating is now at 18
    service: notify.tv

Is numeric_state correct for this? This particular entity (climate.heating) has a state attribute of ‘current_temperature’ so not sure if I should be using that?

Thanks

Check out this thread:

Template Sensor is the way to go here I believe.

1 Like

You need a template trigger for this because you want to check an attribute of an antity, as you have it now it takes the state from the entity (auto, heat, cool…).

Try with a teigger like this:

trigger:
  platform: template
  value_template: "{{ state_attr('climate.heating', 'current_temperature') | int > 18 }}"

Should it look like this?

- id: '1582565127427'
  alias: Heating Notify
  description: ''
  trigger:
  platform: template
  value_template: "{{ state_attr('climate.heating', 'current_temperature') | int > 18 }}"
  entity_id: climate.heating
  condition: []
  action:
  - data:
      data:
        icon: /config/images/hive.png
      message: Heating is now at 18
    service: notify.tv

Sorry, all new to the automations! - I try to do most stuff in the GUI…

The indentation is off, try like rhis:

- id: '1582565127427'
  alias: Heating Notify
  description: ''
  trigger:
    platform: template
    value_template: "{{ state_attr('climate.heating', 'current_temperature') | int > 18 }}"
  action:
  - data:
      data:
        icon: /config/images/hive.png
      message: Heating is now at 18
    service: notify.tv

Will give this a try now, thank you