Ubiquiti Unifi Binding Feature Discussion

Tags: #<Tag:0x00007f51f0250a00> #<Tag:0x00007f51f0250898>

(Fastcar550) #706

I would find it useful if this binding would work with wired clients as well. Then it would be a one stop shop for all things connected vice using this with the network binding. Thanks for all the work thus far.

(Hakan Tandogan) #707

Enjoy your vacation, you have more than earned it :smile:

(Hakan Tandogan) #708

That was actually what I asked about five post before this one. Matthew wrote on 18. December that he introduced the thing type “wirelessClient” in preparation of supporting wired ones as well.

(Kris K) #709

Hi All

Is there a way I can speed up the Mobile phone detection? Right now it takes quite a few miniutes to determine if a phone is online or offline.

Im using it for presence


(Mark) #710

Most of the time for online detection is in the Unifi Controller, so there’s little you can do about that other than lower the refresh interval of the binding (which already is pretty low at 10 seconds).

For offline detection, you can lower the Consider Home Interval of the client, but you run the risk of false positives (or would they better be called false negatives) if you set it too low.

(Kris K) #711

Thanks Mark, so basically I should leave it as it is :smiley: hahaha

(Matthew) #712

You can try tweaking the considerHome parameter, but as @mhilbush said, setting it too low can result in false positives.

See the README for more

(J Wee) #713

With OH 2.4 stable unifi binding

The only channels that are being updated are AP, Lastseen and RSSI. The other channels are just silent.

No errors appear in the logs.
DId I miss something or do something wrong?
Again, I dunno why, but the other channels came back again.

(J Wee) #714

sorry , but which binding is the JS xform? JSONpath?

(Mark) #715


(J Wee) #716

hmm. that binding is already installed. but my item in the Paper UI still just shows a switch at on position

(Mark) #717

If the item is defined as a Number, it shouldn’t show as a switch. Check that the item definition is of type Number, and then define it as a Text widget in the sitemap.

(J Wee) #718

Sorry, its not a switch . What I meant to say is that even with Java Transformation for the uptime, I still see only seconds in Paper UI.

Its the unifi.map transformation that does not seem to be doing anything . It still shows presence as on or off switch

(Mark) #719

I don’t understand what this has to do with displaying the duration.

(J Wee) #720

No, its 2 seperate things.
I was under the impression the unifi.map transformation , changes my on/off switch to present or away. I do not see any difference in my paper UI with the unifi.map edit.

As the seconds conversion, I was trying to achieve who is listed in post #693

(Mark) #721

What do you see in the sitemap? I’m not sure if Paper UI handles map transformations.

Same with this. What do you see in the sitemap?

(Rob Pope) #722

I’ve removed the jar file, made sure the bundle isn’t listed in the command line and then installed the 2.4.0 binding through paper UI. I then updated the .items to match the new format (wirelessClient and cid)

I’ve then gone through my things and items but can’t get anything returned. If I query smarthome:items list I don’t see any unifi items.

Config is:

Bridge unifi:controller:home "UniFi Controller" [ host="", port=8443, username="my@email.com", password="abc123", refresh=10 ] {
        Thing wirelessClient robsPhone          "Rob's Phone"           [ cid="cc:9f:7a:ab:xx:yy", considerHome=180 ]
        Thing wirelessClient helensPhone        "Helen's Phone"         [ cid="64:a2:f9:4c:xx:yy", considerHome=180 ]

Is there anything obvious I’ve missed?

(Mark) #723

One possible thought… If there’s a syntax error in the .items file, the items won’t be loaded. Do you see anything logged in openhab.log when you save the .items file? How about when you save the .things file?

What do you see in the console when you query the things?

smarthome:things list | grep unifi

(Rob Pope) #724

Both the .items and .things refresh fine in openhab.log.

I got my things and items confused last night.

smarthome:things list | grep unifi is empty
smarthome:items list | grep Rob returns the following:

RobsPhone (Type=SwitchItem, State=NULL, Label=Rob's Phone, Category=null)
RobsPhoneSite (Type=StringItem, State=NULL, Label=Rob's Phone: Site, Category=null)
RobsPhoneESSID (Type=StringItem, State=NULL, Label=Rob's Phone: ESSID, Category=null)
RobsPhoneUptime (Type=NumberItem, State=NULL, Label=Rob's Phone: Uptime, Category=null)
RobsPhoneRSSI (Type=NumberItem, State=NULL, Label=Rob's Phone: RSSI, Category=null)
RobsPhoneAP (Type=StringItem, State=NULL, Label=Rob's Phone: AP, Category=null)
RobsPhoneLastSeen (Type=DateTimeItem, State=NULL, Label=Rob's Phone: Last Seen, Category=null)

(Mark) #725

Hmm. Do you see the Unifi things in Paper UI?