dgreif / ring

Unofficial packages for Ring Doorbells, Cameras, Alarm System, and Smart Lighting
MIT License
1.2k stars 161 forks source link

Third Party Device doesnt show in Homebridge #1182

Closed EthanMendel closed 1 year ago

EthanMendel commented 1 year ago

Bug Report

Describe the Bug

I've connected a Schlage Encode lock to my ring app and can control it from the ring app. I also have a ring doorbell using the unbridge Camera setting When Homebridge loads, it finds both the camera and a device (assuming it is the lock), but only the camera gets set up in the Homebridge accessories ### To Reproduce Steps to reproduce the behavior: - Start Homebridge - Have Ring account linked with a schlage encode lock - See no lock in the accessories tab ### Expected behavior A lock accessory that can be controlled through Homebridge and thus through Homekit and the Home app ### Screenshots/Logs ``` [Ring] Found the following locations: [Ring] locationId: xxxxxxx - home [Ring] Configuring 1 cameras and 1 devices for location "home" - locationId: xxxxxxx [Ring] Configured camera xxxxxxx lpd_v2 Front Doorbell Front Doorbell xxxx is running on port xxxxx. Please add [Front Doorbell xxxx] manually in Home app. Setup Code: xxx-xx-xxx ``` ### Additional context Add any other context about the problem here. ### Homebridge Ring Config Post homebridge-ring platform config _without sensitive information_ ``` "refreshToken": "xxxxxxx", "unbridgeCameras": true, "avoidSnapshotBatteryDrain": false, "platform": "Ring" ``` ### Environment
dgreif commented 1 year ago

Would you mind running the Data Discovery tool? This will give me a better sense of how the lock is being reported to Ring.

Given your camera is unbridge, I'm curious - did you add just the camera bridge to HomeKit, or the homebridge bridge as well? If both, is it possible the lock got added but is just in a room in your Home app which you haven't checked?

EthanMendel commented 1 year ago

I've connected both and can see other homebridge accessories within homekit correctly. I don't believe it is just within a room I haven't checked because it is not even within the homebridge's accessories page (also, I did just double check to make sure)

Output from running the Data Discovery tool:

