I²S Digital Audio

Inter-IC Sound (I²S): Digital Plug & Play for Audio Devices

Rather than using dedicated audio playback hardware, many microcontrollers support I²S (Inter-IC Sound): a digital interface for transmitting digital audio between electronic components.

This interface provides a plug&play experience between microcontrollers, digital microphones, audio converters (DACs), and audio amplifiers.

Unlike conventional analog audio interfaces, I²S transmits discrete digital audio samples rather than continuously varying electrical signals.

How I²S Works

A typical I²S interface uses three signal lines:

  • BCLK (Bit Clock): Synchronizes individual data bits.
  • WS/LRC/LRCLK (Word Select): Identifies the left and right audio channels.
  • SD/DIN (Serial Data): Carries the digital audio samples.

    Some I2S amplifier boards call this DIN, and their SD pin is for shutdown and channel selection.

Some devices additionally require a master clock (MCLK).

Typical audio formats use 16-, 24-, or 32-bit samples at sample rates such as 44.1 or 48 kHz.

Digital vs. Analog Audio

Conventional analog audio playback requires a digital-to-analog converter (DAC) and an analog amplifier. The analog signal can pick up electrical interference, particularly in environments with switching regulators and microcontrollers.

I²S keeps the audio signal digital until it reaches the DAC or digital-input amplifier, reducing susceptibility to analog interference along the signal path.

Digital-input Class-D amplifiers such as the MAX98357A combine digital audio conversion and power amplification in a single device. A microcontroller can therefore drive a loudspeaker with very few additional components.

Feature I²S Analog Audio
Signal Digital Analog
Signal lines Typically 3–4 Typically 1–2
Noise immunity High Lower
External MCU DAC Not required Required for digital sources
Volume control Digital or hardware Analog or digital
Synchronization Clocked Not required
Compatibility I²S-compatible devices Conventional audio equipment

Prerequisites

To implement I²S audio playback, you need:

  • A microcontroller with hardware I²S support or an equivalent programmable interface.
  • An I²S-compatible DAC or digital-input audio amplifier.
  • Compatible logic voltage levels.
  • Matching sample rates, bit depths, and audio formats.
  • Sufficient processing power and memory to supply audio samples continuously.
  • An appropriate power supply and loudspeaker.

Compressed audio formats such as MP3 must be decoded into PCM samples before transmission via I²S.

Hardware DMA support is particularly useful because it allows continuous audio playback with minimal CPU involvement.

Supported Microcontrollers

Popular microcontroller families supporting I²S include:

  • ESP32: ESP32, ESP32-S2, ESP32-S3, ESP32-C3 and ESP32-C6.
  • STM32: Numerous models with dedicated I²S or SAI peripherals.
  • RP2040 and RP2350: I²S implemented through programmable I/O (PIO).
  • Nordic nRF52/nRF53: Selected models with hardware I²S.
  • Microchip SAM: Selected SAM D and SAM E microcontrollers.
  • NXP i.MX RT: Hardware serial audio interfaces (SAI).

Classic AVR-based Arduino boards such as the Arduino Uno and Nano lack dedicated I²S hardware.

Conclusion

I²S is particularly attractive for embedded audio applications, including sound generators, music players, voice announcements, and siren simulators.

Combining an ESP32 with a digital-input Class-D amplifier such as the MAX98357A provides an inexpensive, compact audio playback solution without requiring a separate analog DAC or amplifier stage.

Slow Website?

This website is very fast, and pages should appear instantly. If this site is slow for you, then your routing may be messed up, and this issue does not only affect done.land, but potentially a few other websites and downloads as well. Here are simple steps to speed up your Internet experience and fix issues with slow websites and downloads..

Comments

Please do leave comments below. I am using utteran.ce, an open-source and ad-free light-weight commenting system.

Here is how your comments are stored

Whenever you leave a comment, a new github issue is created on your behalf.

  • All comments become trackable issues in the Github Issues section, and I (and you) can follow up on them.

  • There is no third-party provider, no disrupting ads, and everything remains transparent inside github.

Github Users Yes, Spammers No

To keep spammers out and comments attributable, all you do is log in using your (free) github account and grant utteranc.es the permission to submit issues on your behalf.

If you don’t have a github account yet, go get yourself one - it’s free and simple.

If for any reason you do not feel comfortable with letting the commenting system submit issues for you, then visit Github Issues directly, i.e. by clicking the red button Submit Issue at the bottom of each page, and submit your issue manually. You control everything.

Discussions

For chit-chat and quick questions, feel free to visit and participate in Discussions. They work much like classic forums or bulletin boards. Just keep in mind: your valued input isn’t equally well trackable there.

  Show on Github    Submit Issue

(content created Dec 02, 2026)