From 800266741baa6dac59aa3c062c8d123655db7e90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beat=20K=C3=BCng?= Date: Sat, 25 May 2019 17:58:44 +0200 Subject: [PATCH] Merge pull request #12063 from PX4/fix_custom_tune fix tunes: make sure a custom tune gets played --- src/lib/tunes/tunes.cpp | 2 +- src/lib/tunes/tunes.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/tunes/tunes.cpp b/src/lib/tunes/tunes.cpp index 4457ab8f2a..5934153538 100644 --- a/src/lib/tunes/tunes.cpp +++ b/src/lib/tunes/tunes.cpp @@ -178,7 +178,7 @@ int Tunes::get_next_note(unsigned &frequency, unsigned &duration, duration = _duration; frequency = _frequency; silence = _silence; - return TUNE_STOP; + return TUNE_CONTINUE; } // Make sure we still have a tune. diff --git a/src/lib/tunes/tunes.h b/src/lib/tunes/tunes.h index 4ab08804a7..c30335afa8 100644 --- a/src/lib/tunes/tunes.h +++ b/src/lib/tunes/tunes.h @@ -108,7 +108,7 @@ public: * @param duration return duration of the note (us) * @param silence return silence duration (us) * @param volume return the volume level of the note (between 0-100) - * @return -1 for error, 0 for play one tone and 1 for continue a sequence + * @return -1 for no tune available/error, 0 to not play anything and 1 to play */ int get_next_note(unsigned &frequency, unsigned &duration, unsigned &silence, uint8_t &volume);