Hi guys, I have an Arduino Uno and stepper motor. i want to be able to step the motor clockwise until it hits the limit switch then steps anticlockwise for specific steps. i had wrote a code that you can see below but it doesn't work. if you guys help me i would be Grateful.
These statements compare Stepping with false then true with a half second delay between the comparisons and throws away the answers. I don't think that is what you meant to do or if you did I don't see why.
Please read the first post in any forum entitled how to use this forum. http://forum.arduino.cc/index.php/topic,148850.0.html then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?
We need to see how you have connected the stepper and the switch, also how you are powering the arduino and the stepper.
Also a link to the specs on your stepper motor.
no i just want, after it reaches the limit switch stop and then after half second ,start in reverse direction for specific steps . how can i correct the code?