RepositoryC++
Sukecz

Sukecz/esp32-birdnet-mic

ESP32 audio streamer and standalone microSD field recorder. Stream to BirdNET-Go/Pi or record wildlife sounds offline, with browser setup and battery monitoring.

241stars
35forks
1issues
3views

Featured achievements

The project's latest awards

1
TINIX TRENDING·Topic: birdnet

#1 Repository of the week

1
TINIX TRENDING·Topic: birdnetgo

#1 Repository of the week

1
TINIX TRENDING·Topic: birdnet-go

#1 Repository of the week

ESP32 RTSP Mic for BirdNET-Go / BirdNET-Pi

birdnet-esp32-rtsp-mic

Seeed XIAO ESP32 network microphone for BirdNET-Go and BirdNET-Pi. It reads an I2S MEMS microphone and serves mono 16-bit PCM/L16 audio over RTSP.

  • Latest firmware: v1.10.1 (2026-06-25)
  • Target sketch: esp32-birdnet-mic
  • Web flasher: https://esp32mic.msmeteo.cz (Chrome/Edge desktop, USB-C data cable)
  • Manual OTA firmware: manual-ota-firmware/firmware-app-<board>.bin (firmware-app.bin remains the C6 alias)
  • Detailed firmware docs: esp32-birdnet-mic/README.md
  • Changelog: esp32-birdnet-mic/CHANGELOG.md
  • License: MIT (LICENSE)

Quick Start

  1. Open https://esp32mic.msmeteo.cz.
  2. Click Flash, select the USB JTAG/serial device, and wait for reboot.
  3. On first boot, connect to Wi-Fi AP ESP32-RTSP-Mic-AP.
  4. Open http://192.168.4.1 if the captive portal does not appear, then enter your Wi-Fi details.
  5. After reboot, open the device Web UI at http://<device-ip>/.
  6. Use these RTSP URLs in BirdNET-Go, BirdNET-Pi, VLC, or ffplay:
rtsp://<device-ip>:8554/audio1    Stream 1
rtsp://<device-ip>:8554/audio2    Stream 2

If mDNS is enabled and works on your LAN, the same streams are available through the device hostname:

rtsp://<device-hostname>.local:8554/audio1
rtsp://<device-hostname>.local:8554/audio2

The default hostname is unique per device, for example esp32mic-a1b2c3.

Supported XIAO boards:

Default build notes:

  • The web flasher detects the connected ESP chip family and selects the matching firmware.
  • XIAO ESP32-C6 external antenna RF switch is enabled by default.
  • XIAO ESP32-C3, XIAO ESP32-S3, and XIAO ESP32-C5 use their U.FL antenna path without firmware GPIO switching.
  • OTA has no password in the default public build. Keep the device on your trusted LAN.
  • For OTA without USB, open https://esp32mic.msmeteo.cz, enter the device IP in the OTA section, and open the device update page.
  • For manual OTA upload, use the matching app-only file from manual-ota-firmware/.

Wiring

Tested build targets: Seeed Studio XIAO ESP32-C3/S3/C5/C6. Runtime hardware validation is still primarily on XIAO ESP32-C6 + ICS-43434 I2S microphone.

Wiring / pinout

Use the same physical XIAO pin labels on every supported board. The underlying GPIO numbers differ by chip.

Mic signalXIAO pin labelC3 GPIOS3 GPIOC5 GPIOC6 GPIONotes
BCLK / SCKD354721I2S bit clock
LRCLK / WSD13201I2S word select
SD / DOUTD243252I2S data from microphone
VDD3V3----Power
GNDGND----Ground

INMP441 has also been reported to work with the same I2S pins. If your board exposes L/R or SEL, set it to the left channel, usually GND, because the firmware reads the left I2S channel. See discussion #25: https://github.com/Sukecz/esp32-birdnet-mic/discussions/25

XIAO Antennas

