Fixed [[ bug and more cleaning.
This commit is contained in:
20
CS_scan.sh
20
CS_scan.sh
@ -31,7 +31,7 @@ sls_detector_put configuremac 0
|
||||
echo "The receiver should be waiting for data"
|
||||
echo "Please check and press any key to continue, or press q to exit this script"
|
||||
read -n 1 -s input
|
||||
if [ $input = "q" ]; then
|
||||
if [[ $input = "q" ]]; then
|
||||
echo "Exiting script"
|
||||
exit 1
|
||||
fi
|
||||
@ -71,8 +71,6 @@ do
|
||||
tint_sec=$(printf %.9f $(echo "$tint/1000000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68 # what is this doing?
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -84,8 +82,6 @@ do
|
||||
tint_sec=$(printf %.8f $(echo "$tint/100000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -97,8 +93,6 @@ do
|
||||
tint_sec=$(printf %.8f $(echo "$tint/100000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -110,8 +104,6 @@ do
|
||||
tint_sec=$(printf %.8f $(echo "$tint/100000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -123,8 +115,6 @@ do
|
||||
tint_sec=$(printf %.7f $(echo "$tint/10000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -136,8 +126,6 @@ do
|
||||
tint_sec=$(printf %.7f $(echo "$tint/10000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -149,8 +137,6 @@ do
|
||||
tint_sec=$(printf %.7f $(echo "$tint/10000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -162,8 +148,6 @@ do
|
||||
tint_sec=$(printf %.7f $(echo "$tint/1000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
@ -175,8 +159,6 @@ do
|
||||
tint_sec=$(printf %.7f $(echo "$tint/1000000" | bc -l))
|
||||
echo "setting integration time to (s) " $tint_sec
|
||||
sls_detector_put exptime $tint_sec
|
||||
sls_detector_get reg 0x68
|
||||
#sleep 1
|
||||
sls_detector_put status start
|
||||
sleep 4
|
||||
done
|
||||
|
Reference in New Issue
Block a user