local device = {} device.model = "ZNMS13LM" device.vendor = "Aqara" device.description = "Smart door lock S2 Pro" device.zigbeeModel = { "lumi.lock.acn03" } device.exposes = { { type = "binary", name = "state", property = "state", access = 1, value_on = "UNLOCK", value_off = "LOCK", }, { type = "binary", name = "reverse", property = "reverse", access = 1, value_on = "UNLOCK", value_off = "LOCK", }, { type = "enum", name = "action", property = "action", access = 1, description = "Triggered action (e.g. a button click)", category = "diagnostic", values = { "finger_not_match", "password_not_match", "reverse_lock", "reverse_lock_cancel", "locked", "lock_opened", "finger_add", "finger_delete", "password_add", "password_delete", "lock_opened_inside", "lock_opened_outside", "ring_bell", "change_language_to", "finger_open", "password_open", "door_closed", }, }, } device.fromZigbee = { "door_lock" } device.configure = { bind = { "closuresDoorLock" }, reporting = { { cluster = "closuresDoorLock", attribute = "lockState", min = 0, max = 3600, change = 0, }, }, } return device