diff --git a/libraries/AP_HAL_Linux/ToneAlarmDriver.cpp b/libraries/AP_HAL_Linux/ToneAlarmDriver.cpp index d3b42440bd..d3e337d7e8 100644 --- a/libraries/AP_HAL_Linux/ToneAlarmDriver.cpp +++ b/libraries/AP_HAL_Linux/ToneAlarmDriver.cpp @@ -61,6 +61,7 @@ int8_t LinuxUtil::toneAlarm_init() { tune_num = 0; //play startup tune if((period_fd == -1) || (duty_fd == -1) || (run_fd == -1)){ + hal.console->printf("ToneAlarm: Error!! please check if PWM overlays are loaded correctly"); return -1; } return 0; @@ -68,7 +69,6 @@ int8_t LinuxUtil::toneAlarm_init() void LinuxUtil::stop() { - write(run_fd,"0",sizeof(char)); }