Binary Template Sensor never updating

I can not get the binary template to update on change. This is a Fibaro Door Sensor 2 and only shows up with access_control sensor. So i need to add the binary template. But the binary sensor will not update. I can see the access_control sensor is updating correct. Tried with and without add the entity_id

Any ideas why it is not updating?

binary_sensor:
  - platform: template
    sensors:
      bathroom_window_manualy:
        friendly_name: "Badezimmer Fenster"
        device_class: window
        entity_id: sensor.fibaro_system_fgdw002_door_opening_sensor_2_access_control_3
        value_template: >-
          {{ is_state('sensor.fibaro_system_fgdw002_door_opening_sensor_2_access_control_3', 22) }}

All states are strings. You are comparing a string to a number. You need to put the number 22 in quotes to make it a string and it should update.

1 Like