Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use Adafruit I2S Mic breakout (SPH0645): Examples, Pinouts, and Specs

Image of Adafruit I2S Mic breakout (SPH0645)
Cirkit Designer LogoDesign with Adafruit I2S Mic breakout (SPH0645) in Cirkit Designer

Adafruit I2S Microphone Breakout (SPH0645) Documentation

1. Introduction

The Adafruit I2S Microphone Breakout (SPH0645) is a compact, high-performance digital microphone module designed for capturing high-quality audio. It utilizes the I2S (Inter-IC Sound) interface for transmitting audio data, making it an excellent choice for projects requiring precise sound capture and processing. Unlike analog microphones, the SPH0645 outputs digital audio signals, eliminating the need for analog-to-digital conversion and reducing noise interference.

Common Applications

  • Voice recognition systems
  • Audio recording and streaming
  • Sound level monitoring
  • IoT devices with audio input
  • DIY smart assistants and home automation

2. Technical Specifications

The following table outlines the key technical details of the Adafruit I2S Microphone Breakout:

Parameter Value
Microphone Type Digital MEMS (SPH0645LM4H-B)
Interface I2S (Inter-IC Sound)
Supply Voltage 1.8V to 3.3V
Current Consumption ~1.4 mA
Frequency Response 50 Hz to 15 kHz
Signal-to-Noise Ratio 65 dB
Sensitivity -26 dBFS ±3 dB
Dimensions 15.2mm x 17.7mm x 1.5mm

Pin Configuration and Descriptions

The breakout board has four pins, as described in the table below:

Pin Name Description
1 VIN Power supply input (1.8V to 3.3V). Connect to 3.3V for most microcontrollers.
2 GND Ground. Connect to the ground of your circuit.
3 BCLK Bit Clock. Provides the clock signal for I2S communication.
4 DOUT Data Output. Outputs the digital audio data in I2S format.
5 LRCLK Left/Right Clock. Determines whether the data is for the left or right channel.

3. Usage Instructions

Connecting the SPH0645 to a Microcontroller

The SPH0645 is designed to work seamlessly with microcontrollers like the Arduino UNO, ESP32, or Raspberry Pi. Below is a typical wiring guide for connecting the SPH0645 to an Arduino UNO:

SPH0645 Pin Arduino Pin
VIN 3.3V
GND GND
BCLK Pin 3
LRCLK Pin 2
DOUT Pin 4

Note: The Arduino UNO does not natively support I2S. For I2S functionality, use a microcontroller like the ESP32 or Raspberry Pi.

Example Code for ESP32

The following example demonstrates how to use the SPH0645 with an ESP32 to capture audio data:

#include <I2S.h> // Include the I2S library for ESP32

// Define I2S pins
#define I2S_BCLK 3   // Bit Clock pin
#define I2S_LRCLK 2  // Left/Right Clock pin
#define I2S_DOUT 4   // Data Output pin

void setup() {
  Serial.begin(115200); // Initialize serial communication for debugging

  // Configure I2S with the appropriate pins and settings
  if (!I2S.begin(I2S_PHILIPS_MODE, 16000, 16)) {
    Serial.println("Failed to initialize I2S!");
    while (1); // Halt execution if I2S initialization fails
  }

  I2S.setPins(I2S_BCLK, I2S_LRCLK, I2S_DOUT);
  Serial.println("I2S Microphone Initialized!");
}

void loop() {
  int16_t sampleBuffer[256]; // Buffer to store audio samples
  size_t bytesRead = I2S.read(sampleBuffer, sizeof(sampleBuffer));

  if (bytesRead > 0) {
    Serial.print("Audio data captured: ");
    Serial.println(bytesRead / 2); // Each sample is 2 bytes
  }

  delay(100); // Small delay to avoid overwhelming the serial monitor
}

Important Considerations

  1. Power Supply: Ensure the SPH0645 is powered with 3.3V. Supplying higher voltages may damage the module.
  2. I2S Compatibility: Verify that your microcontroller supports I2S communication. The Arduino UNO does not natively support I2S.
  3. Clock Signals: The SPH0645 requires both BCLK and LRCLK signals to function correctly. Ensure these are configured properly in your code.

4. Troubleshooting and FAQs

Common Issues and Solutions

Issue Possible Cause Solution
No audio data is being captured. Incorrect wiring or pin configuration. Double-check the wiring and ensure the pins are connected as per the table.
Distorted or noisy audio output. Incorrect I2S settings (e.g., sample rate). Verify the I2S configuration in your code matches the SPH0645 specifications.
Microphone not initializing. Incompatible microcontroller. Use a microcontroller with native I2S support, such as ESP32 or Raspberry Pi.
Module overheating. Overvoltage on VIN pin. Ensure the VIN pin is supplied with 3.3V (not 5V).

Frequently Asked Questions

Q1: Can I use the SPH0645 with an Arduino UNO?
A1: The Arduino UNO does not natively support I2S. Use an ESP32, Raspberry Pi, or other microcontrollers with I2S support.

