Optimize rc shell

This commit is contained in:
Felix Hu 2016-03-30 10:27:39 +08:00 committed by Lorenz Meier
parent 4aa13d8f1f
commit c528c02e95
2 changed files with 61 additions and 64 deletions

View File

@ -83,81 +83,84 @@ then
then
fi
fi
else
if ver hwcmp PX4FMU_V4
fi
if ver hwcmp PX4FMU_V4
then
# External I2C bus
if hmc5883 -C -T -X start
then
# External I2C bus
if hmc5883 -C -T -X start
then
fi
fi
# Internal SPI bus is rotated 90 deg yaw
if hmc5883 -C -T -S -R 2 start
then
fi
# Internal SPI bus is rotated 90 deg yaw
if hmc5883 -C -T -S -R 2 start
then
fi
# Internal SPI bus ICM-20608-G is rotated 90 deg yaw
if mpu6000 -R 2 -T 20608 start
then
fi
# Internal SPI bus ICM-20608-G is rotated 90 deg yaw
if mpu6000 -R 2 -T 20608 start
then
fi
# Internal SPI bus mpu9250 is rotated 90 deg yaw
if mpu9250 -R 2 start
# Internal SPI bus mpu9250 is rotated 90 deg yaw
if mpu9250 -R 2 start
then
fi
fi
if ver hwcmp PX4FMU_V1
then
# FMUv1
if mpu6000 start
then
fi
if l3gd20 start
then
fi
# MAG selection
if param compare SENS_EXT_MAG 2
then
if hmc5883 -C -I start
then
fi
else
if ver hwcmp MINDPX_V2
# Use only external as primary
if param compare SENS_EXT_MAG 1
then
if mpu6500 start
then
fi
if lsm303d start
then
fi
if l3gd20 start
then
fi
# External I2C bus
if hmc5883 -C -T -X start
if hmc5883 -C -X start
then
fi
else
# FMUv1
if mpu6000 start
# auto-detect the primary, prefer external
if hmc5883 start
then
fi
if l3gd20 start
then
fi
# MAG selection
if param compare SENS_EXT_MAG 2
then
if hmc5883 -C -I start
then
fi
else
# Use only external as primary
if param compare SENS_EXT_MAG 1
then
if hmc5883 -C -X start
then
fi
else
# auto-detect the primary, prefer external
if hmc5883 start
then
fi
fi
fi
fi
fi
fi
if ver hwcmp MINDPX_V2
then
if mpu6500 start
then
fi
if lsm303d start
then
fi
if l3gd20 start
then
fi
# External I2C bus
if hmc5883 -C -T -X start
then
fi
fi
if meas_airspeed start
then
else

View File

@ -815,12 +815,6 @@ fi
# XXX potentially unset all script variables.
unset TUNE_ERR
#if ver hwcmp MINDPX_V2
#then
# start sonnar
# hc_sr04 start
#fi
# Boot is complete, inform MAVLink app(s) that the system is now fully up and running
mavlink boot_complete