Shop OBEX P1 Docs P2 Docs Learn Events
electric motor control — Parallax Forums

electric motor control

NosaerNosaer Posts: 4
edited 2009-09-09 14:59 in General Discussion
I'm starting a new project and am looking for some advice/direction.

2 electric motors will be driven at different rates.
The motors need to be high torque and precise.
Data will be transmitted by a PC and received by the logic board.

What I have:
Basic Stamp Rev G
Board of Education

My Questions:
Is the Basic Stamp suitable for this project?
I assume I'll need to get another motor controller board. What would be recommended for more heavy duty motors?
Is the serial port on the Board of Education sufficient for streaming data to the Basic Stamp?
What other resources should I be reading?

A bit more about the project:
I have a telescope I'd like to be computer driven. One motor will be used for altitude control, the other for azimuth control. Coordinates of an astronomical object would be sent from the PC to the logic board to point the scope. The motors need to be strong enough to move the scope, but be precise enough to follow the object for a period of time.

Comments

  • SRLMSRLM Posts: 5,045
    edited 2009-08-20 22:02
    You'll want to use stepper motors (not regular DC motors), possibly with encoders. The BS2 would probably have trouble doing the coordinate to rotation calculations. You'll have to figure out an acceptable solution to overcome this. Some that occur to me are to a) buy/find a program to do all the main calculations, b) input the start direction yourself, or c) upgrade to a more capable controller (like the propeller). As for the serial port, it should be fine.
  • T ChapT Chap Posts: 4,245
    edited 2009-08-21 01:47
    When you say hi torque, you need to specify what RPMs you need as well. Steppers are higher torque at low RMPs, whereas DC or Brushless DC motors are higher torque at higher RPMs. You can get more torque from DC or Brushless DC motors with gearing(gearboxes as an option). You can move a stepper at high precision, also a brushless DC motor with an encoder can be operated with high precision as well.
  • T ChapT Chap Posts: 4,245
    edited 2009-08-21 16:24
    Just reread your post. I missed a few things on the first time. I suggest you get bipolar steppers and connect them with a coupler to some threaded rod (acme threads). You can get some Delrin antibacklash leadnuts here:

    dumpstercnc.com/

    Get some nema23 bipolar steppers, 3 to 4 amp ratings. These will have either .25" shaft or 8mm typically and you can match these at dumpster.

    Get acme threaded rod at mcmaster.com

    www.mcmaster.com/#acme-threaded-rods-and-studs/=3ab227


    You can get bipolar stepper driver at geckodrive here that will serve your purposes, just send the driver step and direction from the computer/processor. At the speeds you are needing, any processor will do the job, Stamp is fine. These drivers have Full-step, half-step, 5 and 10-Microstep. at 10 microsteps you will get much smoother motion and less vibration.

    www.geckodrive.com/product.aspx?c=3&i=14461


    You need bipolar steppers, usdgital has them but they are not shown on the site, many other places sell them too, just search bipolar stepper motor nema 23 4 amps is quite robust for your application I think.

    You need 24-36 volts approximately. You can build a cheap power supply with a 24v transformer to take 120ac to 24 ac, then connect a 6amp bridge rectifier and a large cap, 2200 uf or so, 100 volt rating. Add some small caps too to smooth out the lines. The output will be around 36-37 with the transformer and rectifier above.


    www.allelectronics.com/make-a-store/item/TX-245/24-V.C.T.-5-AMP-POWER-TRANSFORMER/-/1.html

    www.allelectronics.com/make-a-store/item/FWB-66/6A-600V-BRIDGE-RECTIFIER/-/1.html


    Mount the antibacklash nut to your mechanism, then push or pull it where you want. You could add a home limit switch on each axis so that on boot up it will locate a know position so you can be repeatable with your settings.
  • PhilldapillPhilldapill Posts: 1,283
    edited 2009-08-23 00:35
    If you want some NEMA23 stepper motors like TChapman suggested, I've got tons of them that are just sitting on the shelf in boxes. You can have as many as you'd like for $5 a piece.
  • HollyMinkowskiHollyMinkowski Posts: 1,398
    edited 2009-08-23 09:01
    Maybe you could use 2 cheap cordless drills to do this.
    The smaller low voltage ones should be sufficient in power.
    It would be really easy to attach them to threaded rods since
    you could just tighten them onto the rods just the same as
    you tighten the drills onto a drill bit.

    You would need to make 2 optical encoders and use them to
    give your controller chip the rotation data from the turning rods.

    Each drill would need an H-Bridge circuit...you could get an
    H-Bridge chip or simply make them from transistors, there
    are schematics on the web for making these.

    You would need to engineer some way to let the controller determine
    where the telescope is pointing after a power loss or when first starting up
    the system. Rotating both azimuth and elevation to a start position
    would work...and then from that start position your system could move
    precisely to any new position.

    Are you also going to have a motor to control focus? or is this to be
    always used for astronomical observation with focus always at infinity?

    This seems like a really cool project! smile.gif
    It could be altered a bit and used to point
    small dish antennas....would be great for
    moving a small dish for wifi hacking smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Some mornings I wake up cranky.....but usually I just let him sleep in -
  • NosaerNosaer Posts: 4
    edited 2009-08-31 05:47
    Thanks for all the input so far! I also believe the motor in a common power drill would be sufficient to move the scope. Motorizing the eye-piece focuser is not a high priority right now. I figured that once I have the other motors constructed I could adapt one for the focuser. Or, perhaps, I would just buy a commercial product down the road.

    For now, I am trying to do this project as cheaply as possible. I don't currently know much about electronics but I am interested in learning. Can you explain a bit more about the encoders for rotation data?
  • kwinnkwinn Posts: 8,697
    edited 2009-08-31 14:09
    The most common optical encoders have a transparent disk with opaque radial lines on it. An led is mounted on one side of the disk and two phototransistors on the other side in such a way that the radial lines block the light (usually ir) from the led as the disk turns. This results in pulses from the phototransistors as the disk rotates. The two transistors are slightly offset from each other so that transistor "A" comes on slightly before transistor "B" when the disk rotates in one direction, and "B" comes on before "A" when it rotates in the opposite direction.

    The encoders I work with have 1000 lines/revolution and are fairly expensive. There are less expensive encoders used for volume controls and tuning radios, but they are also less accurate. You could also make your own low resolution encoders by printing an encoder disk and mounting a led/phototransistor or photo-interrupter. Another alternative is to use the parts from an optical mouse.
  • NosaerNosaer Posts: 4
    edited 2009-09-08 06:08
    A simple design I have come across is essentially:

    PC ----> Basic Stamp ----> H-Bridge ----> Motor
    |
    | ----> H-Bridge ----> Motor



    Is this pretty much what devices like HB-25 Motor Controller or the Micro Dual Serial Motor Controller do for electronic motors?
  • HollyMinkowskiHollyMinkowski Posts: 1,398
    edited 2009-09-08 09:42
    If you were to open up the cordless drill you could probably
    do optical encoding by simply making a white dot somewhere in
    the gearing system just at the point where the motor first connects
    to it...then use an LED/Phototransistor to detect reflected light
    from the white dot.

    If you get your position data at the motor and not from the
    shaft connected to the drill chuck your data will be very precise
    since the motor turns many times to turn the chuck once....you
    would be getting useful data that corresponds to even minute
    movements of the chuck.

    This is how I am going to do it for my robot arm project.

    I'm going to try making h bridges using 2n3055 transistors since I have
    a bunch of these available to me....they can handle 5 amps and that
    is probably enough even for the big 18v drills I am going to use.

    Unless your telescope is huge you can use the smallest and cheapest
    cordless drills you can find.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Where am I? Where am I going? Why am I in a handbasket?"

    Post Edited (HollyMinkowski) : 9/8/2009 9:50:27 AM GMT
  • NosaerNosaer Posts: 4
    edited 2009-09-09 03:28
    Note, with my last post. The H-bridges would be connected to the Basic Stamp module, not the PC. The formatting was messed up.

    Anyways.

    That is a great idea for the optical encoders, I'll be interested to hear how it works out.

    The telescope diameter is 8". The tube and mirror weigh about 21kg. I think a 9v cordless drill could just do the job, but maybe a 12v would be better?
  • Beau SchwabeBeau Schwabe Posts: 6,572
    edited 2009-09-09 03:33
    Nosaer,

    This link may be of some help. This is what becomes of my servo electronics after the servo has stripped it's gears...

    http://forums.parallax.com/forums/default.aspx?m=62953&f=10&p=1#m63128

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • rjo_rjo_ Posts: 1,825
    edited 2009-09-09 14:59
    You can get geared steppers out of old business type writers... then change the gearing around to improve your resolution. I am partial to the Propeller because whatever you don't think of today... the Propeller can handle tomorrow[noparse]:)[/noparse]
Sign In or Register to comment.