|
|
@ -97,8 +97,7 @@ if [ $SDCARD_AVAILABLE = yes ] |
|
|
|
then |
|
|
|
then |
|
|
|
if hardfault_log check |
|
|
|
if hardfault_log check |
|
|
|
then |
|
|
|
then |
|
|
|
# Error tune. |
|
|
|
set STARTUP_TUNE 2 # tune 2 = ERROR_TUNE |
|
|
|
set STARTUP_TUNE 2 |
|
|
|
|
|
|
|
if hardfault_log commit |
|
|
|
if hardfault_log commit |
|
|
|
then |
|
|
|
then |
|
|
|
hardfault_log reset |
|
|
|
hardfault_log reset |
|
|
@ -182,15 +181,6 @@ else |
|
|
|
# |
|
|
|
# |
|
|
|
tone_alarm start |
|
|
|
tone_alarm start |
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
# Play the startup tune (if not disabled or there is an error) |
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
param compare CBRK_BUZZER 782090 |
|
|
|
|
|
|
|
if [ $? != 0 -o $STARTUP_TUNE != 1 ] |
|
|
|
|
|
|
|
then |
|
|
|
|
|
|
|
tune_control play -t $STARTUP_TUNE |
|
|
|
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
# |
|
|
|
# Waypoint storage. |
|
|
|
# Waypoint storage. |
|
|
|
# REBOOTWORK this needs to start in parallel. |
|
|
|
# REBOOTWORK this needs to start in parallel. |
|
|
@ -250,7 +240,7 @@ else |
|
|
|
then |
|
|
|
then |
|
|
|
# Start UAVCAN firmware update server and dynamic node ID allocation server. |
|
|
|
# Start UAVCAN firmware update server and dynamic node ID allocation server. |
|
|
|
uavcan start fw |
|
|
|
uavcan start fw |
|
|
|
tune_control play -t 1 |
|
|
|
|
|
|
|
if param greater UAVCAN_ENABLE 2 |
|
|
|
if param greater UAVCAN_ENABLE 2 |
|
|
|
then |
|
|
|
then |
|
|
|
set OUTPUT_MODE uavcan_esc |
|
|
|
set OUTPUT_MODE uavcan_esc |
|
|
@ -315,7 +305,7 @@ else |
|
|
|
if [ $USE_IO = yes -a $IO_PRESENT = no ] |
|
|
|
if [ $USE_IO = yes -a $IO_PRESENT = no ] |
|
|
|
then |
|
|
|
then |
|
|
|
echo "PX4IO not found" |
|
|
|
echo "PX4IO not found" |
|
|
|
tune_control play error |
|
|
|
set STARTUP_TUNE 2 # tune 2 = ERROR_TUNE |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
# |
|
|
@ -369,6 +359,17 @@ else |
|
|
|
commander start |
|
|
|
commander start |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
# Play the startup tune (if not disabled or there is an error) |
|
|
|
|
|
|
|
# |
|
|
|
|
|
|
|
param compare CBRK_BUZZER 782090 |
|
|
|
|
|
|
|
if [ $? != 0 -o $STARTUP_TUNE != 1 ] |
|
|
|
|
|
|
|
then |
|
|
|
|
|
|
|
tune_control play -t $STARTUP_TUNE |
|
|
|
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Pre-takeoff continuous magnetometer calibration |
|
|
|
# Pre-takeoff continuous magnetometer calibration |
|
|
|
if param compare -s MBE_ENABLE 1 |
|
|
|
if param compare -s MBE_ENABLE 1 |
|
|
|
then |
|
|
|
then |
|
|
|