Problem with pololu a4988

Hello,

I have connected a pololu a4988 to a bipolar stepper motor, but it doesn’t work. The pololu is new and I have checked all connections and I can’t find where the problem is. The electric scheme is as follows:

And the code:

#include <AccelStepper.h>

AccelStepper stepper(1,30,32); 

void setup()
{  
   stepper.setMaxSpeed(60);
   stepper.setSpeed(50);
     pinMode(48,OUTPUT);
  pinMode(46,OUTPUT);
  pinMode(44,OUTPUT);
  pinMode(42,OUTPUT);
  digitalWrite(48,LOW);
  digitalWrite(46,LOW);
  digitalWrite(44,LOW);
  digitalWrite(42,LOW);   
}

void loop()
{  
   stepper.runSpeed();
}

I’d be very appreciated if you can help me to solve this issue.
Thank you very much!


Hello.

Are you connecting the grounds between the driver and the Arduino? Do you have access to an oscilloscope? Could you post a picture of your setup?

- Ryan