diff --git a/config.schema.json b/config.schema.json index f07f6d6..4cdb662 100644 --- a/config.schema.json +++ b/config.schema.json @@ -67,8 +67,8 @@ "description": "Lock default state", "type": "string", "oneOf": [ - { "title": "Unlocked", "enum": ["unlocked"] }, - { "title": "Locked", "enum": ["locked"] } + { "title": "Locked", "enum": ["locked"] }, + { "title": "Unlocked", "enum": ["unlocked"] } ], "condition": { "functionBody": "return model.devices[arrayIndices].accessoryType === 'lock';" diff --git a/package-lock.json b/package-lock.json index 8af9888..7667791 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "homebridge-virtual-accessories", - "version": "1.0.1", + "version": "1.0.2", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "homebridge-virtual-accessories", - "version": "1.0.1", + "version": "1.0.2", "license": "Apache-2.0", "dependencies": { "@js-joda/core": "^5.6.3", diff --git a/package.json b/package.json index ae5c7c9..a79e952 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "homebridge-virtual-accessories", "displayName": "Virtual Accessories for Homebridge", "type": "module", - "version": "1.0.1", + "version": "1.0.2", "description": "Virtual accessories for Homebridge.", "author": "justjam2013", "license": "Apache-2.0", @@ -23,9 +23,11 @@ "virtual accessories", "switch", "virtual switch", - "delay switch", + "delay", + "timer", "lock", "virtual lock", + "homekey", "doorbell", "virtual doorbell", "garage door", diff --git a/src/accessories/virtualAccessoryLock.ts b/src/accessories/virtualAccessoryLock.ts index 8fe3b4e..2a3d01b 100644 --- a/src/accessories/virtualAccessoryLock.ts +++ b/src/accessories/virtualAccessoryLock.ts @@ -9,9 +9,9 @@ import { Accessory } from './virtualAccessory.js'; export class Lock extends Accessory { static readonly UNSECURED: number = 0; // Characteristic.LockCurrentState.UNSECURED; - static readonly SECURED: number = 0; // Characteristic.LockCurrentState.SECURED; - static readonly JAMMED: number = 0; // Characteristic.LockCurrentState.JAMMED; - static readonly UNKNOWN: number = 0; // Characteristic.LockCurrentState.UNKNOWN; + static readonly SECURED: number = 1; // Characteristic.LockCurrentState.SECURED; + static readonly JAMMED: number = 2; // Characteristic.LockCurrentState.JAMMED; + static readonly UNKNOWN: number = 3; // Characteristic.LockCurrentState.UNKNOWN; /** * These are just used to create a working example