HAL_Linux: change the return type of AP_HAL::Util::tonealarm_init() to signed int8_t.

This is a part of a set of fixes for the bugs and typos tridge discovered and shared inside earlier commits for setting up tonealarm.
This commit is contained in:
bugobliterator 2014-11-08 15:57:22 +05:30 committed by Andrew Tridgell
parent b383e1633b
commit af203760bd
3 changed files with 3 additions and 3 deletions

View File

@ -62,7 +62,7 @@ public:
/*
ToneAlarm Driver
*/
virtual uint8_t toneAlarm_init() { return -1;}
virtual int8_t toneAlarm_init() { return -1;}
virtual void toneAlarm_set_tune(uint8_t tune) {}
virtual void _toneAlarm_timer_tick() {}

View File

@ -57,7 +57,7 @@ void LinuxUtil::toneAlarm()
tune_num = -1; //initialy no tune to play
}
uint8_t LinuxUtil::toneAlarm_init()
int8_t LinuxUtil::toneAlarm_init()
{
tune_num = 0; //play startup tune
if((period_fd == -1) || (duty_fd == -1) || (run_fd == -1)){

View File

@ -127,7 +127,7 @@ public:
*/
void commandline_arguments(uint8_t &argc, char * const *&argv);
uint8_t toneAlarm_init();
int8_t toneAlarm_init();
void toneAlarm_set_tune(uint8_t tune);
void _toneAlarm_timer_tick();