-
-
Notifications
You must be signed in to change notification settings - Fork 39.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reduce popping during audio initialization using the additive DAC #21642
Conversation
The previous DAC initialization code caused two pops if `AUDIO_DAC_OFF_VALUE` was not 0 because the buffer sent to the DAC had one `AUDIO_DAC_OFF_VALUE` then the rest 0 before leaving the DAC again at `AUDIO_DAC_OFF_VALUE`: ```c static dacsample_t dac_buffer_empty[AUDIO_DAC_BUFFER_SIZE] = {AUDIO_DAC_OFF_VALUE}; /* other elements get initialized to 0 */ ``` This commit corrects the initialization and eliminates this source of popping.
I've gone and marked this as a draft because, while investigating why that empty buffer wasn't marked |
Alright, now that's much better. I've made it so that the "empty" buffer, which is also used throughout the keyboard's runtime, is called |
Description
The previous DAC initialization code caused two pops if
AUDIO_DAC_OFF_VALUE
was not 0 because the buffer sent to the DAC had oneAUDIO_DAC_OFF_VALUE
then the rest 0 before leaving the DAC again atAUDIO_DAC_OFF_VALUE
:This commit corrects the initialization and eliminates this source of popping.
Types of Changes
Checklist