#!/usr/bin/bash

if [ "$2" ]; then
  stty -F $1 "$2"
fi

t=`head -c 7 $1 | tr -d '\377+C' | sed 's/^0*//g'`

echo "TEMP OK - $t C|temperature=${t};40;60;0"
exit 0
