What Power Supply
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
What Power Supply
SIAP but I am a complete thin skinned newb to the arduino world. I have the uno 3 and the motorshield from adafruit (love the site). I am attempting to power a stepper motor (Stepper motor - 200 steps/rev, 12V 350mA) and was wondering what the best way to power the motor is? I have tried going through the arduino (usb)(using the jumper with no response) and figured that I wasn't getting enough juice to the stepper. Help!! Thanks!
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
USB is not the best way to power these, but you should get some action from them. I suspect there may be a problem with the shield or the wiring. Are these the first motors you have attempted to run with the shield?I have tried going through the arduino (usb)(using the jumper with no response)
If you post photos, front & back of the board we'll take a look for any assembly issues.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
Thanks for the response. I have carefully reviewed my construction (soldering and placement of elements) of the adafruit motor shield. Everything is exact according to the instructions and photo's. I have wired the stepper motor to M1 & M2 - red-yellow (no ground) green- brown. With the jumper on - the green led is lit (on the motor shield). using a multi meter - I am showing 3 volts (M1- ground) and only 2 volts at (M2 - ground). M3 & M4 are showing only 1 volt. Is this normal? Please be kind,,,,I am as green as they come
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
Is that with a sketch running? The outputs on these terminals are pulsed (to step the motor) so your meter is actually reading the average. Those measurements sound reasonable for a 5v supply.using a multi meter - I am showing 3 volts (M1- ground) and only 2 volts at (M2 - ground).
These motors are designed for 12v operation. At 5v, they may or may not actually turn, but you should feel something when it tries to step. Does the motor hum or vibrate at all?
If so, I'd go ahead and remove the jumper and find a good DC power supply or battery pack in the 10-14v range. Double check the polarity before connecting to the external power terminals.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
Thank you for your help. As far as having a sketch running while I checked the voltage,no. As for a power supply, I considered purchasing https://www.adafruit.com/products/352 but was concerned about the 5 amp. With only one motor stepping, wouldn't it get too hot?
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
5A is how much the supply is capable of delivering. The actual current draw is determined by the load (in this case the motor). These motors draw about 350mA per phase.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
Okay, I have a 12 volt power supply - and using this sketch -
// Adafruit Motor shield library
// copyright Adafruit Industries LLC, 2009
// this code is public domain, enjoy!
#include <AFMotor.h>
// Connect a stepper motor with 48 steps per revolution (7.5 degree)
// to motor port #2 (M3 and M4)
AF_Stepper motor(48, 2);
void setup() {
Serial.begin(9600); // set up Serial library at 9600 bps
Serial.println("Stepper test!");
motor.setSpeed(10); // 10 rpm
}
void loop() {
Serial.println("Single coil steps");
motor.step(100, FORWARD, SINGLE);
motor.step(100, BACKWARD, SINGLE);
Serial.println("Double coil steps");
motor.step(100, FORWARD, DOUBLE);
motor.step(100, BACKWARD, DOUBLE);
Serial.println("Interleave coil steps");
motor.step(100, FORWARD, INTERLEAVE);
motor.step(100, BACKWARD, INTERLEAVE);
Serial.println("Micrsostep steps");
motor.step(100, FORWARD, MICROSTEP);
motor.step(100, BACKWARD, MICROSTEP);
}
When I verify the sketch, all is fine. When I upload the sketch, I get the avrdude stk_500 get sync error. I have checked Tools-Board- Uno (correct) and I have checked Tools-serial port-com5 (verified in device manager as Arduino Uno R3 (com5). I am pretty sure that I am missing something simple. Unfortunately, simple things escape this newb.
// Adafruit Motor shield library
// copyright Adafruit Industries LLC, 2009
// this code is public domain, enjoy!
#include <AFMotor.h>
// Connect a stepper motor with 48 steps per revolution (7.5 degree)
// to motor port #2 (M3 and M4)
AF_Stepper motor(48, 2);
void setup() {
Serial.begin(9600); // set up Serial library at 9600 bps
Serial.println("Stepper test!");
motor.setSpeed(10); // 10 rpm
}
void loop() {
Serial.println("Single coil steps");
motor.step(100, FORWARD, SINGLE);
motor.step(100, BACKWARD, SINGLE);
Serial.println("Double coil steps");
motor.step(100, FORWARD, DOUBLE);
motor.step(100, BACKWARD, DOUBLE);
Serial.println("Interleave coil steps");
motor.step(100, FORWARD, INTERLEAVE);
motor.step(100, BACKWARD, INTERLEAVE);
Serial.println("Micrsostep steps");
motor.step(100, FORWARD, MICROSTEP);
motor.step(100, BACKWARD, MICROSTEP);
}
When I verify the sketch, all is fine. When I upload the sketch, I get the avrdude stk_500 get sync error. I have checked Tools-Board- Uno (correct) and I have checked Tools-serial port-com5 (verified in device manager as Arduino Uno R3 (com5). I am pretty sure that I am missing something simple. Unfortunately, simple things escape this newb.
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
You have successfully uploaded to this board before, right? Board type and COM port are the usual suspects. You might try another USB cable.
Just to rule out a problem with the shield, try the upload with the shield removed. If all that fails, hold the shift key down when pressing the upload button and post the diagnostic output.
Just to rule out a problem with the shield, try the upload with the shield removed. If all that fails, hold the shift key down when pressing the upload button and post the diagnostic output.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
yes I have successfully uploaded to this board before using the basic blink command. As it is right now, not even the blink command will work. When I plug in the board (shield removed) - the green led lights up and the yellow led at pin 13 blinks off and on (2 second intervals). Loading the basic blink command I get the avrdude stk500_getsync error. When I load the basic blink while holding down the shift key I get usbdev_open error.
Note - the yellow led continues to blink at 2 second intervals at all times, like it is stuck in a loop.
Note - the yellow led continues to blink at 2 second intervals at all times, like it is stuck in a loop.
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
If blink was the last sketch successfully uploaded, it is likely still running.the yellow led continues to blink at 2 second intervals at all times
Sounds like some application is holding the COM port open and the IDE can't open it. Make sure nothing else is running. Cell-phone sync apps and bluetooth stacks are notorious for monopolizing COM ports for no good reason. Disable these if you have to. What OS are you using?When I load the basic blink while holding down the shift key I get usbdev_open error.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
xp 64 bit. Running as basic as I can get. Have paired running processes down to 20 in task manager (bare essentials), have tried re-booting. With arduino plugged in (usb), I press the reset button and the yellow led blinks 3 times (fast) - pauses - one more quick blink - then goes right back to the 2 second blink interval.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
also in device manager, the Arduino UNO R3 is recognized under ports as com3. The device driver is recognized as Arduino UNO R3 with a device instance id of - USB\VID_2341&PID_0043\ and another 20 digits.
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
Hold the shift key down when pressing the upload button and post the complete text of the diagnostic output.
-
- Posts: 19
- Joined: Thu Mar 22, 2012 1:28 am
Re: What Power Supply
Holding the shift key down during upload results in - avrdude: usbdev_open(): did not find any USB device "usb"
That's it. Call me stumped. The uno does the same thing on two different computers - with different usb cables.
BTW,,I really appreciate your help!
That's it. Call me stumped. The uno does the same thing on two different computers - with different usb cables.
BTW,,I really appreciate your help!
- adafruit_support_bill
- Posts: 88091
- Joined: Sat Feb 07, 2009 10:11 am
Re: What Power Supply
I've heard of similar problem once before. The problem mysteriously went away when the user tried it with an older version of the IDE. Try it with Arduino 0022. If that works, try re-installing 1.0.
Please be positive and constructive with your questions and comments.