XIAO ESP32-C6 uses an RF switch path controlled by GPIO3/GPIO14. The firmware selects the external antenna path by default.

  • Use a 2.4 GHz external antenna for stable RTSP streaming.
  • XIAO ESP32-C3 and XIAO ESP32-S3 expose a U.FL antenna connector without a documented firmware GPIO switch.
  • XIAO ESP32-C5 has a dedicated Wi-Fi/BT antenna connector; attach the included antenna before use.
  • Weak Wi-Fi can cause packet loss, retries, and extra heat.
  • If your hardware intentionally uses the internal antenna path, adjust or remove the GPIO3/GPIO14 antenna-control block in setup() for the C6 build.

Test The Stream

Use /audio1 for stream 1 unless you specifically need the old /audio URL.

ffplay -rtsp_transport tcp rtsp://<device-ip>:8554/audio1
ffprobe -rtsp_transport tcp rtsp://<device-ip>:8554/audio1

For VLC: Media -> Open Network Stream -> paste rtsp://<device-ip>:8554/audio1 or rtsp://<device-ip>:8554/audio2.

If VLC/ffplay works, use the same RTSP URL in BirdNET-Go or BirdNET-Pi.

What The Firmware Provides

  • English Web UI on port 80 with live status, settings, logs, and actions.
  • JSON API for automation and monitoring.
  • Two RTSP streams: /audio1 and /audio2; /audio is an alias for /audio1.
  • Configurable 1-3 concurrent RTSP sessions; default is 2.
  • Per-stream enable/disable and BirdNET-Go / BirdNET-Pi target selection.
  • Transport selection based on target: TCP for BirdNET-Go, UDP for BirdNET-Pi.
  • Dedicated audio producer task with ring buffer between I2S capture and RTSP packet output.
  • Audio/API diagnostics for I2S errors, ring-buffer drops, and RTSP write stalls/timeouts.
  • MQTT telemetry and Home Assistant MQTT Discovery.
  • Stream schedule by local time, including overnight windows.
  • Optional deep sleep outside the stream schedule window.
  • Auto-recovery, scheduled reset, CPU frequency control.
  • Thermal protection with persistent latch and manual acknowledgement.
  • Configurable high-pass filter for low-frequency rumble.
  • mDNS hostname support and OTA support.

Default audio settings are 48 kHz, mono 16-bit PCM/L16, gain 1.2, and a 512-sample packet buffer. The 512-sample default is the balanced profile and avoids the BirdNET-Pi UDP stutter observed with 1024-sample packets, while still working well for BirdNET-Go TCP. Firmware v1.9.3 and later improves BirdNET-Pi UDP compatibility by handling RTCP and RTP metadata expected by ffmpeg-based clients.

PartQtyNotesLink
Seeed Studio XIAO ESP32-C31Supported XIAO target boardSeeed Studio
Seeed Studio XIAO ESP32-S31Supported XIAO target boardSeeed Studio
Seeed Studio XIAO ESP32-C51Supported XIAO target boardSeeed Studio
Seeed Studio XIAO ESP32-C61Supported XIAO target boardSeeed Studio
MEMS I2S microphone ICS-434341Tested reference microphoneAliExpress
MEMS I2S microphone INMP4411Reported compatible with same wiring-
Shielded cable, 5+ coreOptionalI2S mic needs 5 conductors: 3V3, GND, BCLK, LRCLK/WS, and SD/DOUT. A 6-core cable is a good practical choice for spare/shield handling.AliExpress
5 V power supply1At least 1 A recommendedAliExpress
2.4 GHz antenna, IPEX/U.FLRecommendedImportant for stable XIAO Wi-Fi streamingAliExpress

Links are examples only. Verify the exact part number before buying.

Practical Tips

  • Keep I2S wires short; use shielded cable for longer runs.
  • Keep the microphone and I2S wires away from the ESP32 antenna/RF area.
  • Aim for Wi-Fi RSSI better than about -75 dBm.
  • Use DHCP reservation or fixed IP if BirdNET cannot resolve mDNS reliably.
  • Keep the device on a trusted LAN; do not expose HTTP/RTSP to the public internet.

RF Noise / Wi-Fi TX Power

