Custom Component: Unifi Protect

Of course!

Old laptop (i7 gen 4 I believe) I think 16GB ram
1 camera, a G3 Flex.

I’m not using anything special besides setting up the integration. Everything works fine and smoothly but since I’m getting spammed with motion events, when (and only when) I open the history page for that specific entity (the camera) it takes a long time to load and starts freezing when I try to scroll through it.

I’d rather avoid lowering the sensitivity since I plan to filter it down using Deepstack for person recognition, so I’m okay with tons of false positives. What I’d like is to maybe even stop saving the motion events (but still get them so my automation can run, if that makes sense).

I understand this is not a problem with the integration, but wanted to ask if someone knows how to limit the amount of data that is recorded or even stop recording it altogether based on some conditions (like being home), since it’s not the data I’m interested in, I just want a trigger for the deepstack flow.

You can avoid storing events from a specific component in the History log if you want to, so basically you can exclude the motion sensor from History. Read more here on how to do that. Would that help?

Anyone already figured out a good way of intergrating either directly into a home assistant card, or via a direct link, the 2 way audio feature of the doorbell? :slight_smile:

Looking for some creative solution to get this to work from my Home Assistant dashboard on my wall tablet :stuck_out_tongue:

is there a way to see the current night vision state for a camera? I have an external IR floodlight and I’d like to make it turn on with a smart plug when the camera switches over to NV mode

No not currently. I have found a field in the API, that seems to reflect if the camera sees the surroundings as dark or not. If I added this to the Cameras as attribute, could you use that in an automation?

Thanks, that sounds like the right sort of thing. I’m not too fussed about it being exactly in sync with the camera, but if it gets close enough it’s better than always on or using the sun tracker.

Very good. I did some tests, and this flag turns true whenever the camera itself turns on the built-in Infrared sensors, so it is in sync with the Camera. I already made most of the stuff, so I can release it soon.

That’s perfect, thanks for getting this done so quickly!

Strangly enough, since yesterday, on all iPads I can not view the live view from my protect cameras. Only a still image appears. Anyone see this too? It happens only on iPads, not iPhones or Windows PCs.

Release 0.6.7

Released: December 15th, 2020

  • ADDED: New attribute on each camera called is_dark. This attribute is true if the camera sees the surroundings as dark. If infrared mode is set to auto, then infrared mode would be turned on when this changes to true.

  • ADDED: New Service unifiprotect.set_mic_volume to set the Sensitivity of the built-in Microphone on each Camera. Requires two parameters: Camera Entity and level, where level is a number between 0 and 100. If level is set to 0, the Camera will not react on Audio Events.

    On each camera there is also now a new attribute called mic_sensitivity which displayes the current value.

    See README.md for instructions on how to setup an Input Slider in Lovelace to adjust the value.

  • CHANGED: Updated the README.md documentation and added more information and a TOC.

This release is tested on:

Tested means that either new features work on the below versions or they don’t introduce breaking changes.

  • CloudKey+ G2: FW Version 1.1.13 with Unifi Protect V1.13.37
  • UDMP: FW Version 1.18.3 with Unifi Protect V1.17.0-beta.6
1 Like

New HA user here with a brand new\fresh install. I’m seeing several dozen integrations in my HA install and several more from the HACS. Searching through these I’m not seeing a UniFi Protect integration listed.

Has this been pulled or do you have to manually install this? I’ve added the unifiprotect block to my configuration.yaml but HA clearly indicates it’s not installed.

Any guidance and maybe a sample config would be a blessing.

Mike

You should be able to search HACS for just “Unifi” and it will be there.

As for sample config its all added in the UI. Once the HACS integration is added, goto Settings and click the + icon to add the new integration to your system and find “Unifi Protect”.

The config things you’ll need are here

Thanks for the quick reply. I’m only seeing Unifi Controller in my HACS list which is why I’m asking if it’s been pulled or how I can troubleshoot this.

Mike

i cant test without removing it. Trying adding a custom repo in HACS using this:
https://github.com/briis/unifiprotect

If you are seeing “unifi controller” it sounds to me like you are searching under Addons and not HACS. Have you installed HACS? You should have the following:

1 Like

The UniFi Protect is very much alive, and just yesterday a new release went out.

HACS is just a “Package Installer” for Integrations that are not part of Core Home Assistant. So the first you do, is to find UniFi Protect in HACS under Integrations. Then you install the package from there and restart Home Assistant.

When HA is back, you go to Configuration and then you select Integrations. When on that page, do a hard refresh of your browser, to ensure UniFi Protect is loaded.
Now click on ADD INTEGRATION in the lower right corner, and search for UniFi Protect. It should show up in the search list. Click it, fill out the form, and you should be good to go.

1 Like

FYI - This morning I noticed the Unifi Protect App beta 1.3.14 they are introducing UP-Floodlight. This means the next UnifiOS beta release may have support for the new hardware.

[https://community.ui.com/releases/UniFi-Protect-Android-1-3-14/cff09f33-5ff8-49b4-907a-d014841f5a61](http://UniFi Protect Android 1.3.14 - beta)

Thanks. I have seen a few other references to this, but I have not discovered the HW that should go with it yet. Anyway, once we know more we will ensure to integrate that also.

love this project and super excited to get this going. in fact, just got into home assistant because of this component helping me get push notifications with the thumbnail preview.

Hope someone can guide me, I am stuck at this step in the github guide

To add Unifi Protect to your Home Assistant installation, go to the Integrations page inside the configuration panel and add a CloudKey+ or UDMP by providing the Host IP, Port Number, Username and Password

i have not been able to see where to click to open the configuration panel. this is a screenshot of the HACS integration with the protect integration added but the configuration panel i dont see any option for Unifi Protect

Go to:

Configuration -> Integrations -> Add Integration button

and look for Unifi Protect there.