diff options
author | Lorenz Meier <lm@inf.ethz.ch> | 2014-01-04 13:54:14 +0100 |
---|---|---|
committer | Lorenz Meier <lm@inf.ethz.ch> | 2014-01-04 13:54:14 +0100 |
commit | 97e8386290b89b0877fe57de31000801b7d0b8c0 (patch) | |
tree | f4bc783819d6f0320ed9e9ed39ec34d9f557d647 /ROMFS/px4fmu_test | |
parent | e7c1e8e94b082a0ba5b22b2f449844ee9a76a50a (diff) | |
download | px4-firmware-97e8386290b89b0877fe57de31000801b7d0b8c0.tar.gz px4-firmware-97e8386290b89b0877fe57de31000801b7d0b8c0.tar.bz2 px4-firmware-97e8386290b89b0877fe57de31000801b7d0b8c0.zip |
Auto-restarting mount test if config file present
Diffstat (limited to 'ROMFS/px4fmu_test')
-rw-r--r-- | ROMFS/px4fmu_test/init.d/rcS | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/ROMFS/px4fmu_test/init.d/rcS b/ROMFS/px4fmu_test/init.d/rcS index 6aa1d3d46..d8ed71f12 100644 --- a/ROMFS/px4fmu_test/init.d/rcS +++ b/ROMFS/px4fmu_test/init.d/rcS @@ -9,4 +9,27 @@ then # Try to get an USB console nshterm /dev/ttyACM0 & -fi
\ No newline at end of file +fi + +# +# Try to mount the microSD card. +# +echo "[init] looking for microSD..." +if mount -t vfat /dev/mmcsd0 /fs/microsd +then + echo "[init] card mounted at /fs/microsd" + # Start playing the startup tune + tone_alarm start +else + echo "[init] no microSD card found" + # Play SOS + tone_alarm error +fi + +# +# The presence of this file suggests we're running a mount stress test +# +if [ -f /fs/microsd/mount_test_cmds ] +then + tests mount +fi |