mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-21 01:12:11 +00:00
drivers/tone_alarm and tune_control small improvements/cleanup
- drivers/tone_alarm: move to ModuleBase and purge CDev (/dev/tone_alarm0) - drivers/tone_alarm: only run on tune_control publication (or scheduled note) rather than continuously - drivers/tone_alarm: use HRT to schedule tone stop (prevents potential disruption) - msg/tune_control: add tune_id numbering - systemcmds/tune_control: add "error" special case tune_id - move all tune_control publication to new uORB::PublicationQueued<> - start tone_alarm immediately after board defaults are loaded to fix potential startup issues - for SITL (or other boards with no TONE output) print common messages (startup, error, etc)
This commit is contained in:
@@ -30,11 +30,10 @@ if [ $? = 0 ]
|
||||
then
|
||||
echo "[i] card mounted at /fs/microsd"
|
||||
# Start playing the startup tune
|
||||
tune_control play -t 1
|
||||
tune_control play -t 1 # tune 1 = STARTUP
|
||||
else
|
||||
echo "[i] no microSD card found"
|
||||
# Play SOS
|
||||
tune_control play -t 2
|
||||
tune_control play error
|
||||
fi
|
||||
|
||||
#
|
||||
@@ -90,22 +89,22 @@ then
|
||||
echo "PX4IO CRC OK"
|
||||
else
|
||||
echo "PX4IO CRC failure"
|
||||
tune_control play -t 18
|
||||
tune_control play -t 16 # tune 16 = PROG_PX4IO
|
||||
if px4io forceupdate 14662 $io_file
|
||||
then
|
||||
if px4io start
|
||||
then
|
||||
echo "PX4IO restart OK"
|
||||
tune_control play -t 19
|
||||
tune_control play-t 17 # tune 17 = PROG_PX4IO_OK
|
||||
else
|
||||
echo "PX4IO restart failed"
|
||||
tune_control play -t 20
|
||||
tune_control play -t 18 # tune 18 = PROG_PX4IO_ERR
|
||||
set unit_test_failure 1
|
||||
set unit_test_failure_list "${unit_test_failure_list} px4io_flash"
|
||||
fi
|
||||
else
|
||||
echo "PX4IO update failed"
|
||||
tune_control play -t 20
|
||||
tune_control play -t 18 # tune 18 = PROG_PX4IO_ERR
|
||||
set unit_test_failure 1
|
||||
set unit_test_failure_list "${unit_test_failure_list} px4io_flash"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user