- #1
mastermechanic
- 108
- 15
Hello,
What I have
I have a NEMA17 stepper motor driven by a DRV8825 driver module, an arduino uno, a multiturn potentiometer.
What I want to do
I want to control the stepper motors in a PID closed loop. The motor shaft will be connected to the potentiometer and I will be sure that the motor goes to the exact position.
What I have done
All necessary physical connections (arduino,driver,pot,motor etc.) done correctly. I can spin the motor at different speeds, directions and send it to different step positions without using a library. So I am sure that there is no physical problem remaining. However, I dont exactly know how I can control it in a closed loop feedback. It is a bit different then driving a DC motor with PWM in a closed loop PID sketch therefore I am confused.
I am not constraining you,
You can explain how it's done without using a library
You can explain how it's done with using a library (i.e. accelstepper.h)
You can link some pages or videos showing an example sketch
I just want to learn how to control the position of stepper motor in closed loop as it is implemented in robotic arms.
What I have
I have a NEMA17 stepper motor driven by a DRV8825 driver module, an arduino uno, a multiturn potentiometer.
What I want to do
I want to control the stepper motors in a PID closed loop. The motor shaft will be connected to the potentiometer and I will be sure that the motor goes to the exact position.
What I have done
All necessary physical connections (arduino,driver,pot,motor etc.) done correctly. I can spin the motor at different speeds, directions and send it to different step positions without using a library. So I am sure that there is no physical problem remaining. However, I dont exactly know how I can control it in a closed loop feedback. It is a bit different then driving a DC motor with PWM in a closed loop PID sketch therefore I am confused.
I am not constraining you,
You can explain how it's done without using a library
You can explain how it's done with using a library (i.e. accelstepper.h)
You can link some pages or videos showing an example sketch
I just want to learn how to control the position of stepper motor in closed loop as it is implemented in robotic arms.