AF_Motor +AccelStepper: How to go backwards?

Adafruit Ethernet, Motor, Proto, Wave, Datalogger, GPS Shields - etc!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
protonumerique
 
Posts: 10
Joined: Wed Dec 05, 2012 3:14 pm

Re: AF_Motor +AccelStepper: How to go backwards?

Post by protonumerique »

Well, it's the first time since I double-checked the soldering, before that I used both ports to test. Never got the M3/m4 to work in both directions though.yesterday I just tried with M1/M2.

Apart from that I just found one strange thing, most likely unrelated, but who knows: One leg of the pins that plug the shield with the Power zone of the arduino is like 1mm shorter than the rest. It's the ground pin next to 5v. Hadn't notice before.

User avatar
adafruit_support_bill
 
Posts: 88087
Joined: Sat Feb 07, 2009 10:11 am

Re: AF_Motor +AccelStepper: How to go backwards?

Post by adafruit_support_bill »

Running out of ideas here. Just to remove one more variable from the equation, have you tried running the AF_Motor Stepper Test?

protonumerique
 
Posts: 10
Joined: Wed Dec 05, 2012 3:14 pm

Re: AF_Motor +AccelStepper: How to go backwards?

Post by protonumerique »

I know. I'm clueless. Today the clues narrowed, but I don't know again for sure: The same example from yesterday, the same motor and no shield, just the ULN2003A. Tested my serial comm with processing all day long because I want to move to a different stage. Suddenly I noticed some hours ago, that this is also going FORWARD all the time. Even though it worked since Yesterday.

I almost collapsed! thought I had an alternative, and now this doesn't work either. This leaves me with 3 theories:

1. Can it be something with Voltage? I'm using a switching power supply with this specs: PRI: 100v-240v-60/50Hz 0.16A it can be set from 3v to 12v
2. Can the motors be damaged? I have just 2, so I just wonder if this is possible.
3. Or can the Arduino be doing something weird? I guess not, the other part of the project is going fine, and all seems to go normally. I have a very commented communication warning with processing (rxtx mismatch), but it doesn't affect data transfer...

This is my first project with motors, so I could have done something terribly wrong (Like powering the whole thing with the bare cables or whatever). The example you ask for is also not working: from all the commands, the motor will just move twice FORWARD, when it comes to DOUBLE steps. Tried changing speed and steps, but the motors will not respond.

User avatar
adafruit_support_bill
 
Posts: 88087
Joined: Sat Feb 07, 2009 10:11 am

Re: AF_Motor +AccelStepper: How to go backwards?

Post by adafruit_support_bill »

1. Can it be something with Voltage? I'm using a switching power supply with this specs: PRI: 100v-240v-60/50Hz 0.16A it can be set from 3v to 12v
Does it say anywhere what the output current rating is? With only 0.16A input, I suspect you may be underpowered.
Also, what is the current rating for the stepper motor (usually expressed in mA per phase). You will want a power supply that is capable of powering 2 phases simultaneously for each motor.

protonumerique
 
Posts: 10
Joined: Wed Dec 05, 2012 3:14 pm

Re: AF_Motor +AccelStepper: How to go backwards?

Post by protonumerique »

I needed to go on with the Project so I just got a different pair of motors. They work like they should. Just for the record:

This motor model (28BYJ-48 5-Volt Stepper) in particular was the reason for all that confusion. Perhaps you could take a look on how to handle them with the AF_Motor library... I found this THREAD in the Arduino Forum, which somehow shows people with similar problems making code just for it.

http://arduino.cc/forum/index.php?PHPSE ... ic=85335.0

But I decided to go the easy way...Thank you for the help anyway

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino Shields from Adafruit”