Did design something very similiar. Except, the cycle was twice a day for 10 minutes each time, every day. Since the cycle operated every day, the code was much simpler. Basically Off for 11 hours 50 minutes, then ON for 10 minutes, and repeat. Since the actual time the cycle initiated was unimportant, I did not use a RTC. Also, to save costs and complexity, there was no display (besides the cycle status LED), and no switches (except a forced initiate switch). To change the settings, you just connect to a PC running a terminal program. The unit displays current cycle settings, and takes in new ones if they are to be changed, saves them in the EEPROM. After this you just disconnect the PC, and start. In your case, you could do the same, except the cycle would be ON for 5 minuts, OFF for 7 hours 5minuts, ON for 5 minuts, OFF for 7 hours 5minuts,ON for 5 minuts, OFF for 7 hours 5minuts, OFF for 24 hours, then repeat. Regards, Anand Dhuru ----- Original Message ----- From: "Picdude" To: Sent: Wednesday, June 18, 2003 3:58 AM Subject: [PIC]: Emergency PIC application dev Need to implement a super-simple sprinkler system really quickly, and since I don't live at that property, I need a controller. [ My (X10) home automation controllers are all in storage so I don't have that option easily available.] Some quick discussion with a gardening-savvy neighbor gives me a watering schedule of 3 times per day for, 5 mins each, and only on every alternate day. The low-cost controllers I can find (up to ~$40 will not do this easily), so it'll have to be a PIC controller. Woo-hoo!!! First thought, no prob, I have been working on a clock w/alarm and other features, so I'll hack that code/circuit and for now I'll hardcode the trigger times/days. Yes, I promise I'll do it the correct way later. I figure I can actually pull this coding off in a few hours. I'll modify the buzzer output to drive a relay instead, which'll switch 24VAC to the valve. Only cost out of my pocket is a 24VAC transformer from Radio Shack, which is $6. Add the other plumbing, hoses, valves, spray heads, etc and I'm up to $52 total max. But before I start, it seems like this would be a common app. Anyone here know of such code available on the web? Seems better not to re-invent the wheel, if this wheel already exists. Cheers, -Neil. -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.489 / Virus Database: 288 - Release Date: 10-Jun-03 -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.