Using Logic Gates to Make an Autometic Watering System
Simple circuits made of up the different types of logic gates – NOT, OR, AND NOR, NAND, XOR, XNOR – can be used to perform simple and useful tasks. Because the circuits are simple and the logic gates are reliable and mass produced, the circuits are reliable.
One such is the circuit used to make a safety watering system. The circuit is shown below. The system is designed to water plants only if the contacts (which may be buried in soil) are dry at night.
If both these conditions are fulfilled, then the resistance of the light dependent resistor is high so input 2 to the first NAND GATE is 1 and input 2 is 0. The output from the first NAND GATE is 1 and this is input 3 to the second NAND GATE. If the switch is pushed then input 4 to the second NAND GATE is 1, so the electrmagnet is switched on, the spring loaded switch is closed and the pump operates. If the switch is not pushed then input 4 is1 so the output from the second NAND GATE is 0 and the pump does not operate.