Automatic commit. Thu Aug 23 16:00:08 WST 2012
[matches/honours.git] / research / TCS / pressure / get_pressure.sh
diff --git a/research/TCS/pressure/get_pressure.sh b/research/TCS/pressure/get_pressure.sh
new file mode 100755 (executable)
index 0000000..5c7744e
--- /dev/null
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+imgdir="/home/sam/Documents/University/honours/pressure_imgs"
+
+get_digits=/home/sam/Documents/University/honours/research/TCS/pressure/get_digits.py
+process_digits=/home/sam/Documents/University/honours/research/TCS/pressure/process_digits.py
+
+mkdir -p $imgdir 2>/dev/null
+name=$(date +%F-%H%M%S.jpg)
+fswebcam --device /dev/video1 -r 640x480 --jpeg 85 $imgdir/$name 2>/dev/null
+$get_digits $imgdir/$name $imgdir/$name 2>/dev/null
+
+if [ "$1" != "" ]; then
+       eog $imgdir/$name
+fi
+
+$process_digits $imgdir/$name

UCC git Repository :: git.ucc.asn.au