I have looked in the developer tools to see the state names and they are Idle and Heating Cycle.
I created an automation like this:
alias: Boiler needs stirring
description: When it is firing, but O2 is > 5% the coal bed isn't right
trigger:
- platform: state
entity_id:
- sensor.heatmaster_boiler_status
from: Idle
to: Heating Cycle
for:
hours: 0
minutes: 5
seconds: 0
condition:
- condition: numeric_state
entity_id: sensor.heatmaster_o2
above: 7
action:
- service: notify.david_text
data:
message: Boiler needs stirred
mode: single
I want to receive a text message after the boiler has moved from Idle to Heating Cycle, wait for 5 minutes for the fire to get started, then check the O2 reading. If it is above 7%, then text me. That means it is not running correctly and I need to take action.
When I do this I can see that the state changes, but I never get a message even when the O2 level was 10%
I then simplified it to just text me when changing from Heating Cycle to Idle:
alias: Test state change
description: ""
trigger:
- platform: state
entity_id:
- sensor.heatmaster_boiler_status
from: Heating Cycle
to: Idle
condition: []
action:
- service: notify.david_text
data:
message: Heating Cycle comlete
mode: single
And the state changed, but no message. I did run it manually and got a message.
Are you sure those are the correct states in the dev tools states list? Not that it’s unheard of but typically core integrations don’t capitalize the true states.
the states you see in most of the user interfaces in HA are actually translated states from the true state to “pretty” things up for the user.
even in the history graphs the states there are translated states as well.
The ‘status’: furnace.strip() string is either Idle, Bypass, Heating Cycle, or Timer
So I thought that meant the value I would look for matched those strings. I do see in the table Idle and Heating Cycle. So I thought that is what I should be looking for.
I’ll try removing the capitalization to see if that helps.
That falls under the caveat of a “core integration” since you created the sensors using the rest integration it didn’t follow the standard of no capitalization. Which to be clear isn’t an issue. I have several self created sensors that are capitalized.
as long as the state in the table below matches the state in the trigger exactly it should work.
so now that we have that verified as valid then we get back to the original problem…
Are you sure that there isn’t a temporary intermediate step that isn’t “Idle”?
if it goes from “Idle” to something else and then to “Heating Cycle” it won’t trigger.
try removing the “from: Idle” requirement from the trigger to see if that works.
Also just an FYI, if you don’t hit the reply button at the bottom of my post or tag me in the reply then I don’t get a notification that you replied to me. I’ll only see it if I happen to look in my unread topics.
Confirm the sensor’s state value doesn’t contain a leading/trailing space character. It shouldn’t, because of furnace.strip(), but best to confirm it.
Copy-paste the following template into the Template Editor and confirm it reports the correct number of characters for the sensor’s value (4 for Idle and 13 for Heating Cycle).
That’s due to my mistake. My example contains the wrong sensor name. The name starts with the word heatmaster not heating. I have corrected the example.
13 characters is correct so you have confirmed there are no leading/trailing space characters that could potentially trip up your State Trigger.
I made a new automation that just said state Idle. That did trigger when it went from Heating Cycle to Idle. I at least know that Idle is the correct name
There are several states, Idle, Heating Cycle, Bypass, Timer, and when things to wrong unknown.
I wanted to have Idle->Heating Cycle specifically. I did change it to just be Heating Cycle, to test if it works like Idle did. Then I can get more complicated.
The slugify changes it lower case and replaces space with underscores. After making that change, I can then use the new state name heating_cycle and it works.
I tried quotes and it doesn’t do anything. I may try backslashing the space, but not sure that will work.
If I can figure out how to make a friendly name of Heating Cycle. I’d be happy. I tried addiing it to the configuration.yaml, but it reported an error.