Q2: What is the maximum sample rate supported by the SPH0645?
A2: The SPH0645 supports sample rates up to 48 kHz, but 16 kHz is commonly used for most applications.

Q3: Can I use multiple SPH0645 modules in a single project?
A3: Yes, but each module will require its own I2S interface or multiplexing to handle the data streams.

Q4: How do I process the audio data captured by the SPH0645?
A4: The audio data is output as 16-bit PCM. You can process it using audio libraries or send it to external devices for further analysis.


5. Additional Resources


This documentation provides a comprehensive guide to using the Adafruit I2S Microphone Breakout (SPH0645). Whether you're a beginner or an experienced developer, this guide will help you integrate the SPH0645 into your next audio project with ease.

Explore Projects Built with Adafruit I2S Mic breakout (SPH0645)

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
ESP32-S3 and INMP441 I2S Microphone Audio Data Logger
Image of esp32-s3-DevKitC-1-N8R2-inmp441: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
This circuit features an ESP32-S3-DevKitC-1-N8R2 microcontroller connected to an INMP441 microphone via I2S protocol. The ESP32 reads audio data from the microphone and prints it to the serial monitor, enabling real-time audio data acquisition and monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer
Raspberry Pi Zero-Based Audio Visualizer with OLED Display and INMP441 Microphone
Image of HEART_SOUND: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
This circuit features a Raspberry Pi Zero connected to an INMP441 MEMS microphone and a 1.3" OLED display. The Raspberry Pi Zero communicates with the OLED display via I2C (using GPIO2 for SDA and GPIO3 for SCL), and it interfaces with the INMP441 microphone using I2S (with GPIO4 for SCK, GPIO9 for L/R selection, ID_SD for SD, and GPIO12 for WS). The circuit is designed for audio input through the microphone and visual output on the OLED display, likely for applications such as sound visualization or audio monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32-Based I2S Digital Microphone Interface
Image of inmp441 mic with esp32: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
This circuit connects an INMP441 MEMS microphone to an ESP32 microcontroller. The microphone's left/right (L/R) and ground (GND) pins are tied to the ESP32's ground, while its I2S interface pins (WS, SCK, SD) are connected to the ESP32's corresponding I2S pins (D25, D32, D33) for digital audio data transfer. The microphone is powered by the ESP32's 3.3V output.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32-Based Voice-Activated SD Card Audio Recorder
Image of Main Design: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
This circuit features an ESP32 Devkit V1 microcontroller connected to a Micro SD Card Module for data storage, an Adafruit MAX9814 Electret Microphone Amplifier for audio input, and an Adafruit MAX98357A I2S Class-D Mono Amp connected to a loudspeaker for audio output. A pushbutton is interfaced with the ESP32 for user input. The circuit is likely designed for audio recording and playback with the capability to store the audio data on the SD card.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with Adafruit I2S Mic breakout (SPH0645)

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of esp32-s3-DevKitC-1-N8R2-inmp441: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
ESP32-S3 and INMP441 I2S Microphone Audio Data Logger
This circuit features an ESP32-S3-DevKitC-1-N8R2 microcontroller connected to an INMP441 microphone via I2S protocol. The ESP32 reads audio data from the microphone and prints it to the serial monitor, enabling real-time audio data acquisition and monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of HEART_SOUND: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
Raspberry Pi Zero-Based Audio Visualizer with OLED Display and INMP441 Microphone
This circuit features a Raspberry Pi Zero connected to an INMP441 MEMS microphone and a 1.3" OLED display. The Raspberry Pi Zero communicates with the OLED display via I2C (using GPIO2 for SDA and GPIO3 for SCL), and it interfaces with the INMP441 microphone using I2S (with GPIO4 for SCK, GPIO9 for L/R selection, ID_SD for SD, and GPIO12 for WS). The circuit is designed for audio input through the microphone and visual output on the OLED display, likely for applications such as sound visualization or audio monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of inmp441 mic with esp32: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
ESP32-Based I2S Digital Microphone Interface
This circuit connects an INMP441 MEMS microphone to an ESP32 microcontroller. The microphone's left/right (L/R) and ground (GND) pins are tied to the ESP32's ground, while its I2S interface pins (WS, SCK, SD) are connected to the ESP32's corresponding I2S pins (D25, D32, D33) for digital audio data transfer. The microphone is powered by the ESP32's 3.3V output.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Main Design: A project utilizing Adafruit I2S Mic breakout (SPH0645) in a practical application
ESP32-Based Voice-Activated SD Card Audio Recorder
This circuit features an ESP32 Devkit V1 microcontroller connected to a Micro SD Card Module for data storage, an Adafruit MAX9814 Electret Microphone Amplifier for audio input, and an Adafruit MAX98357A I2S Class-D Mono Amp connected to a loudspeaker for audio output. A pushbutton is interfaced with the ESP32 for user input. The circuit is likely designed for audio recording and playback with the capability to store the audio data on the SD card.
Cirkit Designer LogoOpen Project in Cirkit Designer