summaryrefslogtreecommitdiffstats
path: root/quantum/audio.c
diff options
context:
space:
mode:
authorAlex Johnstone <alexjj@gmail.com>2016-04-05 16:44:37 +0200
committerAlex Johnstone <alexjj@gmail.com>2016-04-05 16:44:37 +0200
commit1facc53a26294df7fb2a42f8f3d025176b8c384a (patch)
tree98eebfa4beb49524c1345c2dd9e93d1fb8aa445a /quantum/audio.c
parent48899673af8b82638d601455f405f03db165bd57 (diff)
parent931b0a79fc071498c229b0051be0ebadd934a549 (diff)
downloadqmk_firmware-1facc53a26294df7fb2a42f8f3d025176b8c384a.tar.gz
qmk_firmware-1facc53a26294df7fb2a42f8f3d025176b8c384a.tar.xz
Merge pull request #5 from jackhumbert/master
Sync with upstream
Diffstat (limited to 'quantum/audio.c')
-rw-r--r--quantum/audio.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/quantum/audio.c b/quantum/audio.c
index 3a3a1a491..f29d941d7 100644
--- a/quantum/audio.c
+++ b/quantum/audio.c
@@ -247,6 +247,9 @@ ISR(TIMER3_COMPA_vect) {
if (note_frequency > 0) {
ICR3 = (int)(((double)F_CPU) / note_frequency); // Set max to the period
OCR3A = (int)(((double)F_CPU) / note_frequency) >> 1; // Set compare to half the period
+ } else {
+ ICR3 = 0;
+ OCR3A = 0;
}
#endif