hw_ver app added for hardware version checking

This commit is contained in:
Anton Babushkin
2014-01-07 21:56:35 +01:00
parent 94b539dfdd
commit 255d91d8d4
14 changed files with 144 additions and 16 deletions
+5 -2
View File
@@ -67,8 +67,11 @@ if px4io start
then
echo "IO started"
else
fmu mode_serial
echo "FMU started"
if hw_ver compare PX4FMU_V1
then
fmu mode_serial
echo "FMU started"
fi
fi
#
+3 -1
View File
@@ -42,10 +42,12 @@ position_estimator_inav start
if [ -d /fs/microsd ]
then
if [ $BOARD == fmuv1 ]
if hw_ver compare PX4FMU_V1
then
echo "Start sdlog2 at 50Hz"
sdlog2 start -r 50 -e -b 16
else
echo "Start sdlog2 at 200Hz"
sdlog2 start -r 200 -e -b 16
fi
fi
+1 -1
View File
@@ -11,7 +11,7 @@ then
#
# Disable px4io topic limiting
#
if [ $BOARD == fmuv1 ]
if hw_ver compare PX4FMU_V1
then
px4io limit 200
else
+3 -1
View File
@@ -5,10 +5,12 @@
if [ -d /fs/microsd ]
then
if [ $BOARD == fmuv1 ]
if hw_ver compare PX4FMU_V1
then
echo "Start sdlog2 at 50Hz"
sdlog2 start -r 50 -a -b 16
else
echo "Start sdlog2 at 200Hz"
sdlog2 start -r 200 -a -b 16
fi
fi
+1 -3
View File
@@ -28,9 +28,7 @@ fi
if lsm303d start
then
set BOARD fmuv2
else
set BOARD fmuv1
echo "using LSM303D"
fi
# Start airspeed sensors
+6 -3
View File
@@ -185,9 +185,12 @@ then
else
echo "PX4IO restart failed"
echo "PX4IO restart failed" >> $logfile
tone_alarm MNGGG
sleep 10
reboot
if hw_ver compare PX4FMU_V2
then
tone_alarm MNGGG
sleep 10
reboot
fi
fi
else
echo "PX4IO update failed"