The repo has implementing an esp32 standalone MQTT audio streamer. Is is desinged to work as a satellite for Rhasspy (https://rhasspy.readthedocs.io/en/latest/). It supports multiple devices
Rhasspy uses some simple sounds by default to signal wake-up, end of recording and errors, which can be found here. While the sounds are short, they have a sample rate of 44100 Hz (with 16bits depth) and their playback on an ESP32-Audio-Kit with AC101 is bad.
I tried various higher writeSize values to increase the DMA buffer and 1024 seems to be good. It runs stable and sounds good. (The default is writeSize = 256). @locatw wrote the code around the DMA buffer size here
I don't want to blindly pump up the value and @locatw probably had their reasons. So, does anybody have some experience/opinion with DMA buffer size? The current code uses the default divide by four. So at the moment it's 256 / 4 = 64 which seems to be too low for proper 44KHz playback.
I think the 256 was there because is was taken over from the Matrix Voice. Feel free to do a PR to the code.
I do not own either of the chips (in fact no Audio Kit at all)
Rhasspy uses some simple sounds by default to signal wake-up, end of recording and errors, which can be found here. While the sounds are short, they have a sample rate of 44100 Hz (with 16bits depth) and their playback on an ESP32-Audio-Kit with AC101 is bad.
I tried various higher
writeSize
values to increase the DMA buffer and1024
seems to be good. It runs stable and sounds good. (The default iswriteSize = 256
). @locatw wrote the code around the DMA buffer size hereI don't want to blindly pump up the value and @locatw probably had their reasons. So, does anybody have some experience/opinion with DMA buffer size? The current code uses the default divide by four. So at the moment it's
256 / 4 = 64
which seems to be too low for proper 44KHz playback.Otherwise i can send a PR with:
Since i don't have an Audio-Kit with the ES8388 chip i can only test with an AC101. Maybe someone can do some testing with an ES8388?