diff --git a/pcsensor b/pcsensor index 9229324..61f021e 100755 --- a/pcsensor +++ b/pcsensor @@ -18,13 +18,13 @@ if [ "${1}" = "config" ]; then echo "temp.label temperatue" echo "temp.type GAUGE" else - TEMP=`${PCSENSOR} -cm` + TEMP=`${PCSENSOR} -cm | head -n 1` if [[ $? != 0 ]]; then sleep 2 - TEMP=`${PCSENSOR} -cm` + TEMP=`${PCSENSOR} -cm | head -n 1` if [[ $? != 0 ]]; then sleep 6 - TEMP=`${PCSENSOR} -cm` + TEMP=`${PCSENSOR} -cm | head -n 1` fi fi echo "temp.value $TEMP"