Connect with us

!WARNING! Cheap stepper motor on eBay - cheap for reason.

Discussion in 'Sensors and Actuators' started by BitHead, Nov 15, 2013.

Scroll to continue with content
  1. BitHead

    BitHead

    34
    4
    Mar 2, 2012
    Just a friendly `save your time/money' heads up to my fellow inventors...
    Perhaps you've seen them - the ones advertised like...
    " 5V 4-phase 5-wire Stepper Motor Gear Motor 28BYJ-48", sometimes with a ULN2003 driver board.
    They claim the gear ratio is 1/64.
    It is not.
    ( It has a gear with teeth=prime number, 31! )

    If you just want to make something go round-n-round slowly - go ahead, get one.
    If you need to position something accurately - don't.
    The actual gear ratio is 1/63.68395062. With 64 steps per motor rev, the number of steps to make the output shaft go exactly one full revolution is 4075.77283968.
    Not a nice number, is it?

    That said, perhaps my time/effort won't be completely wasted if you help yourself to the Arduino code snippit I wrote for driving it.
    It's compact, drives in half-steps and has a psuedo ramp up/down speed thing in it - starts slowly, stops slowly.
    I thought it would help keep my positioner from losing steps - and it did - but it didn't solve my problem with, you know, the `I was lied to.' thing. :)
    Look for "Arduino stepper code for ULN2003" in the Microcontrollers and Programming forum.
    Good luck with your projects.
     
  2. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,361
    2,756
    Jan 21, 2010
    Interesting... I bought a few of these (for almost nothing) and found I had problems getting them to rotate some arbitrarily amount and then return to the original position. I eventually solved this by ramping up the step rate at the begining and then ramping it back down at the end.

    the information about the internal construction is welcome because i figured out the reduction ratio was strange but even after getting the stepper to rotate 100 times in one direction i was never able to come up with a nice integer number of steps per turn. This explains why :)
     
  3. Fish4Fun

    Fish4Fun So long, and Thanks for all the Fish!

    462
    105
    Aug 27, 2013
    Hrmmm, I have some of these (just for going round & round), but I also have a DIY CNC router and play with CNC a fair amount. The industry standard way of handling this is all done on the PC/Controller side, so I really don't see a problem if every feature in the drive chain is comprised of prime numbers.

    The three PC steps involved in CNC are 1) CAD, 2) CAM 3) Machine Controller. The CAD/CAM portion is optional, but generating g-code by hand is tiresome. Typical machine controllers like Mach3 have very simple settings for things like steps per inch or mm. If you had a stepper motor with 13 steps per revolution, a gear ratio of 1:17, a lead screw pitch of 11rpi, and your amplifier used 7 partial steps per step; then you would simply enter 17017 in the "steps per inch" setting and the machine controller handles the rest. I know it doesn't seem "precise", but neither are "half steps" nor for that matter "full steps". Even high-precision stepper motors have full step error of a few degrees, more commonly +/- 30 degrees or more. This means that absolute accuracy is limited to the absolute accuracy of the full step error of the stepper motor regardless of how many "half steps" the controller uses to get there. HOWEVER, a different, and arguably more important measure of accuracy is "repeatability", which means that once you "know" the exact number of steps from A to B, you can assert with 100% certainty that you will arrive @ B in the same number of steps.....

    In THEROY my little CNC router uses 24,000 steps per inch suggesting I have an absolute accuracy of 1/24,000 in! In reality, I rarely get better than +/- 0.001 absolute accuracy. While this really bothered me at first, when you start multiplying all of the associate errors out, you find that +/- 0.001in is actually REALLY GOOD! With proper care and attention to detail you can achieve a small format CNC router with +/-0.001in capability for <$2k (well, that depends A LOT on where you start and stop counting, lol), but to take the absolute accuracy down the next order of magnitude can easily raise the cost of the machine more than an order of magnitude!

    Any way, I am NOT suggesting these little motors are high quality, high precision, nor that they are suitable for anything more than a toy stage, but they are fabulous for odd things that need to be done on a tight budget! (I got 10 of them with drivers for less than $20 delivered!).

    **Thank you for the info on the gear reduction** if I ever decide to use one for a stage, that is very good to know!

    Fish
     
  4. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,361
    2,756
    Jan 21, 2010
    Totally agreed Fish4Fun.

    I was trying to get the steps per turn so I could move a pointer to an absolute location. Eventually I got something that was close, but it did not satisfy me very much.

    This thread explains why, which makes me a lot happier!

    Bithead, perhaps you can post your code. The speedup/slow down is very important with these motors if you want any sort of accuracy and repeatability in my experience.

    Also, do you know if the motor has a friction clutch in it, or does excessive load just stall the stepper?
     
  5. BitHead

    BitHead

    34
    4
    Mar 2, 2012
    Possible redeeming discovery! A nice metric outcome.

    I was planning on using this motor to directly drive a lead screw - which is why it was important to be able to step it exactly one turn - so I could use the thread pitch in my position math.
    Well... it seems that my 1/4"-20 tpi screw on this motor shaft was able to move it's drive-nut almost exactly 1mm - so close to 1mm that the average of 10 attempts to measure it with my digital calipers was 1.003 - by stepping the motor with a nice number of 1/2 steps.

    Synopsis: 3200 steps (using that 1/2 step Arduino code routine I posted in the Programming forum) will move the nut on a 20tpi screw 1.0mm.

    Steve - no friction clutch. When I drove my nut too far back it just stalled out the motor.

    Here's that stepper code - https://www.electronicspoint.com/arduino-stepper-code-uln2003-t265252.html
     
    Last edited: Nov 21, 2013
  6. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,361
    2,756
    Jan 21, 2010
    Thanks BitHead, useful to me and hopefully many others out there.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-