// Stepper motor on Wokwi!

#include <Stepper.h>
// initialize the stepper library on pins 8 through 11:
//                     BN  BP  AP  AN
Stepper myStepper(200, 26, 27, 14, 12);
int button_state;

void setup() {
  // initialize the serial port:
  Serial.begin(9600);
  pinMode(2 , INPUT_PULLUP);
}

void loop() {
  // Rodar 180 graus no sentido anti-horário a 10rpm
  button_state = digitalRead(2);
  if(button_state == 0){
    myStepper.step(1);
    delay(100);
  }
}