I am trying to make a circuit that will be used for turning on a light whenever there are 1 or more people in a room. I need to add to a variable counter when someone enters and subtract when someone leaves. However, I do not know how to use the ultrasonic sensor for this purpose. What can I do?
-
Google. If you know how to use the Ultrasonic sensor and know the C++ basics, this will be very easy.– Python SchlangeMay 7, 2021 at 7:09
-
How do you find out whether the person is entering or exiting– NinePlusTenEqualsTwentyOneMay 7, 2021 at 7:15
-
Is there some distance change thing– NinePlusTenEqualsTwentyOneMay 7, 2021 at 7:16
-
You'd have to place two Sensors next door, and if both are triggered, someone got in or out. You can check whether the person went in or out by looking what Sensor was triggered first.– Python SchlangeMay 7, 2021 at 7:18
-
thanks for the help– NinePlusTenEqualsTwentyOneMay 7, 2021 at 7:26