Vivint Integration

This is probably the first true doorbell camera with “button push” integration to Home Assistant (searched high and low for a doorbell camera that could be integrated to HA without silly things like vibration sensors glued to mechanical chimes - no luck)

im glad i went browsing today i forgot i wanted to add in vivint integration and natekspencer/hacs-vivint looks the simplest to implement and glad to hear you have had success using the motion to trigger different things, i hate the vivint control panel and leave it on mute so i want to flash the lights when someone is ringing the bell etc

So am I correct in saying this only works with cameras at the moment? I have a few door sensors that I would like to use if possible.

Nope, door and window sensors work as well and are updated immediately! It should work with basically everything at this point. Some might need some tweaking since I don’t own every sensor, but I do have a bunch and they all work well!

Hmm…It doesn’t seem to detect the sensors. All I see in Configuration is options for camera (which I don’t have)
image

The sensors should appear in devices/entities, not in the options section.

Screen Shot 2021-05-18 at 1.56.14 PM

can you share the code you wrote to make the motion dection/door bell ring ? i want to trigger based on motion and door bell ringing
@PerseusX lol i see your more active do you have the yaml to make the sensor for motion/doorbell ring

You can just do it right from the automations tab:

Sure. Here is the code I used to change the status of a boolean switch that I had created.

alias: Front Porch - Motion Detected
description: 'Enable the Doorbell Motion Boolean switch for 30 seconds. '
trigger:
  - platform: device
    domain: vivint
    device_id: 15250498f0362a7cacc4644b1fa058cd
    type: motion_detected
condition: []
action:
  - service: homeassistant.turn_on
    target:
      entity_id: input_boolean.doorbell_motion
  - delay:
      hours: 0
      minutes: 0
      seconds: 30
      milliseconds: 0
  - service: homeassistant.turn_off
    target:
      entity_id: input_boolean.doorbell_motion
mode: single

I then have another automation that monitors the change in the boolean switch to switch on the lights after dark.

alias: Front Porch - Turn on light when motion detected after dark
description: Turn on front porch light when motion detected after dark
trigger:
  - platform: state
    entity_id: input_boolean.doorbell_motion
    to: 'on'
condition:
  - condition: or
    conditions:
      - condition: sun
        after: sunset
      - condition: sun
        before: sunrise
action:
  - service: switch.turn_on
    target:
      entity_id: switch.front_porch
mode: single

As Nathan said, you can just create this directly in the automations UI, which is what I did.

Yeah Unfortunately none of that shows up in mine. Perhaps I have older sensors.

What panel do you have? Is it the old go control panel?

Yes thats the one

Ah ok. That panel isn’t supported with this integration. Only the sky panel and smart hubs are. I need to update the documentation on the repo to correctly state that. It’s called out in the underlying api library, but I forgot to re-state it in the integration repo.

I figured that was the case. Oh well, thanks for the update.

This is pretty awesome @PerseusX! I had bought a SimpleSafe system just so i could have alarm integration. Lately SimpliSafe has been terrible with timeouts and what not so i found this for Vivint. Works great. Just glad i never got rid of my Vivint when i got SimpliSafe. One thing i noticed is many of my door/window sensors came in as windows so the icon was incorrect on the HA frontend. This was a simple fix to just change the icon of each. I couldn’t find where it was setting a device class, so i assume it was trying to use the name (ex Kitchen Sliding Door). Maybe the “Sliding” part made it think it was a window?

Another thing is i cant seem to get motion to be detected in HA with the motion detectors. Entity history shows motion has never been detected. Honestly not sure how to even see a trigger on the sky panel either. Not a big deal.

Well oddly enough with zero changes the motion detectors started reporting and doing so in a timely manner… Not sure why it wasn’t working at first nor why it is now. Either way, Awesome integration and seems to be stable and working great.

Typically when the system is set up, door and window sensors are added and classified under a certain sub sensor type where doors are “exit/entry” and windows are “perimeter”, which is what I tried to key off of. If the doors were added and set as a “perimeter” sensor, then that is likely the reason why. That being said, it should be easy to modify the code and first search for “window” or “door” in the name to set the device class before defaulting to door for exit/entry and window for perimeter.

Glad the motion sensor is working now as well!

@PerseusX,

Love the integration. Everything is working quite well. I have been racking my brain for hours trying to work backwards from your code and some other GitHub repositories related to Vivint trying to understand how to get the correct RTSP URL so I could view one of my cameras in VLC. The cameras are viewable via Home Assistant with the integration, but there are times I’d like to be able to view a single camera in VLC so I can more easily control the size and be able “AlwaysOnTop” it. I’ve managed to get my panel_id and enumerate the devices in my home, but still can’t manage to get the RTSP URL to work in VLC… It prompts me for a username/password, but keeps telling me it’s incorrect. I know this isn’t directly related to your integration, but I’m at the point where I’m raising the white flag hoping someone could assist with the final piece I’m missing.

If you are trying to work from the API and data directly, have a look at how the vivintpy library gets the rtsp url.

If, however, you’re just wanting to get the url for use in VLC, you can do the following:

  1. Install the vivintpy library: python3 -m pip install vivintpy
  2. Create a python file, import vivintpy and connect to your account (see demo.py from the vivintpy library)
  3. For your camera devices, add a logging or print statement such as logging.debug(await device.get_direct_rtsp_url())
  4. You should be able to use that url in VLC to access your camera
1 Like