Skip to content

Has PDM microphone been attempted with an esp32-c3? #5799

Open

Description

@UsableLoki8221

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.

Activity

  1. DedeHai commented on Aug 14, 2026

    @DedeHai
    Collaborator

    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.

  2. UsableLoki8221 commented on Aug 14, 2026

    @UsableLoki8221
    Author

    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

  3. softhack007 commented on Aug 14, 2026

    @softhack007
    Member

    @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

    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.

  4. DedeHai commented on Aug 14, 2026

    @DedeHai
    Collaborator

    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.

  5. UsableLoki8221 commented on Aug 15, 2026

    @UsableLoki8221
    Author
  6. softhack007 commented on Aug 16, 2026

    @softhack007
    Member

    @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.

  7. UsableLoki8221 commented on Aug 16, 2026

    @UsableLoki8221
    Author
  8. DedeHai commented on Aug 17, 2026

    @DedeHai
    Collaborator

    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$

  9. UsableLoki8221 commented on Aug 17, 2026

    @UsableLoki8221
    Author
  10. DedeHai commented on Aug 17, 2026

    @DedeHai
    Collaborator

    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.

  11. UsableLoki8221 commented on Aug 17, 2026

    @UsableLoki8221
    Author
  12. DedeHai commented on Aug 17, 2026

    @DedeHai
    Collaborator
  13. DedeHai commented on Sep 17, 2026

    @DedeHai
    Collaborator

    @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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions