MQTT Trigger doesn't kick off?

i’m trying to setup some automation to work,
when motion gets detected by the camera.
manually running the same automation(s) do the job…
but i want mqtt event to trigger it. :hot_face:

Surely, i’m getting mqtt messages generated with the motion detected each time.

my understanding is that frigate/event is the topic subscribed by the automations

At one point i got the following errors but not at the moment


if anyone can help me. it will be great. dealing with this for months.

Looks like you don’t have the MQTT integration setup

1 Like

Appreciate your reply @crzynik

that’s something i had a doubt on. Glad you confirmed my doubt. Any how-to-video or article that i should follow that you’d recommend.

How can i be sure that’s fully integrated and working okay.

Also, anyway i can see this automation play end-to-end in logs.

Should something like below needs to be added ? in the config.yml
mqtt:
broker: 192.168.1.2

sensor:

  • platform: mqtt
    name: “Frigate”
    state_topic: “frigate/event”

i think i’ve tried fixing the MQTT integration, wasn’t aware of doing the complete steps

something still not right, i think mqtt triggers are still not fully functional.

Q - should i add the topic also to frigate.yml for these to work???

mqtt:
  host: 192.168.1.2
  port: 1883
  # user:  
  # password: 

detectors:
  cpu1:
    type: cpu  
  cpu2:
    type: cpu
  cpu3:
    type: cpu  
  cpu4:
    type: cpu
  cpu5:
    type: cpu  
  cpu6:
    type: cpu    

cameras:
  12: # <------ Name the camera
    ffmpeg:
      inputs:
        - path: rtsp://admin:[email protected]:554 # <----- Update for your camera
          roles:
            - detect
            - rtmp
            - clips
            # - record
    rtmp:
      enabled: true # <-- RTMP should be disabled if your stream is not H264
    detect:
      width: 1280 # <---- update for your camera's resolution
      height: 720 # <---- update for your camera's resolution
      fps: 5
    snapshots:
      enabled: true
      timestamp: true
      bounding_box: true
      crop: true
      retain:
        default: 1
    # clips:
    #   enabled: true
  # record: # <----- Enable recording
  #   enabled: True

  13: # <------ Name the camera
    ffmpeg:
      inputs:
        - path: rtsp://admin:[email protected]:554 # <----- Update for your camera
          roles:
            - detect
            - rtmp
            - clips
            # - record
    rtmp:
      enabled: true # <-- RTMP should be disabled if your stream is not H264
    detect:
      width: 1280 # <---- update for your camera's resolution
      height: 720 # <---- update for your camera's resolution
      fps: 5
    snapshots:
      enabled: true
      timestamp: true
      bounding_box: true
      crop: true
      retain:
        default: 1
    # clips:
    #   enabled: true
  # record: # <----- Enable recording
  #   enabled: True

  # 14: # <------ Name the camera
  # ffmpeg:
  #   inputs:
  #     - path:  rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0  # <----- Update for your camera
  #       roles:
  #         - detect
  #         # - rtmp
  #         - clips
  #         # - record
  #   rtmp:
  #     enabled: false # <-- RTMP should be disabled if your stream is not H264
  #   detect:
  #     width: 1280 # <---- update for your camera's resolution
  #     height: 720 # <---- update for your camera's resolution
  #     fps: 5
  #   snapshots:
  #     enabled: true
  #     timestamp: true
  #     bounding_box: true
  #     crop: true
  #     retain:
  #       default: 1
  #   # clips:
  #   #   enabled: true
  # # # record: # <----- Enable recording
  # # #   enabled: True

No it will use the default topic. There is really not much setup needed from the frigate side (once frigate is running)

You can see that the events topic is being populated correctly. This means the issue lies somewhere in your HA setup, not frigate

1 Like

Thanks for pointing me in correct direction @crzynik

Don’t know what happened but for some reason the HA setup itself corrupted for me. And i started from the scratch yesterday and set it up differently. Like there’s a ubuntu vm on ESXi with Frigate on docker and media storage on the same machine.

In addition the HA neat with Frigate proxy on Raspberry PI 4 (SSD boot) and did go through the integrations including MQTT i used username and password(that i never did before) and now it’s all working as expected. A bit of finetuning is required that i’m sure i’ll continue with.

Appreciate your help. It took me months to get done with this.