Haustüröffner mit IPhone und NFC

@IckeHH
ich habe es so gelöst, dass wenn eine Person in die Home Zone kommt, dies getriggert wird.
Dann wird bis 30 Min. gewartet, ob geklingelt wird. Beim klingeln wird noch mal geprüft, ob die Person, die getriggert wurde, immer noch in der Home Zone ist (könnte man auch auf Wlan-Verbindung prüfen o.ä.).
Und erst dann werden die Türen geöffnet.

description: ""
mode: restart
trigger:
  - platform: zone
    entity_id: person.xyz
    zone: zone.home
    event: enter
    id: xyz-home
  - platform: zone
    entity_id: person.maxe
    zone: zone.home
    event: enter
    id: maxe-home
condition: []
action:
  - wait_for_trigger:
      - platform: state
        entity_id:
          - binary_sensor.haustuer_ding
        to: "on"
    continue_on_timeout: false
    timeout:
      hours: 0
      minutes: 30
      seconds: 0
      milliseconds: 0
  - choose:
      - conditions:
          - condition: trigger
            id:
              - xyz-home
        sequence:
          - condition: zone
            entity_id: person.xyz
            zone: zone.home
          - service: lock.unlock
            data: {}
            target:
              entity_id:
                - lock.haustuer_lock
          - service: lock.open
            data: {}
            target:
              entity_id: lock.wohnungstuer
      - conditions:
          - condition: trigger
            id:
              - maxe-home
        sequence:
          - condition: zone
            entity_id: person.maxe
            zone: zone.home
          - service: lock.unlock
            data: {}
            target:
              entity_id: lock.haustuer_lock
          - service: lock.open
            data: {}
            target:
              entity_id: lock.wohnungstuer
    default: []
    enabled: true