DouweM / homebridge-unifi-occupancy

Homebridge plugin that adds HomeKit occupancy sensors for selected devices (and people) on your UniFi network to the iOS Home app: quickly see who's where and automate accordingly.
Apache License 2.0
41 stars 1 forks source link

Devices not found #7

Closed bc2297 closed 1 year ago

bc2297 commented 1 year ago

Describe Your Problem: After installing the plugin, no iPhones are detected.

Logs:

[1/5/2023, 11:13:11 PM] Registering platform 'homebridge-unifi-occupancy.UnifiOccupancy'
[1/5/2023, 11:13:11 PM] [homebridge-unifi-occupancy] Loaded homebridge-unifi-occupancy v1.0.3 child bridge successfully
[1/5/2023, 11:13:11 PM] Loaded 0 cached accessories from cachedAccessories.0E78E28Dxxxx
[1/5/2023, 11:13:11 PM] Publishing bridge accessory (name: homebridge-unifi-occupancy, publishInfo: {
  username: '0E:78:E2:8D:xx:xx',
  port: 31973,
  pincode: '***-**-***',
  category: 2,
  bind: undefined,
  mdns: undefined,
  addIdentifyingMaterial: true,
  advertiser: undefined
}).
[1/5/2023, 11:13:11 PM] [homebridge-unifi-occupancy] Connecting with UniFi Controller...
[1/5/2023, 11:13:11 PM] [homebridge-unifi-occupancy] Getting access points from UniFi Controller...
[1/5/2023, 11:13:11 PM] Homebridge v1.6.0 (HAP v0.11.0) (homebridge-unifi-occupancy) is running on port 31973.
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: e0:63:da:3c:xx:xx Main Bedroom
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: e0:63:da:3c:xx:xx Basement
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: e0:63:da:3c:xx:xx Living Room
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: e0:63:da:3c:xx:xx Old Living Room
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: 74:ac:b9:c9:xx:xx Back Yard
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Found access point: e0:63:da:3c:xx:xx Front Room
[1/5/2023, 11:13:12 PM] [homebridge-unifi-occupancy] Getting connected devices from UniFi Controller...
[1/5/2023, 11:14:09 PM] [homebridge-unifi-occupancy] Device disconnected from UniFi Controller: User[08:c7:29:5d:xx:xx] disconnected from "Bmel" (6m 15s connected, 5.52M bytes, last AP[e0:63:da:3c:xx:xx])
[1/5/2023, 11:15:09 PM] [homebridge-unifi-occupancy] Device connected to UniFi Controller: User[08:c7:29:5d:xx:xx] has connected to AP[e0:63:da:3c:xx:xx] with SSID "Bmel" on "channel 36(na)"

Last lines are from manually turning off wifi, then turning back on on phone

Plugin Config:

{
            "unifi": {
                "controller": "https://192.168.1.141:8443",
                "username": "username",
                "password": "password",
                "site": "default",
                "secure": false,
                "unifios": false
            },
            "interval": 180,
            "accessPointAliases": [
                {
                    "accessPoint": "Basement",
                    "alias": "Basement"
                },
                {
                    "accessPoint": "New living room",
                    "alias": "Living Room"
                },
                {
                    "accessPoint": "Back Yard Roof",
                    "alias": "Back Yard"
                },
                {
                    "accessPoint": "Master Bedroom",
                    "alias": "Main Bedroom"
                },
                {
                    "accessPoint": "Front Room",
                    "alias": "Front Room"
                },
                {
                    "accessPoint": "Living Room",
                    "alias": "Old Living Room"
                }
            ],
            "_bridge": {
                "username": "0E:78:E2:8D:xx:xx",
                "port": 31973
            },
            "platform": "UnifiOccupancy"
        }

Running unifi network app from a Mac mini

Screenshots:

Screenshot 2023-01-05 at 11 29 47 PM Screenshot 2023-01-05 at 11 36 51 PM

Environment:

DouweM commented 1 year ago

@bc2297 Can you try version 1.0.4 that I just pushed? It should detect anything with "phone" in the (host)name!

DouweM commented 1 year ago

I'm closing this as others reported that 1.0.4 has resolved this problem for them.

bc2297 commented 1 year ago

@DouweM Worked for me as well! Thanks for the help