An exotic new microphone has arrived in the Adafruit shop, a PDM MEMS Microphone! PDM is the ‘third’ kind of microphone you can integrate with electronics, apart from analog or I2S. These microphones are very commonly used in products, but are rarely seen in maker projects. Still, they have some benefits so we thought we’d offer a breakout for the shop.
The first thing to note is that this sensor does not provide an ‘analog’ output like many of our electret microphone assemblies. So it’s great for chips that do not have analog inputs. Secondly, the digital interface is a very simplistic pulse density modulation output. It’s digital, but it’s not PWM, and it’s not I2S. You will need to make sure your chip has a PDM interface – most 32-bit processors these days do!
PDM is a little like 1-bit PWM. You clock the mic with a 1 MHz – 3 MHz clock rate, and on the data line you’ll get a square wave out that syncs with the clock. The data line with be 0 or 1 logic output, with the square wave creating a density that when averaged will result in the analog value out.
There are a few ways to manage these mics:
Your chip comes with a hardware peripheral and library that does all the data managing at high speed, collects samples, applies a filter and gives you an analog value (The nRF52840 is like this, and it is ideal!)
Your chip comes with a hardware peripheral that gives you values, then it is up to you to perform the decimation/filtering. (We have some example code for this on the ATSAMD21 chipset)
Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, TinyGO, or even use the Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for CircuitPython, MakeCode, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.