Stepper Motor wont turn in reverse

i am trying to make my stepper motor turn back to its start position when i hit a button. From what i have researched using the .step() command with a negative value should reverse it but it doesn’t. What am i doing wrong?

My code is a bit of a mess right now but here it is!

I put a comment on the line that should reverse it.

#include <Stepper.h>

#define STEPS 2048

Stepper stepper(STEPS, 10, 11, 12, 13);


int A = 2;
int B = 3;
int C = 4;
int D = 5;
int E = 6;
int F = 7;
int G = 8;
int H = 9; //pins for the 7 segment display

const int Plus = A4;
const int Minus = A3;
const int Clear = A2;
const int Enter = A1;

int buttonPushCounter = 0;
int PlusState = 0;
int lastPlusState = 0; 
int MinusState = 0;
int lastMinusState = 0;
int ClearState = 0;
int lastClearState = 0;
int EnterState = 0;
int lastEnterState = 0;
int ServoVal = 0;
int ServoRotation = 0;

int NumZero(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, HIGH);
  digitalWrite(D, HIGH);
  digitalWrite(E, LOW);
  digitalWrite(F, HIGH);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

int NumOne(){
    digitalWrite(A, LOW);
    digitalWrite(B, HIGH);
    digitalWrite(C, LOW);
    digitalWrite(D, LOW);
    digitalWrite(E, LOW);
    digitalWrite(F, LOW);
    digitalWrite(G, LOW);
    digitalWrite(H, HIGH);
  }

int NumTwo(){
  digitalWrite(A, LOW);
  digitalWrite(B, LOW);
  digitalWrite(C, HIGH);
  digitalWrite(D, HIGH);
  digitalWrite(E, HIGH);
  digitalWrite(F, LOW);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

int NumThree(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, HIGH);
  digitalWrite(D, LOW);
  digitalWrite(E, HIGH);
  digitalWrite(F, LOW);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

int NumFour(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, LOW);
  digitalWrite(D, LOW);
  digitalWrite(E, HIGH);
  digitalWrite(F, HIGH);
  digitalWrite(G, LOW);
  digitalWrite(H, HIGH);
}

int NumFive(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, HIGH);
  digitalWrite(D, LOW);
  digitalWrite(E, HIGH);
  digitalWrite(F, HIGH);
  digitalWrite(G, HIGH);
  digitalWrite(H, LOW);
}

int NumSix(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, HIGH);
  digitalWrite(D, HIGH);
  digitalWrite(E, HIGH);
  digitalWrite(F, HIGH);
  digitalWrite(G, LOW);
  digitalWrite(H, LOW);
}

int NumSeven(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, LOW);
  digitalWrite(D, LOW);
  digitalWrite(E, LOW);
  digitalWrite(F, LOW);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

int NumEight(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, HIGH);
  digitalWrite(D, HIGH);
  digitalWrite(E, HIGH);
  digitalWrite(F, HIGH);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

int NumNine(){
  digitalWrite(A, LOW);
  digitalWrite(B, HIGH);
  digitalWrite(C, LOW);
  digitalWrite(D, LOW);
  digitalWrite(E, HIGH);
  digitalWrite(F, HIGH);
  digitalWrite(G, HIGH);
  digitalWrite(H, HIGH);
}

void setup(){

  pinMode(A, OUTPUT);
  pinMode(B, OUTPUT);
  pinMode(C, OUTPUT);
  pinMode(D, OUTPUT);
  pinMode(E, OUTPUT);
  pinMode(F, OUTPUT);
  pinMode(G, OUTPUT);
  pinMode(H, OUTPUT);

  pinMode(Plus, INPUT_PULLUP);
  pinMode(Minus, INPUT_PULLUP);
  pinMode(Clear, INPUT_PULLUP);
  pinMode(Enter, INPUT_PULLUP);

  NumZero();

  stepper.setSpeed(10);

  Serial.begin(9600);
  
}

void loop(){

  PlusState = digitalRead(Plus);

  MinusState = digitalRead(Minus);

  ClearState = digitalRead(Clear);

  EnterState = digitalRead(Enter);

  buttonPushCounter = constrain(buttonPushCounter, 0, 9);

  ServoVal = buttonPushCounter;
 

  if (PlusState != lastPlusState){

    if (PlusState == LOW){
      buttonPushCounter++;
    }
    delay(100);
  }
  lastPlusState = PlusState;

  if (MinusState != lastMinusState){
    if (MinusState == LOW){
      buttonPushCounter--;
    }
    delay(100);

      lastMinusState = MinusState;
  }
  

   if (ClearState != lastClearState){
    if (ClearState == LOW){

      stepper.step(-ServoRotation); //rotate stepper back to start position 

      delay(1000);
      
     buttonPushCounter = 0;
    }
    delay(100);
    
     lastClearState = ClearState;

   }

 
  if (buttonPushCounter == 0){
    NumZero();
  }
  
  else if (buttonPushCounter == 1){
    NumOne();
  }
  else if (buttonPushCounter == 2){
    NumTwo();
  }
  else if (buttonPushCounter == 3){
    NumThree();
  }
  else if (buttonPushCounter == 4){
    NumFour();
  }
  else if (buttonPushCounter == 5){
    NumFive();
  }
  else if (buttonPushCounter == 6){
    NumSix();
  }
  else if (buttonPushCounter == 7){
    NumSeven();
  }
  else if (buttonPushCounter == 8){
    NumEight();
  }
  else if (buttonPushCounter == 9){
    NumNine();
  }
  
  ServoRotation = map(ServoVal, 0, 9, 0, 2048);
  
  if (EnterState == LOW){

       stepper.step(-ServoRotation);

      delay(1000);
  }
  


  else if (EnterState == HIGH){
    stepper.step(0);
  }



   Serial.println(ServoRotation);

}

Thanks!

Have you tried a very simple code where you say in the setup()

Set speed at 10 rpm
Execute 1024 steps (so should be half a turn - which should take 3 seconds at rpm=10)
then wait 5 seconds for the servo To get there and sit there
and then step -1024 to get back to start point
Keep the loop() empty
—> to see what happens?