I have a number of alarm sensors, and want to keep a log of when each is being triggered. Is there any way of extending the automation below to write an entry to the log containing the name/id of the specific trigger when any of them is triggered?
alias: Sensor triggered - log only
mode: single
trigger:
- platform: state
entity_id: binary_sensor.pir_hall
to: 'on'
- platform: state
entity_id: binary_sensor.sonoff_pir_kitchen
to: 'on'
- platform: state
entity_id: binary_sensor.pir_study
to: 'on'
- platform: state
entity_id: binary_sensor.pir_lounge
to: 'on'
- platform: state
entity_id: binary_sensor.pir_garage
to: 'on'
- platform: state
entity_id: binary_sensor.front_door
to: 'on'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 1E667A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 1E667A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 0A720A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 0A720A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/zigbee-bridge/door/SENSOR
payload: '1'
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 085B0A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 085B0A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 412B0A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 412B0A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 08420A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 08420A
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge/RESULT
payload: 08420E
value_template: '{{ value_json.RfReceived.Data}}'
- platform: mqtt
topic: tele/rf-bridge2/RESULT
payload: 08420E
value_template: '{{ value_json.RfReceived.Data}}'