Skip to content

Commit

Permalink
Merge pull request #12063 from PX4/fix_custom_tune
Browse files Browse the repository at this point in the history
fix tunes: make sure a custom tune gets played
  • Loading branch information
bkueng authored and LorenzMeier committed May 25, 2019
1 parent 9ab9a29 commit 8002667
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/lib/tunes/tunes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down
2 changes: 1 addition & 1 deletion src/lib/tunes/tunes.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class Tunes
* @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);
Expand Down

0 comments on commit 8002667

Please sign in to comment.