You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Has PDM microphone been attempted with an esp32-c3? #5799
I am wondering if any software hack has been tried in order to expand microphone functionality to PDM since all the i2s mics on the market are pretty much obsolete.
@DedeHai@UsableLoki8221 PDM is basically just a cheap version of I2S. Maybe we should look into supporting TDM instead.
🤔 the latest -C3 reference manual says that PDM RX (i.e. PDM receiving) is supported by the hardware, so we might have a chance for PDM support, at least with V5 builds. It's a bit unexpected though, because I am very sure that espressif has stated "no PDM on the -C3" a few years ago.
Normal PDM RX mode
In this mode, pulse density modulation (PDM) data is received and stored into memory via DMA. Used signals: WS and DATA. PDM standard is supported in this mode by user configuration.
C3 has no PDM hardware, but can still receive it, needs to be software decoded at about 160kb/s so could eat quite some cpu time
Edit: this number is based on a 1.3MHz PDM clock.
@UsableLoki8221 no need to panic. I2S is definitely not dead, and PDM is definitely not the answer - PDM microphones are low quality when compared to I2S mics.
While a few of the recommended models - especially INMP441 - are not in production from the original vendor any more, you can still get them as "China clones" everywhere. Millions of makers around the world are still happily using INMP441 clones.
Basically you can use any microphone chip with an I2S interface - research for parts with I2S support and you'll find them.
I think that Adafruit has some ready-made breakouts with I2S interface.
@softhack007 I appreciate the responses and thought towards this topic.
The issue is toward PCB assembly for the bare component itself regarding
any sizable production. I have no idea how the tons of listings for
INMP441 get their stock for those breakouts when there are 0 stock in
mouser or LCSC catalogs for tape and reel. The only i2s mics appearing in
stock are the T5837, ICS-43434/43432 and they're very costly each ($3-5)
compared to the copious number of PDM found at <1$.
Considering that AR effects don't need high fidelity microphone responses
its very appealing to consider PDM as an option if possible. Even if the
PDM processing is taxing on cycles someone in user mod territory could
digest a warning for software limitations. My use case is simply for a
linear count of 21 pixels so I'm hoping once I got time to mess with the
PDM breakout I ordered I can report back
I ran a quick test with an arduino sketch and PDM looks feasible. It will eat quite some RAM (like 4-5k for buffers and LUT) and use ~5% of CPU time - roughly the same amount that FFT calculations take so it should not significantly impact the FPS.
If price is the issue and quality is not - just go analog, those can be had for 0.5$
Cool news! Yeah I was eventually going to try between both but all the
bias against recommending analog made me curious toward PDM alternative.
Does analog work on esp32-c3 v16.0.1 or is that just with the latest update
you made to the API?
difference between analog an PDM is mostly immunity to HF noise - if you do not screw up your design they should perform very similar.
I added analog in a long time ago but it was never merged. Now with IDF V5 it has better support so I added it again. Its in PR.
Activity
DedeHai commentedon Aug 14, 2026
Might be doable but could also put too much strain on limited cpu power.
Analog mic support is in PR already, that would also be a viable option.
UsableLoki8221 commentedon Aug 14, 2026
Oh sweet, thanks for letting me know. I ordered a PDM breakout so I'll see if I can manage anything usable out of it
softhack007 commentedon Aug 14, 2026
@DedeHai @UsableLoki8221 PDM is basically just a cheap version of I2S. Maybe we should look into supporting TDM instead.
🤔 the latest -C3 reference manual says that PDM RX (i.e. PDM receiving) is supported by the hardware, so we might have a chance for PDM support, at least with V5 builds. It's a bit unexpected though, because I am very sure that espressif has stated "no PDM on the -C3" a few years ago.
https://documentation.espressif.com/[esp32-c3_technical_reference_manual_en.pdf](https://documentation.espressif.com/esp32-c3_technical_reference_manual_en.pdf#i2s)#i2s
DedeHai commentedon Aug 14, 2026
C3 has no PDM hardware, but can still receive it, needs to be software decoded at about 160kb/s so could eat quite some cpu time
Edit: this number is based on a 1.3MHz PDM clock.
UsableLoki8221 commentedon Aug 15, 2026
softhack007 commentedon Aug 16, 2026
@UsableLoki8221 no need to panic. I2S is definitely not dead, and PDM is definitely not the answer - PDM microphones are low quality when compared to I2S mics.
While a few of the recommended models - especially INMP441 - are not in production from the original vendor any more, you can still get them as "China clones" everywhere. Millions of makers around the world are still happily using INMP441 clones.
Basically you can use any microphone chip with an I2S interface - research for parts with I2S support and you'll find them.
I think that Adafruit has some ready-made breakouts with I2S interface.
UsableLoki8221 commentedon Aug 16, 2026
DedeHai commentedon Aug 17, 2026
I ran a quick test with an arduino sketch and PDM looks feasible. It will eat quite some RAM (like 4-5k for buffers and LUT) and use ~5% of CPU time - roughly the same amount that FFT calculations take so it should not significantly impact the FPS.
If price is the issue and quality is not - just go analog, those can be had for 0.5$
UsableLoki8221 commentedon Aug 17, 2026
DedeHai commentedon Aug 17, 2026
difference between analog an PDM is mostly immunity to HF noise - if you do not screw up your design they should perform very similar.
I added analog in a long time ago but it was never merged. Now with IDF V5 it has better support so I added it again. Its in PR.
UsableLoki8221 commentedon Aug 17, 2026
DedeHai commentedon Aug 17, 2026
#5764 #5773
DedeHai commentedon Sep 17, 2026
@UsableLoki8221 I actually got this to work, still a proof of concept but could eventually make it into AR.
code for that is here https://github.com/DedeHai/WLED/tree/AR_V5_C3_PDM_support