{
   "locations":[
      {
         "name":"Townhouse",
         "cameras":[
            {
               "description":"Front Doorbell",
               "subscribed":true,
               "subscribed_motions":false,
               "battery_life":null,
               "external_connection":false,
               "firmware_version":"Up to Date",
               "kind":"lpd_v2",
               "settings":{
                  "cv_settings":{
                     "detection_types":{
                        "human":{
                           "enabled":true,
                           "mode":"edge",
                           "record":null,
                           "notification":true
                        },
                        "loitering":{
                           "enabled":false,
                           "mode":"none",
                           "record":null,
                           "notification":false
                        },
                        "motion":{
                           "enabled":true,
                           "mode":"edge",
                           "record":null,
                           "notification":false
                        },
                        "moving_vehicle":{
                           "enabled":false,
                           "mode":"none",
                           "record":null,
                           "notification":false
                        },
                        "other_motion":{
                           "enabled":false,
                           "mode":"none",
                           "record":null,
                           "notification":false
                        },
                        "package_delivery":{
                           "enabled":false,
                           "mode":"none",
                           "record":null,
                           "notification":false
                        },
                        "package_pickup":{
                           "enabled":false,
                           "mode":"none",
                           "record":null,
                           "notification":false
                        }
                     },
                     "threshold":{
                        "loitering":10,
                        "package_delivery":2
                     },
                     "triggers":[

                     ]
                  },
                  "cv_paid_features":{
                     "baby_cry":true,
                     "car_alarm":true,
                     "co2_smoke_alarm":true,
                     "dog_bark":true,
                     "general_sound":true,
                     "glass_break":true,
                     "human":true,
                     "loitering":true,
                     "motion":true,
                     "other_motion":true,
                     "package_delivery":true,
                     "package_pickup":true,
                     "cv_triggers":true
                  },
                  "concierge_settings":{
                     "mode":"disabled"
                  },
                  "other_paid_features":{
                     "alexa_concierge":true,
                     "sheila_cv":true,
                     "sheila_recording":true
                  },
                  "sheila_settings":{
                     "cv_processing_enabled":false,
                     "local_storage_enabled":false
                  },
                  "server_settings":{
                     "ring_media_server_enabled":true,
                     "ring_media_server_host":"rms-us-east-1.rapi.us-east-1.prod.client.cap.ring.devices.a2z.com"
                  },
                  "zone_settings":{
                     "motion":[
                        {
                           "name":"Default Zone",
                           "state":"enabled",
                           "properties":{
                              "detection_types":[
                                 "motion"
                              ],
                              "style":1
                           },
                           "vertices":[
                              {
                                 "x":0.73031,
                                 "y":0.622174
                              },
                              {
                                 "x":0.707981,
                                 "y":0
                              },
                              {
                                 "x":1,
                                 "y":0
                              },
                              {
                                 "x":1,
                                 "y":0.497847
                              },
                              {
                                 "x":1,
                                 "y":1
                              },
                              {
                                 "x":0.685611,
                                 "y":1
                              },
                              {
                                 "x":0,
                                 "y":1
                              },
                              {
                                 "x":0.350019,
                                 "y":0.643165
                              }
                           ]
                        }
                     ]
                  },
                  "offline_motion_event_settings":{
                     "subscribed":true,
                     "enabled":false,
                     "max_upload_kb":5000,
                     "resolution_p":360,
                     "frequency_after_secs":1,
                     "period_after_secs":30
                  },
                  "lite_24x7":{
                     "subscribed":true,
                     "enabled":true,
                     "frequency_secs":180,
                     "resolution_p":360
                  },
                  "enable_vod":true,
                  "motion_zones":{
                     "enable_audio":false,
                     "active_motion_filter":1,
                     "sensitivity":5,
                     "advanced_object_settings":{
                        "human_detection_confidence":{
                           "day":0.8,
                           "night":0.8
                        },
                        "motion_zone_overlap":{
                           "day":0.2,
                           "night":0.3
                        },
                        "object_time_overlap":{
                           "day":0.2,
                           "night":1.2
                        },
                        "object_size_minimum":{
                           "day":0.04,
                           "night":0.07
                        },
                        "object_size_maximum":{
                           "day":0.7,
                           "night":0.7
                        }
                     },
                     "zone1":{
                        "name":"Default Zone",
                        "state":2,
                        "vertex1":{
                           "x":0.73031,
                           "y":0.622174
                        },
                        "vertex2":{
                           "x":0.707981,
                           "y":0
                        },
                        "vertex3":{
                           "x":1,
                           "y":0
                        },
                        "vertex4":{
                           "x":1,
                           "y":0.497847
                        },
                        "vertex5":{
                           "x":1,
                           "y":1
                        },
                        "vertex6":{
                           "x":0.685611,
                           "y":1
                        },
                        "vertex7":{
                           "x":0,
                           "y":1
                        },
                        "vertex8":{
                           "x":0.350019,
                           "y":0.643165
                        }
                     },
                     "zone2":{
                        "name":"Zone 2",
                        "state":0,
                        "vertex1":{
                           "x":0,
                           "y":0
                        },
                        "vertex2":{
                           "x":0,
                           "y":0
                        },
                        "vertex3":{
                           "x":0,
                           "y":0
                        },
                        "vertex4":{
                           "x":0,
                           "y":0
                        },
                        "vertex5":{
                           "x":0,
                           "y":0
                        },
                        "vertex6":{
                           "x":0,
                           "y":0
                        },
                        "vertex7":{
                           "x":0,
                           "y":0
                        },
                        "vertex8":{
                           "x":0,
                           "y":0
                        }
                     },
                     "zone3":{
                        "name":"Zone 3",
                        "state":0,
                        "vertex1":{
                           "x":0,
                           "y":0
                        },
                        "vertex2":{
                           "x":0,
                           "y":0
                        },
                        "vertex3":{
                           "x":0,
                           "y":0
                        },
                        "vertex4":{
                           "x":0,
                           "y":0
                        },
                        "vertex5":{
                           "x":0,
                           "y":0
                        },
                        "vertex6":{
                           "x":0,
                           "y":0
                        },
                        "vertex7":{
                           "x":0,
                           "y":0
                        },
                        "vertex8":{
                           "x":0,
                           "y":0
                        }
                     }
                  },
                  "motion_snooze_preset_profile":"low",
                  "live_view_preset_profile":"highest",
                  "live_view_presets":[
                     "low",
                     "middle",
                     "high",
                     "highest"
                  ],
                  "motion_snooze_presets":[
                     "none",
                     "low",
                     "medium",
                     "high"
                  ],
                  "doorbell_volume":11,
                  "chime_settings":{
                     "type":2,
                     "enable":true,
                     "duration":10
                  },
                  "video_settings":{
                     "ignore_zones":null,
                     "birton":null,
                     "brightness":16,
                     "contrast":80,
                     "saturation":48,
                     "ae_level":32,
                     "ae_mode":0,
                     "ae_mask":null,
                     "encryption_enabled":false,
                     "encryption_method":1,
                     "clip_length_min":null,
                     "clip_length_max":60,
                     "auto_clip_length_enabled":false
                  },
                  "motion_announcement":false,
                  "stream_setting":0,
                  "advanced_motion_detection_enabled":true,
                  "advanced_motion_detection_human_only_mode":true,
                  "luma_night_threshold":0,
                  "enable_audio_recording":true,
                  "people_detection_eligible":true,
                  "live_view_disabled":false,
                  "ignore_zones":null,
                  "enable_rich_notifications":true,
                  "rich_notifications_billing_eligible":true,
                  "loitering_threshold":10,
                  "advanced_motion_detection_types":[
                     "human"
                  ],
                  "motion_detection_enabled":true,
                  "rich_notifications_scene_source":"firmware",
                  "stark_enrolled":false,
                  "rich_notifica-uuid":false
               },
               "features":{
                  "motion_zone_recommendation":false,
                  "motions_enabled":true,
                  "show_recordings":true,
                  "advanced_motion_enabled":false,
                  "people_only_enabled":false,
                  "shadow_correction_enabled":false,
                  "motion_message_enabled":true,
                  "night_vision_enabled":false,
                  "rich_notifications_eligible":true,
                  "show_24x7_lite":true,
                  "show_offline_motion_events":false,
                  "cfes_eligible":true,
                  "sheila_camera_eligible":true,
                  "sheila_camera_processing_eligible":true
               },
               "owned":true,
               "alerts":{
                  "connection":"online",
                  "ota_status":"timeout"
               },
               "motion_snooze":null,
               "stolen":false,
               "is_sidewalk_gateway":true,
               "created_at":"2023-02-26T02:17:08Z",
               "shared_at":null,
               "active_schedule_uuid":null,
               "health":{
                  "device_type":"lpd_v2",
                  "last_update_time":1678373987,
                  "connected":true,
                  "rss_connected":true,
                  "sidewalk_connection":false,
                  "floodlight_on":false,
                  "white_led_on":false,
                  "siren_on":false,
                  "packet_loss":-1,
                  "packet_loss_category":"NA",
                  "rssi":-59,
                  "transformer_voltage":17,
                  "transformer_voltage_category":"good",
                  "ota_status":"timeout",
                  "network_connection_value":"wifi",
                  "external_connection":false,
                  "battery_percentage_category":"unknown",
                  "battery_voltage":4032,
                  "battery_voltage_category":"very_good",
                  "firmware_version":"10.0.18",
                  "rssi_category":"good",
                  "second_battery_percentage_category":"unknown",
                  "second_battery_voltage_category":"unknown",
                  "firmware_version_status":"Up to Date",
                  "stream_resolution":100,
                  "tx_rate":121.5,
                  "bandwidth_last_time":1678373549,
                  "bandwidth":14990,
                  "status_time":54996958811738,
                  "uptime_sec":93665,
                  "channel":"48",
                  "firmware_avg_bitrate":"2500541",
                  "video_packets_total":"16758",
                  "stream_profile":"1080_avc_20fps",
                  "iperf_tcp_throughput":"31373 Kbps"
               },
               "deactivated_at":null,
               "night_mode_status":"unknown"
            }
         ],
         "chimes":[

         ],
         "intercoms":[

         ],
         "devices":[

         ]
      }
   ],
   "amazonKeyLocks":[

   ]
}

I see there are no other devices listed which definitley could be causing the issue, though it is within my app: IMG_646634B9EBD5-1

tsightler commented 1 year ago

Schlage Encode locks are Wifi locks. While they appear in the Ring app, they integrate using the Key by Amazon API, not the Ring API, see this quote from the Schlage website:

Ring is only compatible with your Schlage Encode lock via Key by Amazon

As Key by Amazon is an entirely different set of APIs, these locks are currently not supported by this project. Only locks that connect via Z-wave to Ring Alarm controllers are supported.

EthanMendel commented 1 year ago

I see; thanks for investigating and getting back to me on this..

I'll close this issue as it is out of scope, but curious if anyone knows of another homebridge plugin to integrate a lock using this API (other than homebridge-alexa)