I am using Creality 42-40 STEPPER MOTOR for CR Series/Ender Series, which has a Step angle of 1.8 degrees. From this, I could calculate that it would make 1 revolution in 360/1.8 = 200 steps. However, when I tried to drive motor 200 steps, it could only do 1/4 revolution. I am not using any mircostepping with the driver. No load is attached to the motor. Other Details are:
Driver: TMC2208
Driver Power Supply = 12 V
Logic Power Supply = 5V
Here is my Circuit Diagram:
Here is the code:
/* Arduino sketch to drive a stepper motor using the AccelStepper library.
Runs stepper back and forth between limits. */
#include <AccelStepper.h>
const int dirPin = 3;
const int stepPin = 4;
AccelStepper myStepper(AccelStepper::DRIVER, stepPin, dirPin);
myStepper.setMaxSpeed(500.0);
myStepper.setAcceleration(100.0);
myStepper.moveTo(200);
}
void loop() {
if (!myStepper.run()) {
myStepper.moveTo(0);
}
}
Motor:https://www.azurefilm.com/en/creality-42-40-stepper-motor-for-cr-series/ender-series?pdf=1