Tell us about yourself!
Line now reads: $compensation=-4.4;But it is still about 4-5inches too high.
Now that I have been able to measure, I don't think it's measuring correctly. I measured about 7 inches of water, but it displays 11.4 inches.
There we go, that is working well now. Any chance of keeping any history? Say for the last 24 hours? That would be cool to see.My last question is this value:$compensation=-11;What is the compensation for? Is that the # for how low the water will get once the water is pumped out? OR is it the distance from the top of the pit (or $deep) minus where the sensor sits? Is it in inches or cm as well? I also noticed $deep needed to be in inches, not cm.
no worries, was compensation -11 in cm or inches? I assume cm :D .. so far looks to be working great now that I added it as root cron. Would be cool if you could add some historical graphs of data. My programming is probably not good enough to be able to retain the data, and then display it in a nice graph.
Thanks, that clears some stuff up. For my cron I would run:3 * * * * /path/to/php /var/www/html/chklevel.phpI tried running the script manually, and it puked out some errors:pi@pi /var/www/html $ ./chklevel.php./chklevel.php: line 1: ?php: No such file or directory./chklevel.php: line 2: //: Is a directory./chklevel.php: line 3: syntax error near unexpected token `'/var/www/html/''./chklevel.php: line 3: `chdir('/var/www/html/');'is the $deep in cm? Is that from sensor to bottom of pit? Also, what does compensation equate to? Should that be preset as well from 11? Is that in cm or inches?
That worked, thanks! Also, any idea on these?is the $deep in cm? Is that from sensor to bottom of pit? Also, what does compensation equate to? Should that be preset as well from 11? Is that in cm or inches?Do you know how accurate the sensor is? I will get crazy readings like: Measure final 585cmThen I re run and it's 53cm, which is closer to accurate. Do I need to do anything so it will start measuring the depth of water? Have you found a way to retain results, so I can track trends and retain a little history?
Yeah, that worked, thanks. Shouldn't this work as a cron? 3 * * * * /etc/php5/apache2 /var/www/html/chklevel.phpI also moved the sensor, and it never changed depth, it always said this:pi@pi /var/www/html $ php chklevel.php sh: 1: /var/www/html/sensor.py: Permission deniedPHP Notice: Undefined offset: 0 in /var/www/html/chklevel.php on line 13 Mesure final -11cm Mesure final -4.3pouce44 have been send .The maximum of email have been reach
I am a little confused here, what do I need to edit? I have gone through all of the files, edited what I think I should, GPIO trig/echo, directories, etc. What needs to be cron'd? How often? Where does the data go?