585,759 active members*
4,107 visitors online*
Register for free
Login
IndustryArena Forum > MetalWorking Machines > Benchtop Machines > Making Stepper Motors Work Reliably
Page 1 of 2 12
Results 1 to 20 of 25
  1. #1
    Join Date
    Feb 2006
    Posts
    7063

    Making Stepper Motors Work Reliably

    The conventional wisdom (completley incorrect) is that lost steps are just part of life with stepper motors. Over the years, I've seen a couple bazillion posts dealing with stepper problems, and have come to the conclusion that the overwhelming majority of problems are due to:

    1) Too small a motor - An awful lot of people seem to start cheap and small, and only when that's proven inadequate do they break down and buy appropriately sized motors. If you're building a CNC machine, either do the calculations to determine the torque and power you really need, or be guided by what others have achieved success with. There is some excellent information on the Gecko site, in the FAQ section, on how to properly size power supplies for steppers.
    2) Poor/inadequate power supplies - This is REALLY common. Using a 12V or 24V power supply, where a 48-72V supply is really called for. Similarly, many people use PC power supplies, or other surplus supplies that simply don't have the current capacity required. There is some excellent information on the Gecko site, in the FAQ section, on how to properly size power supplies for steppers.
    3) Poor quality controllers - There are lots of cheap, crappy stepper controllers out there, many very limited in both voltage and current capacity. For all but very small machines, these are a waste of money. Spend the money for something good, like the Geckos, Kelings, and others. Steer well clear of unipolar controllers, and go for the more expensive PWM or "chopper" controllers, preferably with micro-stepping. They are more expensive, but in the long run wil be cheaper than buying the crappy ones first.
    4) Tuning in Mach3 - There are many factors that must be right here. First is DO THE WINDOWS OPTIMIZATION as spelled out by the document on the ArtSoft website. If you have "flaky", random problems, they are VERY likely to be caused by skipping this critical step. As an example, I just resurrected my stepper-driven mini-mill. Before doing the Windows optimization, it would randomly stall one or more axes unless I turned the max velocity down under IPM. Just knocking one of the motors, or putting a load on the table woudl cause a stall. After doing the optimization, it'll run perfectly reliably at over 200 IPM, and it'll drag me along with it if I try to stop the table. If you've got a bad, or underpowered, PC, think about either buying a better one (I just bought a 2.6GHz Dell system on E-Bay for $80 with free shipping), or spring for a SmoothStepper, which will even let you run with a laptop if you wish, as it provides *perfect* step timing at all speeds.

    Getting your ports and pins setup and timing right, not just to where it seems to be working, is critical. In particular, getting the step polarity correct, and the pulsewidths correct, is VERY important. Consult the controller manufacturer if necessary, but get this right!

    Make sure the Mach DriverTest indicates your timing is "Excellent" ALL the time. If you see any glitches, figure out what causing them and fix it. All it takes is a single badly-timed step pulse to stall a stepper at speed.

    Going for max possible rapid speed may be good for "bragging rights", but is of no practical value. Accleration is FAR more important, particularly if you'll be doing 3D work. Going for max rapid speed will force you to tune down acceleration, which will hurt overall performance, and cause you to often not be able to reach your programmed feedrate, except for very long moves.

    You MUST figure out where the limits are, for accleration and feedrate. The way I do this works well. Write a short G-code program to run more or less random combinations of axes over different paths. Mine does a sequence of end-to-end single-axis and diagonal moves on the X/Y axes, running them just barely short of the limits at both ends. This makes lost steps easy to detect, because it'll hit the stops on the next move. Put this code in a subroutine, and call that subroutine in the main program, setting a high loop count (hundreds of iterations at least). Set your zeros,
    and start the program. If any axis EVER stalls or loses steps, then something IS wrong somewhere, so find it and fix it. It's probably one of the items listed abovel. Let this program run for a couple of hours, then, when it's done, return to your zero position, and make sure it's still dead on. If it's not, then you've still got a problem. You should be able to run a program like this for hours with no loss of position on a properly-designed, properly-tuned machine. DO NOT write-off problems to "Ah, they're just steppers! They always lose steps!". This IS NOT TRUE.

    Running the above test for long periods has the added advantage of "wearing in" the machine. You can use it to get the ways smoothed out, and everything working smoothly and tightly. Just make sure you run all axes to all limits A LOT, and don't just concentrate on the center of motion. Re-adjust your gibs and re-lube evertything after running for several hours, and I think you'll find the way operate much more smoothly from end to end. It sure made a difference on mine. It's now nice and tight, with almost no detectable slop in the ways, yet it'll run stop-to-stop at 200 IPM for hours with no position loss.

    Regards,
    Ray L.

  2. #2
    Join Date
    May 2009
    Posts
    141
    Great Post! Thanks for sharing.

    Dale P.

  3. #3
    Join Date
    Mar 2004
    Posts
    1804
    This is excellent information not only for those new to this world, but a good refresher for some of the old timers around here!
    This needs to be put on sticky status or better yet given "Article" status.
    Art
    AKA Country Bubba (Older Than Dirt)

  4. #4
    Join Date
    Feb 2006
    Posts
    7063
    Quote Originally Posted by HimyKabibble View Post
    The conventional wisdom (completley incorrect) is that lost steps are just part of life with stepper motors. Over the years, I've seen a couple bazillion posts dealing with stepper problems, and have come to the conclusion that the overwhelming majority of problems are due to:

    1) Too small a motor - An awful lot of people seem to start cheap and small, and only when that's proven inadequate do they break down and buy appropriately sized motors. If you're building a CNC machine, either do the calculations to determine the torque and power you really need, or be guided by what others have achieved success with. There is some excellent information on the Gecko site, in the FAQ section, on how to properly size power supplies for steppers.
    2) Poor/inadequate power supplies - This is REALLY common. Using a 12V or 24V power supply, where a 48-72V supply is really called for. Similarly, many people use PC power supplies, or other surplus supplies that simply don't have the current capacity required. There is some excellent information on the Gecko site, in the FAQ section, on how to properly size power supplies for steppers.
    3) Poor quality controllers - There are lots of cheap, crappy stepper controllers out there, many very limited in both voltage and current capacity. For all but very small machines, these are a waste of money. Spend the money for something good, like the Geckos, Kelings, and others. Steer well clear of unipolar controllers, and go for the more expensive PWM or "chopper" controllers, preferably with micro-stepping. They are more expensive, but in the long run wil be cheaper than buying the crappy ones first.
    4) Tuning in Mach3 - There are many factors that must be right here. First is DO THE WINDOWS OPTIMIZATION as spelled out by the document on the ArtSoft website. If you have "flaky", random problems, they are VERY likely to be caused by skipping this critical step. As an example, I just resurrected my stepper-driven mini-mill. Before doing the Windows optimization, it would randomly stall one or more axes unless I turned the max velocity down under IPM. Just knocking one of the motors, or putting a load on the table woudl cause a stall. After doing the optimization, it'll run perfectly reliably at over 200 IPM, and it'll drag me along with it if I try to stop the table. If you've got a bad, or underpowered, PC, think about either buying a better one (I just bought a 2.6GHz Dell system on E-Bay for $80 with free shipping), or spring for a SmoothStepper, which will even let you run with a laptop if you wish, as it provides *perfect* step timing at all speeds.

    Getting your ports and pins setup and timing right, not just to where it seems to be working, is critical. In particular, getting the step polarity correct, and the pulsewidths correct, is VERY important. Consult the controller manufacturer if necessary, but get this right!

    Make sure the Mach DriverTest indicates your timing is "Excellent" ALL the time. If you see any glitches, figure out what causing them and fix it. All it takes is a single badly-timed step pulse to stall a stepper at speed.

    Going for max possible rapid speed may be good for "bragging rights", but is of no practical value. Accleration is FAR more important, particularly if you'll be doing 3D work. Going for max rapid speed will force you to tune down acceleration, which will hurt overall performance, and cause you to often not be able to reach your programmed feedrate, except for very long moves.

    You MUST figure out where the limits are, for accleration and feedrate. The way I do this works well. Write a short G-code program to run more or less random combinations of axes over different paths. Mine does a sequence of end-to-end single-axis and diagonal moves on the X/Y axes, running them just barely short of the limits at both ends. This makes lost steps easy to detect, because it'll hit the stops on the next move. Put this code in a subroutine, and call that subroutine in the main program, setting a high loop count (hundreds of iterations at least). Set your zeros,
    and start the program. If any axis EVER stalls or loses steps, then something IS wrong somewhere, so find it and fix it. It's probably one of the items listed abovel. Let this program run for a couple of hours, then, when it's done, return to your zero position, and make sure it's still dead on. If it's not, then you've still got a problem. You should be able to run a program like this for hours with no loss of position on a properly-designed, properly-tuned machine. DO NOT write-off problems to "Ah, they're just steppers! They always lose steps!". This IS NOT TRUE.

    Running the above test for long periods has the added advantage of "wearing in" the machine. You can use it to get the ways smoothed out, and everything working smoothly and tightly. Just make sure you run all axes to all limits A LOT, and don't just concentrate on the center of motion. Re-adjust your gibs and re-lube evertything after running for several hours, and I think you'll find the way operate much more smoothly from end to end. It sure made a difference on mine. It's now nice and tight, with almost no detectable slop in the ways, yet it'll run stop-to-stop at 200 IPM for hours with no position loss.

    Regards,
    Ray L.
    One more thing I've seen - I am reminded of it, because it just happened again this AM:

    Windows is just flaky. The machine running my mini-mill is a very basic PC, with a fresh install of WinXP-Pro, properly optimized for Mach3. Yesterday, my system ran my "torture test" for hours, with no lost steps, running at 150IPM. I also ran it for a while at 200IPM, again with no lost steps. This AM, I booted up, and could not run 50 IPM without stalling! If I continued to command a move after the stall, there was a VERY clearly audible "thunk" at very regular intervals. I've seen this before, and it's a Windows thing. I changed nothing, and simply rebooted the PC, and it's back to working perfectly at high speed. I encountered the same thing on my big mill, before I put a SmoothStepper on it.

    Regards,
    Ray L.

  5. #5
    Ray L,

    Good post. Let me add a little to it:

    1) "lost steps are just part of life with stepper motors" I agree, not true. Send a billion steps to well set-up system will result in exactly 1 billion steps taken; not one more, not one less.

    2) Don't do things backwards. Avoid the "I salvaged a 0.5A NEMA-34 motor from a defunct printer and I want to use it on a 4' by 8' router I'm building". Things probably won't end well. Design the machine first, then pick a motor to power it, not the other way around.

    3) Don't be too cheap. Cheap is good but too much of a good thing can be bad. Avoid the "Can I use some 15A three-axis drive kits I found on e-bay for $9.99 with Mach3 and my Bridgeport mill?" pitfall. There is no magic in the world; there is no pixie anywhere on earth selling high performance drives at an unbelievably low price.

    That is everyone's dream but it just doesn't happen. Reality is unbelievably cheap drives deliver unbelievably poor performance. Here's the reason why:

    The world's electronic market is a level playing field. Someone in China pays exactly the same for electronics components as everyone else. Resistors cost $0.003, commodity ICs are $0.08 and so on the world over. There is very little labor content in modern drives because they are assembled by automated machines. The perceived third-world country advantage of cheap labor is canceled by automation. The result is a drive built in China or the US will cost same to build.

    Drive performance depends on the drive's complexity. Anyone can churn out a L/R full-step unipolar drive, tag it with 15A and 100VDC specifications and sell it for $10 in kit form. Just a PCB and a bag full of parts. Sounds like it can't be beat.

    Like Ray said, if you want a happy life, avoid unipolar drives, avoid any drive that doesn't microstep accurately (Allegro and L297/298) and avoid any drive that doesn't have mid-band resonance compensation. Avoid all low voltage drives based on chipset solutions (Allegro and L297/298). They are fragile and blow easily. Designs based on them are primarily cookbook designs (IC manufacturer's datasheets) without anything to differentiate one drive from another.

    What determines a drive's price? Complexity. At the simplest end ($10), four power transistors driven from the parallel port will turn a motor. The poor motor's performance has little resemblance of what it could do if it were driven with a complex drive. A crappy drive gives crappy motor performance. Take a look at all the noisy and torque-robbing resonance suppression ball-bearing and damper designs on this group used to overcome inadequate drive shortcomings.

    A complex drive makes the motor shine. Complexity means a lot of extra components used in the design and they cost money. That makes the drive cost more and it's unavoidable. It does result in a motor that does more than you thought it could.

    Mariss

  6. #6
    Join Date
    May 2008
    Posts
    1185
    I might add that the China import stepper drivers with the model # KL-56 and the true model # H2MD have no midband adjustment and performed poorly with 400oz NEMA 34 low inductance steppers. The Gecko drives gave twice the speed and much smoother midband performance.

    The low cost Geckos G251 should be the starting point for just about anyone.

  7. #7
    Join Date
    Feb 2009
    Posts
    26
    amen guys. good post for the new kids on the block looking for some input on setup.
    Geckos rock. G203v's.

  8. #8
    Join Date
    May 2007
    Posts
    1026
    Ray,

    You forgot to mention that servo drives are better because they automatically correct for lost steps.

    (ducks and runs)

    The only real problem I see with your post is that the people who need to read it, won't.

    Mariss's point about designing from the center outwards is in the same vein. Many people go on eBay and start scrounging stuff that looks cheap, and then come on here and brag about their "score," and how they're going to build a CAT40 taper machine with enough travel to cut a 4x8 sheet of titanium for slightly less $ than a Tormach. Every so often a genuine expert shows a finished machine that resembles this, so the newbs start to think this is a successful way to go. I can say with certainty that 99% of the time I've spent on eBay relating to this hobby was a waste, and the other 1% didn't make up the difference.

  9. #9
    Join Date
    Feb 2006
    Posts
    7063
    Quote Originally Posted by sansbury View Post
    Ray,

    You forgot to mention that servo drives are better because they automatically correct for lost steps.

    (ducks and runs)

    The only real problem I see with your post is that the people who need to read it, won't.

    Mariss's point about designing from the center outwards is in the same vein. Many people go on eBay and start scrounging stuff that looks cheap, and then come on here and brag about their "score," and how they're going to build a CAT40 taper machine with enough travel to cut a 4x8 sheet of titanium for slightly less $ than a Tormach. Every so often a genuine expert shows a finished machine that resembles this, so the newbs start to think this is a successful way to go. I can say with certainty that 99% of the time I've spent on eBay relating to this hobby was a waste, and the other 1% didn't make up the difference.
    You mean those 100 oz-in unipolar motors I got for $5 each might not be strong enough for my knee mill? How about if I gear them down 10:1?? :-)

    Regards,
    Ray L.

  10. #10
    Join Date
    May 2007
    Posts
    1026
    Quote Originally Posted by HimyKabibble View Post
    You mean those 100 oz-in unipolar motors I got for $5 each might not be strong enough for my knee mill? How about if I gear them down 10:1?? :-)
    I find a 75:1 worm drive reducer will be even better. I run the motors at 900V using the power supply from an old vacuum tube amp with peltier coolers to keep them from overheating. I have rubber-soled shoes and a wooden broomstick to switch the power on just in case.

  11. #11
    Join Date
    Feb 2006
    Posts
    7063
    Quote Originally Posted by sansbury View Post
    I find a 75:1 worm drive reducer will be even better. I run the motors at 900V using the power supply from an old vacuum tube amp with peltier coolers to keep them from overheating. I have rubber-soled shoes and a wooden broomstick to switch the power on just in case.
    I'll bet I could rig up something suitable using the power supply from an old microwave.... :-)

    Regards,
    Ray L.

  12. #12
    Join Date
    Jun 2009
    Posts
    5
    Quote Originally Posted by Mariss Freimanis View Post
    Ray L,

    Drive performance depends on the drive's complexity. Anyone can churn out a L/R full-step unipolar drive, tag it with 15A and 100VDC specifications and sell it for $10 in kit form. Just a PCB and a bag full of parts. Sounds like it can't be beat.

    Like Ray said, if you want a happy life, avoid unipolar drives, avoid any drive that doesn't microstep accurately (Allegro and L297/298) and avoid any drive that doesn't have mid-band resonance compensation. Avoid all low voltage drives based on chipset solutions (Allegro and L297/298). They are fragile and blow easily. Designs based on them are primarily cookbook designs (IC manufacturer's datasheets) without anything to differentiate one drive from another.

    What determines a drive's price? Complexity. At the simplest end ($10), four power transistors driven from the parallel port will turn a motor. The poor motor's performance has little resemblance of what it could do if it were driven with a complex drive. A crappy drive gives crappy motor performance. Take a look at all the noisy and torque-robbing resonance suppression ball-bearing and damper designs on this group used to overcome inadequate drive shortcomings.


    Mariss

    What a bunch of marketing ____ ____
    Millions of machines run on steppers that don't have Gecko's in them and perform just fine. They run L/R drivers, unipolar driver, full step, half step, don't have mid-band compensation and never miss a beat. From cheap computer printers to Bridgeports the full gambit of complex motion machinery.

    This is a CNC forum, and you use it as a personal Gecko marketing media!

  13. #13
    Join Date
    Apr 2005
    Posts
    861
    Hey, he never said those cheaper drives wouldn't work - just maybe they won't be extracting the optimum from the motors connected. Rings pretty true with my experience.

  14. #14
    Join Date
    Feb 2006
    Posts
    7063
    Quote Originally Posted by wannabeee70 View Post

    What a bunch of marketing ____ ____
    Millions of machines run on steppers that don't have Gecko's in them and perform just fine. They run L/R drivers, unipolar driver, full step, half step, don't have mid-band compensation and never miss a beat. From cheap computer printers to Bridgeports the full gambit of complex motion machinery.

    This is a CNC forum, and you use it as a personal Gecko marketing media!
    That's more than a little over the top. He didn't say they wouldn't work, but he did say they would not get the best performance out of the motors, and that is an indisputable fact. A micro-stepping drive WILL outperform a non-microstepping drive. A higher voltage drive WILL out-perform a lower-voltage drive. Having mid-band resonance compensation WILL give smoother operation, and, in extreme cases, prevent stalling. PWM/chopper drivers ARE MUCH more efficient than simple L/R drivers. And the Allegro, and many other integrated drives, ARE more sensitive and FAR easier to blow up. I have several that did just that, all by themselves.

    If you want a very cheap, poor performing system, by all means buy the cheapest, simplest drives you can get your hands on. If you want your machine to perform the very best it can with whatever particular motors you have, spend the money for a decent drive, and Geckos are more than just decent. It WILL make a BIG difference. I started with A3977 drives (functionally identical to Xylotex), and "graduated" to Geckos, and the performance improvement was dramatic, to say the least.

    Regards,
    Ray L.

  15. #15
    wannabeee70,

    Good point. Let me address it:

    1) I don't mention any company. "What a bunch of marketing" isn't much of a bunch if a product or company isn't mentioned.

    2) I know a little about step motor drives. A person can't help but learn a few things if they keep at it for a while. I offered my best opinion on various drive types. It was based on my experience.

    3) I try to give back to the community. I pass on some things I have learned that others may find useful. The latest was the Verilog tutorial which shows anyone interested how to program a CPLD to become the core of a high performance microstep drive. Schematics, code, everything. "What a bunch of marketing" pushes a product and never gives away anything in return.

    4) Marketing is hype. I work hard to design the best possible drives. We work hard to support the drives I design by treating people like they are human beings instead of $$$ signs.

    5) Why would anyone want to be 70? I don't get it unless you are 80. It's hard enough being 60. I wanabeee28.:-)

    Mariss

  16. #16
    Join Date
    Mar 2007
    Posts
    122
    Quote Originally Posted by wannabeee70 View Post

    What a bunch of marketing ____ ____
    Millions of machines run on steppers that don't have Gecko's in them and perform just fine. They run L/R drivers, unipolar driver, full step, half step, don't have mid-band compensation and never miss a beat. From cheap computer printers to Bridgeports the full gambit of complex motion machinery.

    This is a CNC forum, and you use it as a personal Gecko marketing media!
    wannabeee70,

    I am only addressing a small portion of your message because of limited knowledge and experience on my part.

    I have only owned G-251's. NON of the other drives for steppers. They work great. Mariss is the type of guy who shares his knowledge with almost anyone willing to accept it. He did that for me and many others when he began designing and building the G-250/251/540 drivers. When I was deciding what stepper sizes to purchase, he and many others chimed in and guided me without telling me to buy his G-250/251/540 drivers. Only showing me how to figure out what size steppers I might use to fit my needs. What a bunch of marketing that is. I for one like that kind of marketing. He impressed me so much with his knowledge and willingness to help, I BOUGHT FROM HIM. He may not be the only seller who helps, but he met my needs and still does.

    Al

  17. #17
    Join Date
    Nov 2008
    Posts
    76
    Usually in marketing a company name is thrown in. I'm still trying to find this critical component in his post.

  18. #18
    Join Date
    Jun 2009
    Posts
    5
    "Marketing is an integrated communications-based process through which individuals and communities are informed or persuaded that existing and newly-identified needs and wants may be satisfied by the products and services of others." Mariss is Geckodrive, so any communications that persuade a consumer of what not to buy, essentially highlights his products. So his statement says not to buy Rockliff, HobbyCNC, Xylotex and Probotix.

    Just as put it Santa Fe Al "I for one like that kind of marketing." He see's it as marketing.

    Mariss is no dummy he understands that it is marketing, so the whole "no names" innocence is a bunch of __ __

    70 has nothing to do with age.

  19. #19
    OK, by your reasoning I must not offer any technical opinions or help people here on the CNCzone because I'm a "company" and anything I say is "marketing". My friend, I am not a company but a human being like you. I have a birth certificate, not papers of incorporation. Why dehumanize me that way?:-)

    OK, so I got the age thing wrong. Perhaps you are the 70th person in line at an apiary wanting to purchase an Apis Mellifera of your very own?

    Mariss

  20. #20
    Join Date
    Feb 2006
    Posts
    7063
    Quote Originally Posted by wannabeee70 View Post
    "Marketing is an integrated communications-based process through which individuals and communities are informed or persuaded that existing and newly-identified needs and wants may be satisfied by the products and services of others." Mariss is Geckodrive, so any communications that persuade a consumer of what not to buy, essentially highlights his products. So his statement says not to buy Rockliff, HobbyCNC, Xylotex and Probotix.

    Just as put it Santa Fe Al "I for one like that kind of marketing." He see's it as marketing.

    Mariss is no dummy he understands that it is marketing, so the whole "no names" innocence is a bunch of __ __

    70 has nothing to do with age.
    And another once useful thread goes right down the ol' crapper....

    Regards,
    Ray L.

Page 1 of 2 12

Similar Threads

  1. 1 Driver 2 Stepper Motors, is it possible will it work?
    By guy2b1 in forum DIY CNC Router Table Machines
    Replies: 31
    Last Post: 07-11-2012, 04:42 PM
  2. Replies: 2
    Last Post: 07-12-2009, 10:10 AM
  3. ATX (New) PS - Making it Work - HELP
    By Santa Fe Al in forum CNC Machine Related Electronics
    Replies: 5
    Last Post: 04-19-2009, 05:07 AM
  4. Purchasing Used Kiwa Colt 510 CNC and making it work
    By henry_phd in forum Community Club House
    Replies: 0
    Last Post: 06-15-2008, 05:01 AM
  5. Will These Work (Stepper Motors)
    By Hawkeye in forum DIY CNC Router Table Machines
    Replies: 9
    Last Post: 12-06-2003, 06:53 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •