MechMate CNC Router Forum

MechMate CNC Router Forum (http://www.mechmate.com/forums/index.php)
-   701. Motor Drives (http://www.mechmate.com/forums/forumdisplay.php?f=14)
-   -   Use Arduino Uno to test stepper drivers and stepper motors (http://www.mechmate.com/forums/showthread.php?t=4844)

Richards Sat 13 December 2014 11:12

Use Arduino Uno to test stepper drivers and stepper motors
 
1 Attachment(s)
I'm attaching an Arduino sketch (program) that you can use with an Arduino Uno to test your stepper drivers and stepper motors. This program requires that you have a power supply connected to the stepper driver and that the stepper driver is connected properly to the motor. The program supplies the step pulse signal and the direction signal for the stepper driver. You can change settings by changing values in the DEFINE section at the start of the program. The program uses an array to create acceleration and deceleration values. You can modify the values. The values in the array will start the motor at 100 RPM and then ramp up to 650 RPM, which are the values that I used with a PK268-02A motor that I had on the bench and the 48VDC power supply that was driving it. If your motor stalls, change the rampSteps from the default 57 to a lower number. Change/test as required until the motor works as expected.

In operation, the motor will turn one direction for the number of steps defined by "totalSteps", wait for the amount of milliseconds defined by "waitTime", and then reverse. It will operate as long as power is supplied to the Arduino and to the motor.

The Arduino Uno R3 is available worldwide. Here in America, most Radio Shack stores carry it. It is also available from sparkfun.com and adafruit.com. The price is $25 to $35, depending on where you buy it.

The Arduino programming language (required) can be downloaded from arduino.cc. There is no cost for the software. Versions are available for Linux, Windows, and for OS-X (apple).

Unzip the stepper_tester.zip file and open the step_pulse_2014_12_12.ino file.

If you have problems or questions, send me a private message.

-Mike Richards


All times are GMT -6. The time now is 09:02.

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.