ESPHome and SparkFun Electret Microphone Breakout, BOB-12758

Hi all! I’m trying to make sense of the SparkFun Electret Microphone Breakout, BOB-12758. I’ve got it connected, and read values through ADC… but am I doing it right? The voltage mostly stays around 1.6, but spikes to 2-3 with no apparent reason. I’m using an ADC pin on an ESP-WROOM-32 devkit. My goal is to detect prolonged loud noise and activate an automation in Home Assistant based on the input from this mic. Any tips for a more sensible configuration to capture output?

sensor:

  • platform: adc

pin: 32

name: “Sound level”

update_interval: 500ms

attenuation: auto

How much is your VCC? 3.3V? A raise in the output without any apparent change in the sound level is something really questionable. Are you trying the code given in the hookup guide? Or something else written by you?