Stepper vibrates and draws current after disabling

My stepper keep vibrating and drawing current after disabling all outputs? The driver is a L298N connected to a UNO.

My code is:

#include <AccelStepper.h>

int stepCount = 0;

AccelStepper stepper1 (AccelStepper::FULL4WIRE, 8,9,10,11);

int steps = 0;

void test(){
  stepper1.moveTo(2000);
  stepper1.runSpeedToPosition();
}

void setup() {
  stepper1.setMaxSpeed(200);
  stepper1.setSpeed(100);
  stepper1.setAcceleration(50); 

}

void loop() {
  test();
  stepper1.run();
  stepper1.disableOutputs();
}
 

The L298N is an ancient, obsolete, very inefficient brushed DC motor driver, not a stepper driver.

Please post a hand drawn wiring diagram, and links to all the components, especially the motor and the motor power supply.

links:

It is an original arduino uno.

Stepper Datasheet
Powersupply

If the driver is the problem here, I will get a new one as I have multiple steppers laying around.

That's not a schematic!

Anyway, it doesn't look like you have the enable pins connected!

The link to the stepper motor goes to a page that my virus scanner rejects. Please post a valid link to the actual motor product page or data sheet.

Most stepper motors require a modern, current limiting stepper driver that can handle the maximum rated winding current. Pololu has the best selection.

Thats strange. That is were I find the PDF without problem. I am not able to upload a PDF as a new user... So i uploaded it to wetransfer(PDF) It is a chinese brand, so could not find a places where they were sold. I got them from free. Do you have a stepper driver that you would recommend?

I don't. I thought I could just disable the output, and that with disable the output from the driver?

Not if you want to use the disable function. You could make the pins all inputs after you stop, then set them to outputs again when you need to move if you don't want to use the enable feature though.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.