Today we are going to make a closed-loop stepper motor for accurate position feedback, we are achieving this by coupling potentiometer in perfect synchronization with the stepper motor.
As we all know potentiometer can’t be rotated to one side only, for increasing and decreasing the resistance we used to turn it forwards and backward.
So here for this application we want the potentiometers should be fully rotatable, to achieve that what I have done is, I opened the potentiometer and break the lock inside it and put it back inside its case, now it is fully rotatable.
But there was a problem with that, when I connected the potentiometer to the analog input of Arduino and reading the values, the potentiometers showing very random values when they reach the point where the lock was situated.
So to rectify this issue I have taken one more potentiometer and do the same procedure. Now when one potentiometer reaches that random value position we can get feedback from the other one and vice versa.
- Stepper motor
- Stepper driver
To buy electronic components order from UTSOURCE
3 thoughts on “Position control of stepper motor using potentiometers”
I didnt understand what the random function is doing. Can you please elaborate on it .. thanks
Hi Ekaggrat, actually I build this for a game. In that game when I press the momentary button the wheel will stop at a random position and the person will win prices or loss
The code is not there, it would be possible to publish it, Thanks