From e971ce290ceac6680480331da9e5a3fc7102a501 Mon Sep 17 00:00:00 2001 From: Nebuleon <2391500+Nebuleon@users.noreply.github.com> Date: Thu, 27 Jul 2023 00:06:14 -0400 Subject: [PATCH] Remove needless precision in additive DAC sample generation (#21498) --- platforms/chibios/drivers/audio_dac_additive.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platforms/chibios/drivers/audio_dac_additive.c b/platforms/chibios/drivers/audio_dac_additive.c index 419c8be230..22e4fa2608 100644 --- a/platforms/chibios/drivers/audio_dac_additive.c +++ b/platforms/chibios/drivers/audio_dac_additive.c @@ -135,7 +135,7 @@ __attribute__((weak)) uint16_t dac_value_generate(void) { * timer runs with 3*AUDIO_DAC_SAMPLE_RATE; and the DAC callback * is called twice per conversion.*/ - dac_if[i] = fmod(dac_if[i], AUDIO_DAC_BUFFER_SIZE); + dac_if[i] = fmodf(dac_if[i], AUDIO_DAC_BUFFER_SIZE); // Wavetable generation/lookup uint16_t dac_i = (uint16_t)dac_if[i];