01-19-2012 02:36 AM
Hello,
after solving the problems with the digital read I recognized a new problem. I try to control a stepper motor with my arduino and the stepper motor driver A4988 from pololu http://www.pololu.com/catalog/product/1182 . When I use the new stepper.vis my motor sounds terribly and looses many steps. Before using the new vis I used the tone function to generate my step signal and another pin for direction, with this configuration the motor works fine, but I don't find a reliable way to count the steps for position.
I think the problem is that the new vis only generate a frequence signal with very small peaks (I measured the step signals with an oscilloscope), while the tone function generates a 50% duty cycle square frequence.
Do you have any solution for my problem?
Best regards
Torsten
01-19-2012 10:23 AM
Hey Torsten,
I have been testing the stepper motor example out on some other drivers this week and have noticed similar behavior. I will post back here when I have a solution.
01-23-2012 02:14 AM
Did you current limit those drivers using the onboard pot? How much power are you suppling in regards to your stepper's specs?
I have not been able to get the new stepper example working yet just sending 1/0 in a loop after initializations. Works but slow.
01-23-2012 03:38 PM
I have made some fixes to the stepper motor examples and added a new control method for the EasyStepper which should work better for motor drivers than the current options. We will be releasing it in a patch soon.
01-24-2012 12:35 AM
Thank you. I hope the patch will come soon.
01-24-2012 12:36 AM
I limit the current to round about 1/3 . My Motor characteristics: 2V/1.8A. My motor supply voltage is 12V.
01-24-2012 07:59 AM
The new mode should be very similar to the current 2 wire (pulse and direction) mode. Is this the mode you are currently using for your motor controller?
01-24-2012 03:34 PM
I am asuming you meant 12V not 2. @ that current make sure you have a heatsink (sparkfun). Also most of the readily available pulse/dir microstepper controllers act differently in full step mode so now you know too. Good luck.
@Kevin this is the mode I favor by far & the mode used by pololu & sparkfun dedicated stepper drivers. Thanks!
01-25-2012 12:53 AM
Yes I used the 2 wire pulse and direction mode. Do you know how long are the pulses (in microseconds)? From the datasheet minimum pulse width for my stepper driver is 1 microsecond. Is it possible to generate a 50% dutycycle step frequence signal. Because with steps generated by the tone function the stepper runs perfect.
@allthingz
Yes I use an aluminium heatsink. The stepper motor data is 2V/1.8A (data printed on the motor) but I don't know how they get these values. Seems to me that they define maximum voltage and current with DC-current. This is the stepper motor I am controlling
ST4118M1804 from nanotec http://de.nanotec.com/schrittmotor_st4118.html. They offer a stepper driver http://de.nanotec.com/schrittmotor_steuerungen_smc11.html which is similar to Pololus for this kind of motor.
01-25-2012 09:34 AM
I am not sure how long the pulses are in microseconds but I can't imagine its less than 1uS. Our driver makes calls into the AccelStepper motor driver which handles tha actual pulse generation:http://www.open.com.au/mikem/arduino/AccelStepper/