Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: mqtt publishing of detections #83

Closed
tomlut opened this issue Mar 26, 2024 · 2 comments
Closed

Feature request: mqtt publishing of detections #83

tomlut opened this issue Mar 26, 2024 · 2 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@tomlut
Copy link

tomlut commented Mar 26, 2024

Could you please consider publishing bird detections to an mqtt broker?

@tphakala tphakala added enhancement New feature or request help wanted Extra attention is needed labels Mar 26, 2024
@tphakala
Copy link
Owner

tphakala commented Apr 5, 2024

MQTT support is now added, code was contributed by @janvrska. Release v0.5.1 and latest docker images contain support for this, please test and provide feedback.

Add following under realtime node in config yaml file

realtime:
    mqtt:
        enabled: true                      # true to enable MQTT
        broker: tcp://localhost:1883       # MQTT (tcp://host:port)
        topic: birdnet                     # MQTT topic
        username: birdnet		   # MQTT username
        password: secret       		   # MQTT password

@tomlut
Copy link
Author

tomlut commented Apr 5, 2024

Confirmed as working. Thank you both.

birdnet startup

Starting BirdNET-Go Analyzer in realtime mode
Threshold: 0.8, sensitivity: 1, interval: 15
2024/04/06 08:22:42 Connecting to MQTT broker
2024/04/06 08:22:42 Successfully connected to MQTT broker
2024/04/06 08:22:42 Connected to MQTT broker: tcp://10.1.1.100:1883
[2024-04-06T08:22:43+11:00] [INFO] ⨠http server started on [::]:8080

mqtt broker /birdnet topic:

{
  "ID": 0,
  "SourceNode": "BirdNET-Go",
  "Date": "2024-04-06",
  "Time": "08:23:51",
  "InputFile": "",
  "BeginTime": "2024-04-06T08:23:48.736132138+11:00",
  "EndTime": "0001-01-01T00:00:00Z",
  "SpeciesCode": "railor5",
  "ScientificName": "Trichoglossus moluccanus",
  "CommonName": "Rainbow Lorikeet",
  "Confidence": 0.8614452481269836,
  "Latitude": <redacted>
  "Longitude": <redacted>
  "Threshold": 0.8,
  "Sensitivity": 1,
  "ClipName": "clips/2024/04/trichoglossus_moluccanus_86p_20240406T082353Z.wav",
  "Comment": "",
  "ProcessingTime": 598766979,
  "Results": null
}

Just have to work out how best to display it in Home Assistant now.

@tomlut tomlut closed this as completed Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants