I have a project wherein I need to control the speed of a DC motor which depends on the distance of my hand to a proximity sensor.
I purchased HC-SR04 for my proximity sensor.
However, I have noticed that the proximity sensor's output is a square wave pulse. Using Arduino Uno, is there a code wherein the pulse output of the HC-SR04 can directly modulate the speed of the motor?
If your question has been answered to your satisfaction, please mark the thread as solved so that other members that wish to help will not waste their time opening the thread only to find that you no longer require assistance.