void loop() {
digitalWrite(stepPin, HIGH);
delayMicroseconds(100);
digitalWrite(stepPin, LOW);
delayMicroseconds(100);
...
if (digitalRead(buttonPin) == HIGH) {
digitalWrite(stepPin, LOW);
}
You "disable" stepPin then immediately set it high again. Try
void loop() {
if (digitalRead(buttonPin) == HIGH) {
digitalWrite(stepPin, LOW);
} else {
digitalWrite(stepPin, HIGH);
delayMicroseconds(100);
digitalWrite(stepPin, LOW);
delayMicroseconds(100);
}
Note also the use of the code tags (the # button) to make the code easier to read.
Rob