A good percentage of commercial stepper systems are closed loop to a certain extent. I think you will find a lot of code either for the PIC itself or for the stamp extension. Some closed loop stepper methods are step verification, back emf detection (sensorless and sensored), and full servo with continuous sensor feedback.
The simplest position control, uses a low count per revolution encoder to 'count' the number of steps actually moved. A simple circuit compares expected versus measured steps. Remediation of the error condition is up to you and depends on the movement. If the move was a cutting one involving interpolation you should quit with an error and adjust the system. If the move was positional only you can add the lost steps to the end.
The stepper's back electromotive force (emf) allows measurement and control of velocity. This is a lot more complicated but can give you more information about the error causing condition. You also have to change to open loop for the final move and hope for the best.
Then full servo. |