Set the State of a Sensor - How?

How do I chance the state of a sensor?

My RF433 Door switch only sends a signal when the door is opened. This leaves my sensor hanging in the state “Alarm Tamper”, but I have no chance setting the state back to “Door Closed” unless I restart HASS. This renders my switches useless!

My thought was to reset the sensor after 60 sec. - but How???

ba5171f58ed2b45c417d1e8c7c8ef94a4610385d_1_319x500-1!

Can’t you do it in an automation…

trigger on alarm_state
action
delay 30s
service homeassistant.turn_off
entity_id: rf433door_switch

The spacing etc. is off but that should work :slight_smile:

Th problem (I think) is that it is not a switch but a sensor:

sensor doorswitch433_1:
  platform: rfxtrx
  devices:
    '08200000257f708123':
      name: '433 Door Switch 001'
      fire_event: true
1 Like

But HA doesn’t need to know that does it? HA responds to what you tell it :slight_smile:

I’ve tried to do it that way but it doesn’t allow me to set the state of a sensor with a service call. I have to do it in the entities page manually. It would be really nice if this could be done with a service call because some of my zwave devices get stuck in the wrong state.