Ipwebcam detect connections

I’m trying to use the new IP webcam component to detect when someone connects so I can trigger an automation. For initial configuration I want it to use tts to say that someone is connected.

Below is what I have so far, however, it doesn’t trigger despite seeing the state change in the UI and in the history.

- alias: "Connected to camera"
  trigger:
    platform: numeric_state
    entity_id: sensor.ipwebcam_video_connections
    above: 0
  action:
    service: tts.google_say
    data:
      message: 'Watching you'
    entity_id: media_player.kitchen

Does anyone know why I’m going wrong?

@timwood
Can you help in this?

Cool idea about detecting whether someone is viewing the camera. Wish I could help, but I haven’t even had time to convert my config to the new IP webcam component. :frowning: Maybe @robbiet480, who built the component based on my post, can assist?

1 Like

As an update for this I was able to get it to work using the above but changing it to

above: 1

Now on the first connection, that takes the video_connections sensor from 0 to 1, I can start an automation.