automations.yaml, zigbee2mqtt/state.json
This commit is contained in:
1 parent
b3d9ae54fa
commit
4192ecbaae
2 files changed
+32
-26
No files matched your search
+24
-18
@@ -4213,10 +4213,11 @@
|
||||
mode: restart
|
||||
- id: sparkx_i7_cfs_auto_recover
|
||||
alias: SparkX i7 - CFS Info Auto Recover
|
||||
description: The ha_creality_ws integration drops its CFS sensors to unavailable
|
||||
description: 'The ha_creality_ws integration drops its CFS sensors to unavailable
|
||||
whenever the integration is reloaded, and they only come back when the printer
|
||||
is asked. This re-requests CFS info after a sustained outage, with a settle delay
|
||||
and a re-check so a brief reload gap does not cause a spurious request.
|
||||
is asked. A state trigger only fires on the transition, so this retries the recovery
|
||||
rather than relying on a single attempt: up to 3 tries spaced 2 minutes apart,
|
||||
then it gives up and writes a logbook entry instead of retrying forever.'
|
||||
triggers:
|
||||
- entity_id: sensor.sparkx_i7_cfs_box_1_temperature
|
||||
id: cfs_unavailable
|
||||
@@ -4240,24 +4241,29 @@
|
||||
sequence:
|
||||
- delay:
|
||||
seconds: 60
|
||||
- repeat:
|
||||
count: 3
|
||||
sequence:
|
||||
- else: []
|
||||
if:
|
||||
- condition: template
|
||||
value_template: '{{ is_state(''sensor.sparkx_i7_cfs_box_1_temperature'',
|
||||
''unavailable'') }}'
|
||||
then:
|
||||
- action: ha_creality_ws.request_cfs_info
|
||||
target:
|
||||
device_id: 1196bfc60ac925f3874be27098978ef6
|
||||
- delay:
|
||||
seconds: 30
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ is_state(''sensor.sparkx_i7_cfs_box_1_temperature'', ''unavailable'')
|
||||
}}'
|
||||
then:
|
||||
- action: ha_creality_ws.request_cfs_info
|
||||
target:
|
||||
device_id: 1196bfc60ac925f3874be27098978ef6
|
||||
- delay:
|
||||
seconds: 30
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: '{{ is_state(''sensor.sparkx_i7_cfs_box_1_temperature'', ''unavailable'')
|
||||
}}'
|
||||
then:
|
||||
- action: logbook.log
|
||||
data:
|
||||
entity_id: sensor.sparkx_i7_cfs_box_1_temperature
|
||||
message: CFS info still unavailable 30s after request_cfs_info
|
||||
name: SparkX i7 CFS
|
||||
- action: logbook.log
|
||||
data:
|
||||
entity_id: sensor.sparkx_i7_cfs_box_1_temperature
|
||||
message: CFS info still unavailable after 3 recovery attempts; giving up until
|
||||
the next state change
|
||||
name: SparkX i7 CFS
|
||||
mode: single
|
||||
Reference in new issue
Block a user