Hello everybody,
I am a newbie, I'm a student, and l like doing DIY projects.
Currently i'm working on a interactive project, the idea is to create a tornado machine that can be controlled by users. I am sorry is this is a very long post, but I figured it's better to put all three part together instead of three different posts.
The first part:
I am using 3 motion sensors in form of a line with some distance between them. That would detect the presence of a hand that move side to side and each time each sensor detects a presence it would add some percentage to the speed of a fan that is installed on top until fan reaches 80% total capacity. I have the code with all three sensors working fine, now i don't know how to count the detection and use it as an input to control then fan.
The second part:
With every 10 detection, 3 led would light up on LED strip until you reach to the last 3 LEDs. The strip has 30 LED's. I have the same issue here, how illuminate every 3 LEDs with 10 detection.
The third part:
Using two ultra sound sensors on the sides of the object, when we try join our hands together the speed of the fan rises to maximum speed (100%) thus creating a thin tornado. In my code I am measuring the distance between the sensor and the objects to increase or reduce the speed of fan.
I would appreciate any help / suggestions. I have attached the codes that I have made and a picture of my fan a little video if the prototype.
Thank you
Fan_speed_motion_controlled.ino (2.67 KB)
Ultrasound.ino (1003 Bytes)