Turning 28BYJ-48 stepper motor

Where is your code (attempt) to go forward and backward? That way we can see where you might have gone wrong.

I have no experience with steppers but I think your attempt should look something like

void loop()
{
  int i;
  i = 0;
  while (i < NUMBER_OF_STEPS_PER_REV) {
    onestep();
    i++;
  }

  i=0;
  while (i < NUMBER_OF_STEPS_PER_REV) {
    backstep();
    i++;
  }
}

Your topic has been moved to a more suitable location on the forum. Installation and Troubleshooting is not for problems with (nor for advise on) your project :wink: See About the Installation & Troubleshooting category.

1 Like