If the stream is stable but the audio is noisy or distorted, try lowering Wi-Fi TX Power in the Web UI. When the access point is nearby, lower TX power can reduce RF coupling into the microphone, wiring, or power rails.

Suggested test:

  1. Set Wi-Fi TX Power to about 11 dBm.
  2. Watch RSSI, packet rate, reconnects, and audio quality for a few minutes.
  3. If Wi-Fi becomes unstable, raise TX power step by step.

A grounded metal enclosure can help shield microphone wiring, but keep the Wi-Fi antenna outside the metal enclosure.

High-Pass Filter

The firmware includes a configurable high-pass filter to reduce low-frequency rumble.

  • Default: ON at 500 Hz.
  • Typical range: 300-800 Hz.
  • Web UI: Audio -> High-pass and HPF Cutoff.
  • API: POST /api/set with key=hp_enable&value=on|off or key=hp_cutoff&value=600.
  • Mutating API calls require header X-ESP32MIC-CSRF: 1.

Compatibility

  • Target boards: Seeed Studio XIAO ESP32-C3, XIAO ESP32-S3, XIAO ESP32-C5, and XIAO ESP32-C6.
  • Web flasher auto-selects firmware by ESP chip family. It cannot distinguish board variants that share the same chip family.
  • Reference microphone: ICS-43434.
  • Reported compatible microphone: INMP441 with the same I2S wiring.
  • Other ESP32 boards or I2S microphones may work, but may need pin or I2S format changes.

Arduino IDE Build Size

Firmware v1.9.2 and later includes esp32-birdnet-mic/build_opt.h, which the ESP32 Arduino core loads automatically in Arduino IDE and arduino-cli. It disables unused C++ exception/unwind metadata and keeps the tight XIAO ESP32-C3/C6 default 1.2 MB app partitions below the limit without removing firmware features.

More Documentation

  • Firmware details, build instructions, API notes: esp32-birdnet-mic/README.md
  • Manual OTA firmware: manual-ota-firmware/README.md
  • Web flasher notes: web-flasher/README.md
  • Firmware changes: esp32-birdnet-mic/CHANGELOG.md

License

This project is released under the MIT License. See LICENSE.

Similar Projects

Discover other similar projects and AI models.

RepositoryC
FFmpeg/FFmpeg

Mirror of https://git.ffmpeg.org/ffmpeg.git

68.4k
Nov 29, 2026
RepositoryC++
snapcast/snapcast

Synchronous multiroom audio player

8.1k
Nov 25, 2026
RepositoryPython
arnegiacomo/fugleramme

Bird frame for Raspberry Pi or your homelab - real-time bird detection by audio, fully local AI, rendered as real, hand-cut 1800s bird illustrations. On an e-ink panel, a TV, or any screen.

4.1k
Nov 26, 2026
RepositoryJavaScript
adamoberley/HABirdDashboard

A live bird collage card for your Home Assistant dashboard.

106
Nov 27, 2026
RepositoryRust
ruvnet/RuView

π RuView turns commodity WiFi signals into real-time spatial intelligence, vital sign monitoring, and presence detection — all without a single pixel of video.

105.9k
Dec 2, 2026
RepositoryPython
OpenBMB/VoxCPM

VoxCPM2: Tokenizer-Free TTS for Multilingual Speech Generation, Creative Voice Design, and True-to-Life Cloning

43.1k
Nov 9, 2026
RepositoryC
mpv-player/mpv

🎥 Command line media player

38.4k
Nov 29, 2026
RepositoryPython
blakeblackshear/frigate

NVR with realtime local object detection for IP cameras

38.1k
Nov 30, 2026
Modelautomatic-speech-recognition
openai/whisper-large-v3

Whisper Whisper is a state-of-the-art model for automatic speech recognition (ASR) and speech translation, proposed in the paper Robust Speech Recognition via Large-Scale Weak Supervision(https://huggingface.co/papers/2212.04356) by Alec Radford et...

♥0
3.0M
Aug 12, 2024