Whats wrong with my stepper code?

Wheter I push the button on pin 12 or 13, the stepper always goes clockwise. Even when I have nothing on pin 12 and push a button connected to 13 and gnd it will still go clockwise in stead of counter clockwise. I am somewhat a beginner to Arduino. Can someone please check if it's my code or something else? Thanks in advance.

Code on pastebin

Touch here for the full post on the Arduino Apprentices tumblr

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s