Page 1 of 1

i2s volume control

Posted: Thu Jul 01, 2021 6:34 am
by amazone
hi there,

I am using esp-adf with esp32 wrover and max98375a (no codec, i2s, class d amplifier).
There is no codec, so there are some problems with the volume control.


When using alc, it seems that the volume is controlled through the i2s_alc_volume_set() function.
Is it the right way to adjust the volume using the i2s_alc_volume_set function?


" esp_err_t i2s_alc_volume_set(audio_element_handle_ti2s_stream, int volume) "

What is the minimum and maximum value of the parameter volume?


Thanks in advance.

Re: i2s volume control

Posted: Tue Jul 13, 2021 4:17 pm
by astate
Hi, I'm having the same question, was wondering if you have this sort out? Thanks!

Re: i2s volume control

Posted: Wed Jul 14, 2021 2:32 pm
by astate
I have successfully using i2s_alc_volume_set to set volume with max98375a, it works well!
Just following the pipeline example https://github.com/espressif/esp-adf/tr ... e_http_mp3
and the int volume scale is from -64 (muted) to 64 (super noisy)

Re: i2s volume control

Posted: Thu Jul 15, 2021 5:33 am
by amazone
astate wrote:
Wed Jul 14, 2021 2:32 pm
I have successfully using i2s_alc_volume_set to set volume with max98375a, it works well!
Just following the pipeline example https://github.com/espressif/esp-adf/tr ... e_http_mp3
and the int volume scale is from -64 (muted) to 64 (super noisy)
I'm glad to hear you're using it well. :lol:

However, I would like to hear the exact answer from the espressif team.