Software apps and online services
Hand tools and fabrication machines
My name is Shubhankar Singh and this is how I created WaterWorks.
Summer was in full swing and when my father installed a sprinkler system, I criticized it for its limitations. Sure we would never need to use the hose and stand there watering it ourselves, but the system that was put in place still required us to go outside and operate the system manually.
Last school year was when I first became familiar with the Alexa console as well as AWS Lambda service. I created a score keeping skill that was tailored around the game of Quirkle, which by the way is a great board game. This skill was submitted as my IB Computer Science SL IA project. Thanks to my skills in creating skills I was able to very quickly develop a solution to the water sprinkler problem. The only question left to answer was, how would I control something in the physical world, as big as a sprinkler system, with solely my voice and current knowledge in the Alexa Skills Kit. The answer was the addition of a Raspberry Pi 3 Model B.
The water sprinkler that was already in place used four solenoid valves which controlled 4 solenoid valves that open and close 4 hoses which feed to water sprinkler heads arranged all around the house. Before implementing Waterworks in the sprinkler system, the solenoid valves were controlled by an automated timer system control by an Orbit module. Because of our Bipolar weather in the PNW during the summer, this timer system simply would not suffice, as sometimes if it rains we wouldn't want to turn on the system at all. The next challenge was figuring out how to open and close solenoid valves using a raspberry pi.
Using a multi-meter, I was able to figure out that the Orbit module sent a 18v dc electric charge for a fraction of a second in order to open a solenoid valve. To close the same solenoid, it would require that the polarity of the electric charge be reversed. This system is rather complicated and for a while I was considering ordering 4 new AC solenoid valves, which would be much simpler to control, without the need to switch the polarity of the charges sent to the solenoid.
Before switching to a new system of solenoids, I tried to better understand why DC solenoid valves would latch in this manner. I came to the conclusion that AC solenoid valves would draw voltage for the period of time that they were open for. In other words, AC solenoids would draw much more power than DC solenoid s. Although most forums on the topic of automated sprinkler systems advised that AC solenoids would be much easier to control by means of arduino or raspberry pi, I was now determined to figure out how to control latching DC solenoids.Schematic
Here is a schematic of my solution using a total of 12 relay switches that can be controlled by the raspberry pi:
NC stands for "normally closed", and when the relay is opened it becomes the connection that carries electrical current. NO stands for "normally open" which means that when the relay is closed, it is open by default. With these three relays, the Raspberry pi can now open and close the solenoid valves using the 18v DC power source.
On the raspberry pi, there are 8 python scripts which turn on or off the ground relay, and then for a half a second open either the Positive Relay 1, or Positive Relay 2. These scripts are called upon through SSH communication code running in java 8 in lambda. I had to open up the raspberry pi to allowed for these SSH commands through a service called weaved Pi, however opening up port forwarding will work the same.
Throughout the project there were many obstacle which I had to overcome, but now that we can simply say something like "Alexa, ask WaterWorks to open hose three" it was all worth it in the end.Demo video
Here is a video demonstrating the use of WaterWorks:
Thanks for looking through my project!
Contact me at Shubhankar.email@example.com for any questions you have. No soliciting.