diff --git a/homekey-test-c3.yaml b/homekey-test-c3.yaml index 9af7657..efd0626 100644 --- a/homekey-test-c3.yaml +++ b/homekey-test-c3.yaml @@ -53,10 +53,15 @@ homekit: lambda: |- ESP_LOGI("HEREHERE", "IssuerID: %s", x.c_str()); ESP_LOGI("HEREHERE", "EndpointID: %s", y.c_str()); + if (id(this_lock).state == LOCK_STATE_LOCKED) { + id(this_lock).unlock(); + } else { + id(this_lock).lock(); + } on_hk_fail: lambda: |- ESP_LOGI("GSDGSGS", "IT FAILED :("); hk_hw_finish: "SILVER" logger: - level: DEBUG \ No newline at end of file + level: DEBUG