Commits

Craig Swank committed a941717

updated the sprinklers example to show the current crontab I am using

Comments (0)

Files changed (1)

examples/sprinklers.py

 accepts a '--command' argument, which starts a Socket, sends the command, and
 then exits.
 
-# Minute   Hour   Day of Month       Month          Day of Week         Command
-# (0-59)  (0-23)     (1-31)    (1-12 or Jan-Dec)  (0-6 or Sun-Sat) 
-    0       5          *             *                Wed               gadgets --command 'water front yard for 20 minutes'
-    0       5          *             *                Fri               gadgets --command 'water front yard for 20 minutes'
-    25      5          *             *                Wed               gadgets --command 'water back yard for 20 minutes'
-    25      5          *             *                Fri               gadgets --command 'water back yard for 20 minutes'
-    50      5          *             *                Wed               gadgets --command 'water sidewalk for 20 minutes'
-    50      5          *             *                Fri               gadgets --command 'water sidewalk for 20 minutes'
-    0       4          *             *                Mon               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Tue               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Wed               gadgets --command 'water front garden for 5 minutes'    
-    0       4          *             *                Thu               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Fri               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Sat               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Sun               gadgets --command 'water front garden for 5 minutes'
-    0       4          *             *                Mon               gadgets --command 'water back garden for 5 minutes'
-    0       4          *             *                Tue               gadgets --command 'water back garden for 5 minutes'
-    0       4          *             *                Wed               gadgets --command 'water back garden for 5 minutes'    
-    0       4          *             *                Thu               gadgets --command 'water back garden for 5 minutes'
-    0       4          *             *                Fri               gadgets --command 'water back garden for 5 minutes'
-    0       4          *             *                Sat               gadgets --command 'water back garden for 5 minutes'
-    0       4          *             *                Sun               gadgets --command 'water back garden for 5 minutes'
+# Minute   Hour   Day of Month       Month          Day of Week        Command    
+# (0-59)  (0-23)     (1-31)    (1-12 or Jan-Dec)  (0-6 or Sun-Sat)
+0   5   *  *  Wed  python2 /opt/local/gadgets/examples/sprinklers.py -m 'water front yard for 20 minutes'
+21  5   *  *  Wed  python2 /opt/local/gadgets/examples/sprinklers.py -m 'water back yard for 20 minutes'
+0   5   *  *  Sat  python2 /opt/local/gadgets/examples/sprinklers.py -m 'water front yard for 20 minutes'
+21  5   *  *  Sat  python2 /opt/local/gadgets/examples/sprinklers.py -m 'water back yard for 20 minutes'
+
+0   4   *  *  *    python2 /opt/local/gadgets/examples/sprinklers.py -m 'water back garden for 5 minutes'
+
+42  9,10,11,12,13,14,15,16,17,18 * * * python2 /opt/local/gadgets/examples/sprinklers.py -m 'water front garden for 2 minutes'
+
+50  9,10,11,12,13,14,15,16,17,18 * * * python2 /opt/local/gadgets/examples/sprinklers.py -m 'water sidewalk for 2 minutes'
+0   3 * * * python2 /opt/local/gadgets/examples/sprinklers.py -m 'water sidewalk for 30 minutes'
+
+NOTE:  I just planted a bunch of plants in the sidewalk zone and the front garden and it is the middle of summer.  I
+am watering them for 2 minutes each hour during the day so they don't dry out, not because I'm a water wasting bastard.
 """