Page 1 of 1
Can ESP32 output audio streams?
Posted: Tue Jan 02, 2018 6:28 am
by shicongyu666
Hello,
I have a product that's going to use esp32, which has a network radio playback function.Now I know ESP32 I2S interface can output the data to a digital power amplifier, and speakers. But I'm not quite sure ESP32 could directly output audio stream.If it can output audio streams, can the program control the amplitude of the audio stream?If it can, I can control the output sound size directly through ESP32, because the current selected analog power amplifier has no volume adjustment function.
I look forward to your reply. Thank you!
Re: Can ESP32 output audio streams?
Posted: Tue Jan 02, 2018 9:01 am
by ESP_Sprite
Technically: yes, the ESP32 has two DACs you can use to directly output an analog signal. You can digitally divide the signal going to this to get some kind of volume control. In practice, these DACs are only eight bit, so audio quality won't be exactly HiFi, so you may want to grab an external codec anyway.
Re: Can ESP32 output audio streams?
Posted: Tue Jan 02, 2018 7:37 pm
by Gfast2
ESP_Sprite wrote:Technically: yes, the ESP32 has two DACs you can use to directly output an analog signal. You can digitally divide the signal going to this to get some kind of volume control. In practice, these DACs are only eight bit, so audio quality won't be exactly HiFi, so you may want to grab an external codec anyway.
Some Off-Shelf Suggestions (tested one with ESP32 if any?)
Cheers
Gfast2
Re: Can ESP32 output audio streams?
Posted: Tue Jan 02, 2018 7:46 pm
by hassan789
Basically, you can output audio via:
PWM
PDM
I2S
DAC
How many watts are you trying to output? 100mW, 1W, 10W?
Are you trying to output to headphones or speakers?
Re: Can ESP32 output audio streams?
Posted: Wed Jan 03, 2018 3:05 am
by shicongyu666
ESP_Sprite wrote:Technically: yes, the ESP32 has two DACs you can use to directly output an analog signal. You can digitally divide the signal going to this to get some kind of volume control. In practice, these DACs are only eight bit, so audio quality won't be exactly HiFi, so you may want to grab an external codec anyway.
You explain it very well, and your suggestion is very applicable.
Thanks!!!
Re: Can ESP32 output audio streams?
Posted: Wed Jan 03, 2018 3:07 am
by shicongyu666
hassan789 wrote:Basically, you can output audio via:
PWM
PDM
I2S
DAC
How many watts are you trying to output? 100mW, 1W, 10W?
Are you trying to output to headphones or speakers?
1W,a speaker.
I see the reply on the 2nd floor is very good, I intend to use his suggestion, use a codec.
Thank you for your reply!