ESP8266Audio icon indicating copy to clipboard operation
ESP8266Audio copied to clipboard

How to connect the esp32?

Open Primus007 opened this issue 6 years ago • 6 comments

i have successfully wired my pcm5102 to a wemos d1. Now i want to use a ESP32. I have connected: BCK Gpio26 LCK Gpio25 DIN Gpio22 Power: 3,3v + to ESP Vin and DAC VCC 3,3v - to ESP GND and DAC GND

But i hear no sound. please can help anyone?

Primus007 avatar May 23 '18 14:05 Primus007

Using PlayMP3FromSPIFFS example, I changed AudioOutputI2SNoDAC to AudioOutputI2S (include header file, class file name), the wiring just same as your BCK Gpio26 LCK Gpio25 DIN Gpio22 It works for me on ESP32. I used Adafruit UDA1334, but it should works for another I2S DAC module. Good lucks.

RemyEE avatar Jun 22 '18 10:06 RemyEE

I addition, SCK have to be connected to GND

aviosipov avatar Feb 23 '19 21:02 aviosipov

For what it's worth, if the issue is that you get more noise than sound, it could be the bit order. To get my PT8211 to work, I had to change I2S_COMM_FORMAT_I2S_MSB to I2S_COMM_FORMAT_I2S_LSB, here: https://github.com/earlephilhower/ESP8266Audio/blob/d0089c1f4acbcca48ef852400dfdcfd75ff06c8c/src/AudioOutputI2S.cpp#L56 .

tfry-git avatar Apr 16 '19 14:04 tfry-git

For what it's worth, if the issue is that you get more noise than sound, it could be the bit order. To get my PT8211 to work, I had to change I2S_COMM_FORMAT_I2S_MSB to I2S_COMM_FORMAT_I2S_LSB, here:

https://github.com/earlephilhower/ESP8266Audio/blob/d0089c1f4acbcca48ef852400dfdcfd75ff06c8c/src/AudioOutputI2S.cpp#L56

.

Wow, tfry-git you save me hours. I was getting mad testing several pt8211 and a pair of esp32 and noise was horrible. Thank you

zircothc avatar May 09 '19 19:05 zircothc

How do I make this change on an esp8266?

FrankHovis avatar Apr 03 '21 20:04 FrankHovis

Check this out to change on an esp8266: https://github.com/esp8266/Arduino/pull/4574#issuecomment-491023995

stufi1983 avatar Oct 08 '21 09:10 stufi1983