Skip to content

Arduino irrigation automation The setup includes an Arduino Uno, water pump, water hose, water level sensor and Arduino adapter card, and a blue relay.

Notifications You must be signed in to change notification settings

ReinhardLenz/arduino_flower_water_kalman_filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

arduino_flower_water_kalman_filter

Arduino irrigation automation This seems to be a pretty common type of Arduino project. I’m terribly lazy to water my flowers, often forgot for weeks, and I want the flower to be watered automatically with a pump whenever the water runs out. The setup includes an Arduino Uno, water pump, water hose, water level sensor and Arduino adapter card, and a blue relay. I took some program example from the Internet as a starter. I tried to find a challenge for myself. There is a delay command in the original program example, which prevents the pump from starting immediately the sensor detects that the water level has gone dry. But at that point, the program cycle is interrupted. In my program version, the program cycle is never interrupted, but sensor signal change doesn't cause any immeditae raction, but 2 different counters are triggered and then increased during every program cycle, until a time threshold triggers again. The first counter starts when the sensor state goes from wet to dry. The counter then waits a longer time before the pump starts, because it does not matter that the flower is dry for a short time, but it is more important that the pump battery does not run out because the pump is starting all the time, and then running only few seconds. On the other hand, as soon as the pump has started and starts filling the water pot, the pump must be switched off quickly when the sensor detects the water, otherwise the plate under the flower pot would overflow and the water will spill to the floor and cause damage. Therefore, the second counter shuts off its pump immediately when the sensor detects water in the plate under the flower pot. For the first time I used a relay, so in principle Arduino can also connect the right mains devices, such as a lamp, socket, radiators, radio, etc. it feels very exiting, to hear the relay click! But this still feels a bit dangerous, so all devices at this stage only run on battery. later addition: The problem with the first circuit and program is that the tank from which the water is taken, can be empty. Therefore, when the pump starts, it is necessary to prevent the pump from running continuously and the supply battery of the pump would be discharged unneccessary, even if there is no hope that the pump will add water to the flowers. Because in this case the pump runs empty, and only pumps air. Therefore, when the pump is started, a seperate counter starts, and when the counter has reached the limit value, the pump switches off and at the same time the red LED lights up. Then from the red LED I can see, that I have to add water to the water tank. After that, I press a reset button. The reset button will turn off the red light and puts the pump runtime counter to zero. So the next time the sensor indicates that the flower is dry, the pump will start rotating again. But unless water is added to the tank, the pump will not run as it would be a waste of battery energy. This counter should be so, that within counter time, the reservoir is emptied in any case.

About

Arduino irrigation automation The setup includes an Arduino Uno, water pump, water hose, water level sensor and Arduino adapter card, and a blue relay.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages