Parallax Forums
  HomeLog InRegisterCommunity CalendarSearch the ForumHelp
   
Parallax Forums > Public Forums > BASIC Stamp > Stepper motor help  Forum Quick Jump
 
New Topic Post Reply Printable Version
42 posts in this thread.
Viewing Page :
 1  2 
[ << Previous Thread | Next Thread >> ] | Show Newest Post First ]

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/25/2008 8:32 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Hello
 
I am currently trying to gain control of my Hurst AS unipolar (6 wire) stepper motor and I need some help.  The cheapest alternative that I have found to control the stepper is included below in the schematic below.  Each of the four coils are activated simultaneously with TIP31 NPN transistors, which are protected by 1N4003 micro 1 amp diodes.  The BS2px pins I believe protected by the 1 KoHm 1/4 watt resistors (will they protect the stamp pins?)  The stepper I want to control is a Hurst AS stepper motor (datasheet)  Here is a link to the website I am using for wiring.  Would the current wiring and parts work with this stepper? Do i need stronger transistors? Will i destroy the stamp?
 
Stepper motor is 12 VDC - 3W.  6 wire
 
Thanks
 
Technic-R-C

Post Edited (Technic-R-C) : 7/26/2008 7:09:38 AM GMT


Image Attachment :
Image Preview
cpu-npn.gif
  2KB (image/gif)
This image has been viewed 80 time(s).
Back to Top
 

PJ Allen
Counsel of Despair ???



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2005
Total Posts : 2910
 
   Posted 7/26/2008 4:22 AM (GMT -8)    Quote This PostAlert An Admin About This Post.

The diodes should be across the coils (windings).

(pic attached.)


Image Attachment :
Image Preview
trc_step.JPG
  10KB (image/pjpeg)
This image has been viewed 88 time(s).
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 8:37 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Thanks
So with the schematic that you provided your saying that I whould be able to run my 12 VDC 3 Watt motor from four BS2px pins with no problem whatsoever (no burnign pins)?  If this is the case, what do you mean by attaching the diodes across the coils?  Would one end of the diode be attached to the battery supply (positive or negative?? im assuming its positive) whilst the other is attached to the wire distinguishing one coil from another?  What would be the amperage of my stepper motor considering it is 12 volt and 3 watt.  Is there a way to calculate this?  If so will the TIP31 NPN transistor work with a max amperage of 3.0?
 
Technic-R-C
Back to Top
 

PJ Allen
Counsel of Despair ???



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2005
Total Posts : 2910
 
   Posted 7/26/2008 9:40 AM (GMT -8)    Quote This PostAlert An Admin About This Post.

P = E x I

therefore

I = P / E

I = 3W / 12V

I = 0.25A


Post Edit:

Check -- 12V x 0.25A = P

                  3W = P

T-R-C asked...
Would one end of the diode be attached to the battery supply (positive or negative?? im assuming its positive) whilst the other is attached to the wire distinguishing one coil from another?
The cathode would go to +V and the anode to the motor terminal/wire.  From what you're showing, it had better be positive.

Post Edited (PJ Allen) : 7/26/2008 5:50:48 PM GMT

Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 9:50 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
So the TIP31 NPN transistors should more than exceed the expectations when controlling the stepper motor.  So to finalize, will the circuit work withough damaging the stamp???  Are the types of diodes and resistors correct?
 
Technic-R-C

Post Edited (Technic-R-C) : 7/26/2008 5:56:14 PM GMT

Back to Top
 

PJ Allen
Counsel of Despair ???



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2005
Total Posts : 2910
 
   Posted 7/26/2008 10:08 AM (GMT -8)    Quote This PostAlert An Admin About This Post.

My suggestion, given your trepidation/s, is that you initially wire up some LEDs and resistors in place of the coils, by way of simulation.  12V source, "10mA" each ought to do... use a 1kΩ, each.  See how that works out.

Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 10:52 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Might sound kind of dumb, but wouldn't the LED burns out when I connect a 12V battery with 1.3A to the ciurcuit conatining LED's instead of coils.  (thats the only power supply I have)
 
Technic-R-C
Back to Top
 

PJ Allen
Counsel of Despair ???



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2005
Total Posts : 2910
 
   Posted 7/26/2008 10:55 AM (GMT -8)    Quote This PostAlert An Admin About This Post.

Crikey...

Use an LED and a resistor in place of each coil.  I specifically mentioned a 1kΩ.  So that's an LED and a 1kΩ in place of each coil.  Do you require a schematic?


Post Edit -- pic attached

Post Edited (PJ Allen) : 7/26/2008 7:06:21 PM GMT


Image Attachment :
Image Preview
sum_ppl.jpg
  62KB (image/pjpeg)
This image has been viewed 78 time(s).
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 12:25 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Thanks, that makes more sense.  So i'm going to try these circuits out tonight after I buy some parts and I'll get back to you with results.  By the way, I read somewhere that applying more voltage than the amount required will still run the stepper with better performance?  So would the stepper run with a lower voltage like a 9.6 volt supply - 2900 mili amperage?  I know that motors would run, but steppers??
 
Thanks for all the help by the way turn
Technic-R-C
Back to Top
 

PJ Allen
Counsel of Despair ???



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Sep 2005
Total Posts : 2910
 
   Posted 7/26/2008 1:06 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
 
T-R-C asked...
I read somewhere that applying more voltage than the amount required will still run the stepper with better performance?
 
I would have to disagree, more is NOT better.
You should run it with the specified voltage or within the specified range.
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 3:22 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
I was reading the Tech Specs about the TIP31 and I was wondering what this meant
 
V(CE): 1.2 V(BE): 1.8 I(C) Max  link
Does this mean If I use the 12 V battery power source for my stepper will it damage the transistor. (man 1.8 V????)  Or will the pin voltage off of my BS2px damage the transistor? (5V)
 
Technic-R-C
Back to Top
 

Mike Green
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Oct 2004
Total Posts : 14332
 
   Posted 7/26/2008 3:36 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Read the "official" datasheet (www.fairchildsemi.com/ds/TI/TIP31.pdf) rather than the "Tech Specs". In particular, look at the test conditions and the graphs.

Vce(sat) is the voltage measured between the collector and emitter when the transistor is saturated under certain conditions (which are stated). Similarly, Vbe(sat) is the voltage measured between the base and emitter when the transistor is saturated under the conditions stated.

For questions about potential for damage, look under "absolute maximum" ratings. There are also graphs that show "safe area" and power dissipation vs. case temperature.
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 3:40 PM (GMT -8)    Quote This PostAlert An Admin About This Post.

 

 

Symbol

Parameter

Test Condition

Min.

Max.

Units

VCEO(sus)

* Collector-Emitter Sustaining Voltage

: TIP31

: TIP31A

: TIP31B

: TIP31C

IC = 30mA, IB = 0

40

60

80

100

V

V

V

V

 
min 40 V, am I reading this correctly??  I am sure I dont need a 40V supply to run the transistor?
And it appears like there is no maximum
 
Technic-R-C
Back to Top
 

Mike Green
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Oct 2004
Total Posts : 14332
 
   Posted 7/26/2008 3:53 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Here's a link to a reference book with definitions like "collector-emitter sustaining voltage". This was found with a simple Google web search. You should try it before you make assumptions about what something means.
Back to Top
 

Sawmiller
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2005
Total Posts : 243
 
   Posted 7/26/2008 4:16 PM (GMT -8)    Quote This PostAlert An Admin About This Post.

quote

Each of the four coils are activated simultaneously with TIP31 NPN transistors, which are protected by 1N4003 micro 1 amp diodes.

end quote

you activate the coils sequentialy to move the stepper forward or back, in full or half step mode

in regards to stepper motor operation...
you can use up to 20 times the voltage that the stepper is rated for, to get better current response.
 
however never exceed the rated current for the stepper.
 
it sounds like you need to read up on stepper ops, before hooking it up, do like pj said and check the rest of your circut before hooking up the wires.
 
you can limit the current with resistors , or with chopper chips, but do limit it
there are many fine documents out there that explain how to do steppers.
 
if i wanted to control a low current stepper, i would probally use a ULN2803A Darlington Array  since i believe it already includes the diodes and the bemf protection diode ( check the docs to make sure )
 
and some current limiting resistors in line with the coils, if i was to go above the rated voltage.
dan
 

Post Edited (Sawmiller) : 7/27/2008 12:22:07 AM GMT

Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/26/2008 6:27 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Sawmiller said...

quote

Each of the four coils are activated simultaneously with TIP31 NPN transistors, which are protected by 1N4003 micro 1 amp diodes.

end quote

you activate the coils sequentialy to move the stepper forward or back, in full or half step mode

in regards to stepper motor operation...
you can use up to 20 times the voltage that the stepper is rated for, to get better current response.
 
however never exceed the rated current for the stepper.
 
it sounds like you need to read up on stepper ops, before hooking it up, do like pj said and check the rest of your circut before hooking up the wires.
 
you can limit the current with resistors , or with chopper chips, but do limit it
there are many fine documents out there that explain how to do steppers.
 
if i wanted to control a low current stepper, i would probally use a ULN2803A Darlington Array  since i believe it already includes the diodes and the bemf protection diode ( check the docs to make sure )
 
and some current limiting resistors in line with the coils, if i was to go above the rated voltage.
dan
 
Thanks, whew, I was just about to connect a 9.6 Volt 2900 miliamperage (2.9 amps) battery to a 0.25 amps rated stepper (compliments to PJ's knowledge of equations).  Thanks for the info sawmiller.
At the moment I have given  up my attempt to connect my stepper to my BS2px and started to do a little bit more research.  Well lo and behold the research was beneficial because I found a website insiting that my current circuit schematic was not good and not made for a stepper but for a relay.  So here it the link to this website.  Proper schematic attached below.
It seems that i need to also add a zener diode into my circuit to prevent motion breaking, drive breaking, etc.  So will this 1N4742A 1-Watt Zener Diode zener diode work?  It is rated at 1 watt while the stepper is rated at 3.  Will this cause problems?
Second, i believe in the document it states that i need 2 zener diodes for the entire circuit correct?  ( 1 for a pair of coils)  Is this right?
Finally, what is the C1 in the circuit? 
So many questions, sorry?
Thanks
Technic-R-C
 


Image Attachment :
Image Preview
stepper5.gif
  2KB (image/gif)
This image has been viewed 73 time(s).
Back to Top
 

Sawmiller
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2005
Total Posts : 243
 
   Posted 7/26/2008 9:23 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
first of all, just because the power supply says 2.9 amps , doesnt mean thats what you will draw. thats the max
use the eqation e = I *R where e is voltage. so you have to find out what resistance your coil has, then add enough resistance in the form of a current limiting resister to limit your current to .25A
like so
I = E/R , .25 = 9.6/( x +y ) where x is your coil resistance, and y is the additional resistance you have to add to keep the current to .25 A... plug in the coil resistance and solve for y

that drawing you have looks complicated
the purpose of the diodes accross the coil is that when you cut the current to the coil, the coil will generate a voltage/current of its own as the magnetic field colapses only in the reverse direction.
so you put the diode so it wont conduct normally, but will when the field collapses, short circuting the back emf
i'm not sure about the zeners, i've only used them to limit the voltage in paraell with them.
as i said before look arooound , google stepper basics, there are some articles here on that if i remember right, in the nuts and volts issues.
 
or look here at the stepper motor docs...
 
theres a diagram and code
 look at the datasheet for the chip if you want to use discete componets.
dan

Post Edited (Sawmiller) : 7/27/2008 6:34:57 AM GMT

Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/28/2008 9:41 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Hello once again,
 
I was reading some Nuts and Volts columns when I came upon some info about controlling steppers and other devices with a ULN2803A Darlington Array.  Well the schematiac of the Darlington array was exactly similar to my original schematic.  And I was wondering wether or not to buy the darlington instead of building my own.  Before I make my decision I have a couple of questions.
 
1.  In the datasheet it states that the input current is typically .93mA (max 1.35mA) per input.  So in theory, would I be able to control(25mA/.93mA= ~4 Darlingtons) 25 inputs (4 Darlington Arrays controlling 4 steppers) without exceeding the max source of the Stamp? (For my project I would only need 12 inputs from 3 darlington arrays to control 3 steppers)???
 
2.  Since I my stepper is rated at 0.25 amps - 250 mA (3 watt 12 V), will i be able to control the stepper when using half steps (250 mA + 250 mA = 500 (danger zone) - 2 coils turned on at once)? (500 mA max for darlington)
 
3.  What kind of transistors and diodes are used in the ULN2803A?
 
Thanks
 
Technic-R-C
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/29/2008 8:49 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
If anyone could help I need a quick response.

Technic-R-C
Back to Top
 

Sawmiller
Registered Member

Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2005
Total Posts : 243
 
   Posted 7/29/2008 9:07 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
see my reply above, look at the docs for the stepper motor that parallex sells
it's about the same as yours
dan
Back to Top
 

Mike Green
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Oct 2004
Total Posts : 14332
 
   Posted 7/29/2008 9:29 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Look at the datasheet for the ULN2803A. You'll see that the continuous current for a transistor (Darlington pair) is different when only one conducts at a time as opposed to all 8 being on together. In the latter case, only 150mA is allowed per transistor for a total of 1.2A. That's not what you're asking for.

The transistors and diodes in the ULN2803A are not made to look like some kind of numbered standard. They're all integrated on a single piece of silicon. It doesn't make sense to ask "what kind of transistors and diodes" they are. They're just what the datasheet says, Darlington pairs with diodes to absorb reverse EMF pulses from relays or motor coils with specifications as described in the datasheet.
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/29/2008 10:57 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Look at the datasheet for the ULN2803A. You'll see that the continuous current for a transistor (Darlington pair) is different when only one conducts at a time as opposed to all 8 being on together. In the latter case, only 150mA is allowed per transistor for a total of 1.2A. That's not what you're asking for.
I'm sorry I don't quite understand.  So your saying that if all 8 transistors are turned on at once only 150mA is allowed per transistor.  So if two transistors are turned on at once then they can each source 600 mA for the total of 1.2A?  Is 1.2 amp the max current for the whole Darlington array?  With the total of 1.2A does this mean that that is the limit current for my external stepper power supply?  I've looked at the datasheet and it has only made me more confused. 
The transistors and diodes in the ULN2803A are not made to look like some kind of numbered standard. They're all integrated on a single piece of silicon. It doesn't make sense to ask "what kind of transistors and diodes" they are. They're just what the datasheet says, Darlington pairs with diodes to absorb reverse EMF pulses from relays or motor coils with specifications as described in the datasheet.
That makes sense.
      Technic-R-C
Back to Top
 

Mike Green
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Oct 2004
Total Posts : 14332
 
   Posted 7/29/2008 11:13 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Look at the graphs on the datasheet. There are different datasheets depending on the manufacturer:
focus.ti.com/lit/ds/symlink/uln2803a.pdf
www.st.com/stonline/products/literature/ds/1536/uln2804a.pdf
Look at Figure 11 on the ST datasheet. It shows peak collector current vs duty cycle vs
# of transistors on at the same time. This mostly gives some idea of heat load.

The TI datasheet indicates that the absolute maximum total ground current on the chip is 2.5A. This will
be exceeded if more than 5 transistors are on and conducting the 500mA maximum current per transistor.

The issue in bringing this up is that the figures for maximum current for one transistor don't apply to the
whole chip which has limits of its own. You have to look at all the information on the datasheet. You can't
just pick and choose what's important to you. You asked about two transistors being on at once and what
total current is allowed. You figure it out based on the information in the datasheets. It's all there.
You need to figure out enough about heat to determine whether that's a limiting factor. The collector to emitter
voltage (Vce) and the current you want to switch will tell you how much heat will be produced which has to be
gotten rid of.
Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/29/2008 6:31 PM (GMT -8)    Quote This PostAlert An Admin About This Post.
Thanks Mike,
Due to the fact that I can't buy the Darlington Array in any local store I have bought 4 TIP31 transistors, 4 IN4003 silicon diodes, and 4 1k-Ohm 1/4 watt resistors to control my stepper.  The stepper I am using is rated at 3W, 12V, 0.25A (250mA) and I should be able to drive it with the schematic posted in my first post. Thanks to all for helping me comprehend this rather new topic.

However like usual I still have a couple of questions.  I would like to use my BS2px power source (9V, 300mA) to power my stepper (12V, 3W, 250mA) as well as the Stamp by using the Vin pin.  However I am know that the stamp will not be able to sink 300mA of current.  Is there any way to use my power outlet as a means of driving the stepper as well as the stamp?
 
Technic-R-C

Post Edited (Technic-R-C) : 7/30/2008 3:24:21 AM GMT

Back to Top
 

Technic-R-C
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Nov 2007
Total Posts : 102
 
   Posted 7/30/2008 7:58 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Any ideas?
Couldn't find any info on the web or prior posts.
 
Technic-R-C
Back to Top
 
[ << Previous Thread | Next Thread >> ]
New Topic Post Reply Printable Version
42 posts in this thread.
Viewing Page :
 1  2 
 
Forum Information
Currently it is Tuesday, February 09, 2010 3:17 AM (GMT -8)
There are a total of 415,988 posts in 57,637 threads.
In the last 3 days there were 78 new threads and 885 reply posts. View Active Threads
Who's Online
This forum has 18517 registered members. Please welcome our newest member, try388.
50 Guest(s), 7 Registered Member(s) are currently online.  Details
Graham Stabler, humanoido, Bob Lawrence (VE1RLL), computer guy, Rick Brooks, JohnandElspeth, mikestefoy