[Solved] CT101 ZWave Thermostat hvac_action attribute disappears when AC is running

So I was just looking for a way to log when my AC runs, and I noticed that the hvac_action attribute says ‘idle’ when it’s not running, and just completely disappears when the AC turns on. Is this happening for anyone else on their thermostat? I’m looking at the states page.

I’m running 0.96. Not sure if this is related to this version because of all the changes in the climate component or if this is how it’s always been.

In 0.95.4 I don’t have a hvac_action but an operateing_state and it does toggle from Cooling to Pending Cool to Idle

Try updating to 0.96.1. Might be fixed by this.

1 Like

Hvac action is a new thing in .96.

Wow. That was definitely not there when I made this post. I’ll try it now.

Edit: Looks like I will have to wait. The update isn’t showing up for hassio. They have to update that json file.

That was it. I just updated it and it now shows ‘cooling’ when it’s cooling. Now I have to figure out how to make some kind of sensor or report that can tell me how many hours it runs in an hour.

I use a history_stats sensor for that.

I have a template binary sensor that tracks A/C on/off and uses the history stats platform to keep track of time per day (12am-now).

binary sensor:

- platform: template
  sensors:
    ac_on:
      friendly_name: 'Air Conditioner Running'
      device_class: cold
      value_template: "{{ is_state_attr('climate.home', 'cool_on', True) }}"

sensor:

- platform: history_stats
  name: AC On today
  entity_id: binary_sensor.ac_on
  state: 'on'
  type: time
  start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
  end: '{{ now() }}'
2 Likes

Hi, this is my thermostat component (see image). I want to tack heating time, but i’m not sure how to write the device_class section and the value_template. When heating is running i can see hvac_action change from ‘idle’ to ‘heating’… How should i use this in value_template and device_class?
Thank you