From 0419c61ad1255fdc6f028203fe178eb248d70c1e Mon Sep 17 00:00:00 2001 From: Drashna Jael're Date: Wed, 22 Apr 2020 02:48:55 -0700 Subject: Fix timer calls in arm_audio --- quantum/audio/audio_arm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'quantum/audio') diff --git a/quantum/audio/audio_arm.c b/quantum/audio/audio_arm.c index 6b54d80acf..36f4f00c5d 100644 --- a/quantum/audio/audio_arm.c +++ b/quantum/audio/audio_arm.c @@ -85,7 +85,7 @@ static bool should_shutoff_dac(void); static void shutoff_dac(void); static void shutoff_dac_callback(void *arg); -#define PLAY_NOTE_TIMEOUT MS2ST(5) +#define PLAY_NOTE_TIMEOUT TIME_MS2I(5) #define DAC_BUFFER_SIZE 100 #ifndef DAC_SAMPLE_MAX # define DAC_SAMPLE_MAX 65535U @@ -583,7 +583,7 @@ static void gpt_cb8(GPTDriver *gptp) { } } -bool should_shutoff_dac() { return ST2MS(chVTTimeElapsedSinceX(last_note_played_at)) > 5 && dac_on; } +bool should_shutoff_dac() { return TIME_MS2I(chVTTimeElapsedSinceX(last_note_played_at)) > 5 && dac_on; } void shutoff_dac() { dacStopConversion(&DACD2); -- cgit v1.2.3