summaryrefslogtreecommitdiffstats
path: root/quantum/audio
diff options
context:
space:
mode:
authorJack Humbert <jack.humb@gmail.com>2017-07-21 19:18:36 +0200
committerJack Humbert <jack.humb@gmail.com>2017-07-23 20:59:29 +0200
commitf407f3e8deea433ae4bca61f17d8ed8ed208bb27 (patch)
tree6c93433f1190bec654d786465723c1b9b4e5c0da /quantum/audio
parent92ccc9a7b8ac856966147be48e24ce652c160386 (diff)
downloadqmk_firmware-f407f3e8deea433ae4bca61f17d8ed8ed208bb27.tar.gz
qmk_firmware-f407f3e8deea433ae4bca61f17d8ed8ed208bb27.tar.xz
remove unneccesary headers
Diffstat (limited to 'quantum/audio')
-rw-r--r--quantum/audio/audio.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/quantum/audio/audio.c b/quantum/audio/audio.c
index baa364eec..8e8570d26 100644
--- a/quantum/audio/audio.c
+++ b/quantum/audio/audio.c
@@ -555,7 +555,10 @@ ISR(TIMER1_COMPA_vect)
note_position++;
bool end_of_note = false;
if (TIMER_1_PERIOD > 0) {
- end_of_note = (note_position >= (note_length / TIMER_1_PERIOD * 0xFFFF - 1));
+ if (!note_resting)
+ end_of_note = (note_position >= (note_length / TIMER_1_PERIOD * 0xFFFF - 1));
+ else
+ end_of_note = (note_position >= (note_length));
} else {
end_of_note = (note_position >= (note_length));
}