UDA1334A I2S stereo DAC with ESP32
Supply 3.3-5 V
Bus GPIO
Pins and ESP32 wiring
| Pin | Role | ESP32 pin | Notes |
|---|---|---|---|
| VIN | Power | 3V3 | Pin order varies between boards: match by the printed label. 3.3 V or 5 V |
| 3VO | Not wired to the ESP32 | — | 3.3 V output of the regulator. Leave unconnected |
| GND | Ground | GND | |
| WSEL | SPI chip select | D25 | I2S word select (LRC), not SPI |
| DIN | Input (the ESP32 drives it) | D26 | I2S audio data from the ESP32 |
| BCLK | SPI clock | D27 | I2S bit clock, not SPI |
| LOUT | Not wired to the ESP32 | — | Line out left (or use the headphone jack) |
| AGND | Not wired to the ESP32 | — | Audio ground for the line outputs |
| ROUT | Not wired to the ESP32 | — | Line out right |
Suggested wiring for the 30-pin ESP32 DevKit, avoiding flash, input-only and strapping pins. BoardPilot checks it for you as you wire.
Starter code (Arduino)
void setup() { pinMode(26, OUTPUT); } // DIN
void loop() {
digitalWrite(26, HIGH);
delay(500);
digitalWrite(26, LOW);
delay(500);
}
Sources
- NXP UDA1334ATS datasheet, I2S-bus input BCK, WS, DATAI
- Adafruit I2S Stereo Decoder UDA1334A guide, Pinouts
Try it in 3D in BoardPilot
Related parts
18650 Li-ion cell in holder28BYJ-48 stepper + ULN2003 driver433 MHz transmitter (FS1000A)74HC595 shift registerA4988 stepper driverActive buzzer
Part data: CC BY 4.0, free to reuse with credit to BoardPilot.