Close

Electronics part 1

A project log for Yet another automated watering project.

Solar powered budget automated watering system.

labanssonLabansson 05/16/2016 at 20:140 Comments

The project is coming along nicely. I have decided to add a “water sensor” (two nails with fabric in between) to my project. I decided to do that because I plan to run the watering from a rain water barrel and if it has been raining I won’t water the plants and thus save some water. I will use the output from one solar panel as an analogue input for my microcontroller and use the information to know when dusk has arrived. Later I might add some sampling of the solar panel during the day and a temp sensor and use the information from them to adjust the watering time, but that will be a later project. To figure out how to wire everything up I “reversed engineered” the garden solar light. It was based on a chip marked YX8018, but more on that later. When I tried to figure out the circuit in the garden solar light I realized that just sticking the positive of the solar panel to an analogue pin wasn’t going to work. Damnit!

I did some testing with the “water sensor” and my multimeter yesterday. When I measured resistance I found that dry fabric showed up as open circuit on the multimeter on the 20k range. When I made it wet using water from my sink it had 6-7KOhms between the nails. A voltage divider with 15kOhms connected to V+ and an analogue pin will surely make me figure out if the water sensor is wet.

I got my electrically operated ball valve in the mail the other day and it looks good. I tried it at home using just a couple of batteries and it opened and closed fine with just three AAA alkaline cells (total of 4,5V) I found in a drawer. I haven’t decided if I will boost the voltage up to 12V (it is said to operated at 12V) or if I am going to operate it out-of-spec with just the raw solar cell battery voltage. I think I will go for the out-of-spec solution for now and throw in a 12V booster circuit if it doesnt work reliably. It one similar to this:

I also bought a L293E H-bridge to be able to operate the motor for the valve. I would have preferred a L293D since it has protection diodes (I don’t think 293E has them?) and no sense-inputs (which I don’t plan to use), but the L293E was available over the counter in my local parts shop, so it will have to do. I don’t have any diodes lying around at home, though. I wonder if I will damage something over time if I don’t use any protection. For now I think I will just stick a 1nF-ish capacitor across the power leads for the motor and hope for the best.

I was thinking about etching a PCB for everything, but I have decided to just use some perf-board. I really hate soldering wires to perf-board, but the build will consist of just a couple of IC’s and some passives, so I think an etched PCB will be a bit overkill.

Discussions