:
#
# lha.sh - create the lha.scr (LED Sign script file) for use on my web page.
#

TEMP=`/usr/local/bin/wx200 --temp diane 2>/dev/null` # Get the temperature
TEMP=${TEMP:="unknown"}

DATE=`/bin/date '+%H:%M'`			# Get the date
Update=`/bin/cat update.txt`			# Get the index.html version

# The is the skeleton for the the LED Sign script

FILE="!! The Demo script \n
Do \n

   Appear center=true URL=http://automate.netpedia.net/ text=\\\bWelcome to \n
   Sleep delay=1500 \n

   ScrollUp delay=120 center=true URL=http://automate.netpedia.net/ text=\\\oLinux Home Automation \n
   Sleep delay=1000 \n

   ScrollLeft delay=30 startspace=120 endspace=20 URL=http://automate.netpedia.net/ text=\\yLast updated:\\\c ${Update} \n


   ScrollLeft delay=30 startspace=120 endspace=20 URL=http://automate.netpedia.net/ text=\\wNick Estes has start an Open Source hardware/software project called the \\oGNU/Linux Home Automation Project\\w, Click here to visit the site.\\\w\n
   ScrollLeft startspace=80 endspace=140 text=\\gCentral NJ temperature: ${TEMP} @ ${DATE} \n
   Sleep delay=1000 \n

Repeat times=5 \n

Reload\n
"

# Write it out

/bin/echo ${FILE} >lha.scr

