SecKatie / wyzeapy

35 stars 26 forks source link

#74 Adding support for UnLocking and Locking states for Wyze Lock #75

Closed GuillaumeB-GitHub closed 5 months ago

GuillaumeB-GitHub commented 1 year ago

This is to add support for UnLocking and Locking states for Wyze Lock. I tested locally with my Wyze lock.

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

lygris commented 1 year ago

will this add in door jammed/left open as well or is it possible to add that?

GuillaumeB-GitHub commented 12 months ago

That change doesn't include the support for door jammed/left open.

I looked into it and:

GuillaumeB-GitHub commented 12 months ago

Example of response from /openapi/lock/v1/info endpoint below. If you think we can use something for is_jammed, let me know.

{ "ReqID": "bc3f443086", "ErrNo": 0, "ErrMsg": "", "device": { "uuid": "fb130b12e8901ffe7ecd269bd64d0531", "device_type": "102051001000", "parent": "8084ebf0af07f9fade5d73e1748b9dc3", "hardware_info": { "sn": "lkjl0051210403647386", "mac": "1C64525DD4DB", "cid": "12-34-56-78-90", "versions": { "app_version": "2.1.22.0", "hardware_version": "1.5.0.0", "media_version": "0.0.0.0", "protocol_version": "0.0.0.6", "zigbee_version": "2.0.3.2", "fp_version": "0.0.0.0", "ble_version": "2.1.22.0" } }, "onoff_line": 1, "onoff_time": 1692662584551, "df": -1, "df_refreshtime": -1, "power": 11, "power_refreshtime": 1692675188944, "lqi": 255, "lqi_refreshtime": 1692675188944, "time": 1685209620817, "ctime": 1655608248926, "brand": "dding", "model": "XNLL901", "name": "Ford", "nickname": "Wyze Lock", "bind_time": 1685209635115, "time_zone": -700, "dst_offset": 0, "locker_status": { "door": 4, "door_refreshtime": 1692661288674, "hardlock": 1, "hardlock_refreshtime": 1692675170000 }, "door_open_status": 4, "door_open_status_time": 1692661288674, "calibrate_info": { "status": 1, "stage_time": 1685209694180 }, "open_volume": 100, "open_volume_refreshtime": 1692645312382, "auto_lock_time": 0, "auto_lock_time_refreshtime": 1692645301832, "ajar_alarm": 2, "ajar_alarm_refreshtime": 1692645301832, "trash_mode": 2, "trash_mode_refreshtime": 1692645301832, "left_open_time": 0, "left_open_time_refreshtime": 1692645301832, "keypad_enable_status": 1, "keypad_enable_status_refreshtime": 1692645301832, "door_sensor": 2, "door_sensor_refreshtime": 1692645301832, "geo": { "lat": "Sanitized", "lon": "Sanitized", "radius": 150, "address": "Sanitized" }, "auto_unlock": 1, "notice": { "notice_locked": 1, "notice_unlocked": 2 } } }

GuillaumeB-GitHub commented 11 months ago

Hello, would it be possible to add this fix in the next release please ?

GuillaumeB-GitHub commented 8 months ago

@SecKatie Hi, is it possible to get that PR merged and then release please ? Thanks

SecKatie commented 6 months ago

@GuillaumeB-GitHub How does the locker_status change on different states of the door? The number for door or hardlock might have that information.

"locker_status": {
  "door": 4,
  "door_refreshtime": 1692661288674,
  "hardlock": 1,
  "hardlock_refreshtime": 1692675170000
}
GuillaumeB-GitHub commented 5 months ago

@GuillaumeB-GitHub How does the locker_status change on different states of the door? The number for door or hardlock might have that information.

"locker_status": {
  "door": 4,
  "door_refreshtime": 1692661288674,
  "hardlock": 1,
  "hardlock_refreshtime": 1692675170000
}

"The number for door or hardlock might have that information.' -> what information are you talking about ?

GuillaumeB-GitHub commented 5 months ago

Thank you !