Skip to content

tomwpublic/hubitat_unifiProtect

Repository files navigation

hubitat_unifiProtect

This provides various driver capabilities for Hubitat with UniFi Protect systems. Supported devices include:

  • cameras (Motion and ImageCapture capabilities, as well as Smart Detect for supported cameras)
  • chimes (AudioVolume and Switch capabilities, for adjusting Protect Chime volume)
  • doorbells (Motion, Notification (LCD screen message), and PushableButton (for doorbell button presses))
  • lights (Motion, Switch, and SwitchLevel (for dimming the light))
  • viewers (for selecting ViewPort views based on saved liveviews)
  • more capabilities may be added over time.

Most of this implementation is based on the work shared here:

Special thanks to @Bago for their troubleshooting help.

Manual Installation instructions:

  • In the Drivers Code section of Hubitat, add the unifiProtectController, unifiProtectCamera, and unifiProtectDoorbell drivers.
    • Optionally add the remaining drivers if your system contains those additional device types.
  • In the Devices section of Hubitat, add a New Virtual Device of type UniFi Protect Controller.
  • On the configuration page for the newly created Device, enter these details and Save:
    • username and password for your UniFi Protect controller
    • the IP address of your UniFi Protect controller

Usage instructions:

  • Use createChildDevices() to create specific instances for all known devices (from the 'bootstrap' Device States entry)
  • Utilize Motion (from cameras, doorbells, and lights) and PushableButton (from doorbell) events, according to whatever is supported by your devices
  • Use on(), off(), and setLevel() on lights
  • Use the take() command on camera devices to take a snapshot from the main lens of the camera
    • This will store an image locally in the File Manager of your Hubitat hub (requires Hubitat software 2.3.4.132 or later).
    • To display or use the stored image, use my companion app hubitat_imageServer (available through HPM and GitHub).
  • Use the takePicture() command for capturing snapshots from camera devices that have multiple lenses, like the G4 Doorbell Pro.
  • Use the setRecordingMode(mode) on camera devices to modify the recording mode. Supported modes: "always", "never", and either "motion" or "detections" (try both to see which is correct) depending on your version of UniFi Protect.
  • Use the deviceNotification() command on doorbell devices to print a message to the LCD screen
    • Messages are limited to 30 characters by the UniFi Protect system

Disclaimer

I have no affiliation with any of the companies mentioned in this readme or in the code.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages