DRV8825 and NEMA17

Hello, I’ve been a few days trying to drive this stepper motor while using a DRV8225 driver. I have everything connected as stated on Pololu but the only thing I get from the stepper is a constant buzz…
Here’s the code I’ve used: http://pastebin.com/LeB9MsWa

I cant move the stepper with my hands if 5v are set into the FAULT pin. And I don’t have a capacitor, is it a problem?
Thank you!

Hi,
Welcome to the forum.

Please read the first post in any forum entitled how to use this forum.
http://forum.arduino.cc/index.php/topic,148850.0.html then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.

Your stepper is a 42BYGHW609, NEMA17 is the motor size so it means nothing to electrical specs.
stepperspecs2016.jpg

Tom… :slight_smile:
PS Have you got

  • Black to A1
  • Green to A2
  • Red to B1
  • Blue to B2

To what value have you adjusted the driver current limit?

What are the voltage and current capabilities of the motor power supply?

The capacitor is used to prevent destruction of the motor driver by spikes in the motor power supply. You can certainly take the risk and leave it out.

Pls confirm: 1. You set the current limit of the Driver before you started any tests? 2. you made sure that you identified the two coils of the stepper motor (by measuring the resistance) ? 3. you connected Arduino Pin3 to DRV8825 "Step"-Input? 4. you connected Arduino Pin4 to DRV8825 "DIR"-Input? 5. you connected DRV8825-Pins "Sleep" and "SLEEP" to +5V of Arduino?

Your stepper will only move and do what you expect when ALL of those steps have been confirmed positively. When the stepper runs after you could verify all these check points, don't forget to add the capacitor (I would prefer at least 470uF).

byleandroid: I cant move the stepper with my hands if 5v are set into the FAULT pin. And I don't have a capacitor, is it a problem?

The FAULT pin is an output from the driver. It should normally be HIGH if nothing is connected to it and if there is no fault. If it is low there is an internal problem in the driver - probably a overload.

Start with a much slower step speed - perhaps 2 steps per second. Instead of this

   digitalWrite(steps, HIGH);  
    delayMicroseconds(2000);
    digitalWrite(steps, LOW);
    delayMicroseconds(2000);

try this

   digitalWrite(steps, HIGH);  
    delayMicroseconds(10);
    digitalWrite(steps, LOW);
    delay(500);

...R Stepper Motor Basics Simple Stepper Code

if the motor is sitting on a bench i.e. no load vmot at least 12volts and all leads correct you need to manually adjust the pot until the motor moves without stutter best bet have vmot on a switch to turn off and on during adjustment turn pot turn on repeat till it moves otherwise the 8825 will get hot enough to melt glue holding heatsink on. once you get it moving adjust the pot each way till it stops then set it midway this worked for me if 8825 gets too hot thermal protection shuts it off also try different microsteps 1/32 requires 6400 steps in your sketch for a complete turn this is a 1.8 degree motor 200 steps/rev use a delaymicroseconds 200 in your sketch to adjust. i have written a sketch with 2 pushbuttons one forward other reverse once pressed it does one complete rev in the chosen direction and holding is continuous motion a pot can be added for speed you can set several drivers with this the 4988 will work with this motor

rogertee: if the motor is sitting on a bench i.e. no load vmot at least 12volts and all leads correct you need to manually adjust the pot until the motor moves without stutter best bet have vmot on a switch to turn off and on during adjustment

Why not just use the recommended way with a multimeter to measure the voltage on the test pin.

After all, the main reason for adjusting the DRV8825 is to protect the motor from excessive current - and your method takes no account of that.

@rpt007 has a good description of the adjustment process here

...R

an update to your specific motor after you set vref a final test remove one stepper wire from driver and connect it to a multimeter and the other lead to the driver and adjust the current with meter on amps dc for 1.2 amps when motor is not moving this will keep both motor and driver cool without missing steps on 1/32 which draws 100 % this motor is rated for 1.75 amps

rogertee: remove one stepper wire from driver and

NEVER disconnect a motor wire from the driver while the stepper driver is powered up - you will almost certainly destroy the driver instantly.

...R

byleandroid: Hello, I've been a few days trying to drive this stepper motor while using a DRV8225 driver. I have everything connected as stated on Pololu but the only thing I get from the stepper is a constant buzz... Here's the code I've used: http://pastebin.com/LeB9MsWa |500x230 I cant move the stepper with my hands if 5v are set into the FAULT pin. And I don't have a capacitor, is it a problem? Thank you!

i have similar problem as you, but have solved yet.

maomaoyun:
i have similar problem as you, but have solved yet.

I’m guessing that should be “have not solved”

You need to tell us that you have carefully followed all the advice earlier in this Thread.

If that does not solve your problem you need to make a simple pencil drawing showing how YOU have everything connected and post a photo of the drawing. See this Simple Image Posting Guide

AND you need to post the program that YOU have uploaded to your Arduino and tell us in detail what happens when you run the program.

…R