I am using these circuits to create an automated sprinkler system, but I'll keep this brief. I'm running a DC solanoid valve and a relay switch using an Arduino from my computer. The Ardiono cannot power either device directly, so it switches the device indirectly via a NPN transistor. The 9V batteries can power both devices sufficiently. The diode is there neutralize any kickback in the coils (both the valve and the relay have coils so I'm using the same circuit design for both of them). I had the relay and valve turning on and off every 5 seconds to test them but then they stop doing this after a minute. I replaced the diode and that solved the problem for about a minute but then it stops working again (I think current is building up and gettting trapped somewhere but I don't want to remove the diodes). Is there any electronics whizz who can help me solve this riddle and stop the electical buildup or whatever it is causeing this?
I got the schematics from here using their design but I think there is something wrong and I can't figure it out . http://www.instructables.com/id/Control ... h-arduino/
Here are the design schematics in this picture