January 17, 2007

More variable problems

I was actually going to do a test run today with everything running, but the first time the program tried to upload the data to the webserver, I started getting corrupt output. As that data is getting written out to the log file, the datetime stamp is getting inserted into the middle of the data variable. So a full test will be delayed until tonight or tommorow.

January 16, 2007

Awk saves the day

Solved a minor script problem by using awk. I needed the script that uploads the sensor data to the website to keep trying until the data was uploaded and processed. I was having trouble comparing variables because /bin/sh treated spaces as a field separator. I used awk to seperate the fields using a ‘;’. This allowed me to compare the data fields instead of the entire line.

· Next entries »