Ubiquiti Unifi Binding Feature Discussion

I just pushed the refactoring changes to @scurb’s PR.

Once these changes get merged, I’m going to release a beta version for testing of site and wiredClient things :smiley:

2 Likes

What I am looking for is to have the same DateTime information for uptime then for last seen. I want to achive a view where I see with date and time when a person came home or left home. Has this already been mentioned somewhere? I did not find it and it seems that I am to stupid to create a working rule by myself.

Thank your for your help

Markus

The uptime channel gets reset to 0 whenever a client is marked as away and then starts incrementing once a client returns home.

So you could accomplish this with 2 extra items and 2 rules…

DateTime MatthewsPhoneAwayAt
DateTime MatthewsPhoneHomeAt
rule "Matthew has left the building"
when 
  Item MatthewsPhoneUptime changed to 0
then
  MatthewsPhoneAwayAt.postUpdate(MatthewsPhoneLastSeen.state)
end

rule "Matthew has returned"
when
  Item MatthewsPhoneUptime changed from 0
then
  MatthewsPhoneHomeAt.postUpdate(MatthewsPhoneLastSeen.state)
end

At least I think this will work :see_no_evil:

As promised, here’s phase 1 …

We now have a site thing with the following channels:

  • totalClients
  • wirelessClients
  • wiredClients
  • guestClients

Please update to the latest build: org.openhab.binding.unifi-2.5.0-SNAPSHOT.jar

See the updated README

As always, please report back here - even if everything works!

1 Like

hmm… not getting any numbers on the new channels on site:

It’s fixed now :man_facepalming:

org.openhab.binding.unifi-2.5.0-SNAPSHOT.jar

Now phase 2 …

We finally have a wiredClient thing :tada:

org.openhab.binding.unifi-2.5.0-SNAPSHOT.jar

See the updated README for the available channels

Let me know how it works for you!

2 Likes

Looking good here, all working fine :grinning:

I just installed the ltest version of the binding and have a problem (same problem when installed through paperui, that’s why I tried this one).

Seems that accented characters causes problems somehow, i have an ‘ä’ in my password, and get a OFFLINE - CONFIGURATION_ERROR Invalid username and/or password - please double-check your configuration error on the thing.

The same password works just fine when logging in to the controller otherwise, so the controller supports it.

I have tried configuring both through paperui and .things-file, but same result.

1 Like

Maybe replace ä with ae :see_no_evil:

I will try and reproduce this and see if it’s something I can fix in the binding.

Of course that’s the easy solution, and I have already changed my password, just thought I should let you know :wink:

Someone else had a password issue with a special character. I’ll try and solve both of them.

1 Like

Works fine for me, especially after I chose the correct sid for my site :blush:

1 Like

Both of these issues have been solved! :smiley:

org.openhab.binding.unifi-2.5.0-SNAPSHOT.jar

@jwiseman and @pacive - please update to the latest build and try your original passwords and let me know if it works now.

Works like a charm here, thank you!

Tried the 2.4 one for starters, works very well!

One Feature Request - because this is the title of the thread :slight_smile: I have a unify PoE Switch, would be great to power devices on and off this way. No Idea if that is feasable.

Good work !
Thanks
PhiL

This will be one of the next features as I have just acquired a US-8-60 :slight_smile:

There’s a growing list of new features but PoE support is a major one for me and my WAF :laughing:

@mgbowman If you don’t mind me asking, what’s the use case for being able to power on and off PoE on a switch port?

I currently have 4 access points attached to them, and if I am not at home, I don’t need at least 3 of them. I don’t have other scenarios, but I just started to be a fan of PoE for IoT devices, but if I could control their power-usage for example dependend if I am at home or away, sleep or awake… that might save a buck or two.

I have 12 ceiling mounted echo dots and some cameras overlooking the garden. Wife likes to don a tin foil hat every now and again (me as well), so when we’re having a BBQ in the garden, no cameras. Want a private convo in the house, “Alexa, commit suicide” :rofl:

3 Likes