Hi, I have this code and the icon of my sensor doesn’t change when the value changes
rest:
- resource: http://192.168.100.207/getVariables
scan_interval: 5
sensor:
- name: "Status"
value_template: "{{ value_json.Status }}"
unique_id: "rgbclockStatus"
icon: >-
{% if is_state(value_json.Status,"ON") %}
mdi:lightbulb-on
{% else %}
mdi:lightbulb-off
{% endif %}
This is what my rest call returns:
{
"Status": "ON",
"Mode": "Clock12",
"Selected_Effect": "SolidFill",
"Parameters": {
"Color1": 255,
"Color2": 170,
"Brightness1": 150,
"Brightness2": 50,
"Effect_Speed": 1
}
}
1 post - 1 participant