I was wondering if someone could help and guide me in a little project that I am working on.
I am making an automated watering system for my wife.
I can't seem to wrap my head around the 'C' script/code.
This is what I want to happen.
Using an LDR I wish to determine weather it is day or night. If it is night time, the program will wait 60 minutes and try again. This time if it is day time it will check the soil moisture. If the soil moisture is too wet, then it will wait 60 minutes and then restart the program. When the soil moisture is dry enough it flicks a relay that turns on a solidnoid and the water is turned on for 30 minutes. Then the software will restart.
Sounds complicated, but I have it all drawn up, it's just the 'C' I am having troubles with.
Could anyone please spend a little time for me and help out.
I am making an automated watering system for my wife.
I can't seem to wrap my head around the 'C' script/code.
This is what I want to happen.
Using an LDR I wish to determine weather it is day or night. If it is night time, the program will wait 60 minutes and try again. This time if it is day time it will check the soil moisture. If the soil moisture is too wet, then it will wait 60 minutes and then restart the program. When the soil moisture is dry enough it flicks a relay that turns on a solidnoid and the water is turned on for 30 minutes. Then the software will restart.
Sounds complicated, but I have it all drawn up, it's just the 'C' I am having troubles with.
Could anyone please spend a little time for me and help out.