Shop OBEX P1 Docs P2 Docs Learn Events
Control motor direction — Parallax Forums

Control motor direction

RandallRandall Posts: 5
edited 2006-03-22 14:31 in BASIC Stamp
I have a motor that reverses direction depending on which lead the positive voltage is applied to. Reversing the voltage has no affect, and this appears to be the only way motor controllers will control motor direction (H-bridge). This motor runs at 24V/9A which is also a bit of a challenge. I know I could hook up a separate relay for each direction, but solid-state relays that handle this load are expensive. Does anyone have any other ideas on how I can control the direction and speed of this funky motor? Thanks!!

Comments

  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-03-20 20:33
    Randall -

    Changing the leads (presuming there are only TWO) and reversing the voltage, should be the same thing, IF this is s DC motor. How do you differentiate those two methods?

    If necessary. please provide a diagram, or simple sketch.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • RandallRandall Posts: 5
    edited 2006-03-20 20:48
    The configuration of the motor is really strange. There's one negative that's attached to the motor housing, and then two leads that take the positive input. One's for CW, and the other for CCW. Switching which lead gets the positive changes the motor direction.



    Motorouts.jpg
  • PJAllenPJAllen Banned Posts: 5,065
    edited 2006-03-20 21:04
    · Typically, relays have a Normally Open (N.O.) contact, a Normally Closed (N.C.) contact, and a Common terminal.··When the·relay coil is energized the path is from N.O. to Common; when it's de-energized the path is from N.C. to Common.· Change directions by turning the relay on/off.
    · That'll be a big relay (9A!).
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-03-20 21:17
    Since you need speed control you'll most likely need to build a custom driver circuit.· This isn't a typical DC Motor so a typical H-Bridge circuit won't work.· In your situation there is the possibility of trying to drive the motor in both directions.· I wonder what that does to it?· Can't be good.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-03-20 21:34
    Randall -

    I have seen some 110V AC/DC motors that were wound that way. It's a bit of a pain to deal with. You can still change direction if you use a SPDT (single pole double throw) relay, but you will need another means to turn it ON/OFF and/or change the motor speed.

    /code

    CW·· ====


    ············· · ·· *=== Power + (common pole)
    ············· ·||/
    ············· ·||
    CCW ====

    code/

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • RandallRandall Posts: 5
    edited 2006-03-20 21:48
    Excellent feedback. Thanks guys!

    BTW, before I knew how this thing was wired I tried hooking it up in a way that ended up trying to run in both directions. The smoke didn't smell very good. freaked.gif
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-03-20 22:45
    Sounds like you need two transistors (at that current you should use mosfets), then use a inverter so that only one is turned on at any one time. If you want on/off control you'll need a tri-state buffer. Theres a problem with the fact that its the positive side thats switched, because PMOS transistors should be used and the control voltage should be 24V for off and less than 24V for on. You can do this a few ways, but a optoisolator would work. I can draw up an example diagram for you later if you want.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
  • RandallRandall Posts: 5
    edited 2006-03-20 23:13
    Paul Baker said...
    Sounds like you need two transistors (at that current you should use mosfets), then use a inverter so that only one is turned on at any one time. If you want on/off control you'll need a tri-state buffer. Theres a problem with the fact that its the positive side thats switched, because PMOS transistors should be used and the control voltage should be 24V for off and less than 24V for on. You can do this a few ways, but a optoisolator would work. I can draw up an example diagram for you later if you want.

    Thank you Paul! What you say makes sense. If you wouldn't mind a diagram would be very helpful. I'm pretty new to microprocessors, and any help is appreciated.
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-03-21 13:01
    Ok give me a day or so, I tried using expressPCB's software last night but couldn't find an optoisolator. I'll try will eagle tonight.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-03-22 03:52
    Ok heres the schematic, I went with an all transistor design. Q1-Q3 are N channel FETs and Q4-Q5 are P channel FETs. All of them need to be able to handle a Vdc of 24V or greater, and Q3-Q5 need to be able to handle the 9 Amps of current to drive the motor. DIR and ON are your controls, when DIR is low, the resistor attached to Q4's gate pulls the drain of Q1 up to 24V·turning off·Q4·and turning on·Q2. Q2 being on pulls it's drain down to ground, turning Q5 on and causing current to be able to flow through (+ 2). When DIR is high, Q1, Q2, Q4 and Q5 switch states causing current to be able to flow through (+ 1). ON when low prevents current from flowing through the motor, when On is high, the motor will turn in the direction dictated by the DIR control.

    I wrote the explanation as though you understand the principles of transistors. If you dont and want some more explanation, ask.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10

    Post Edited (Paul Baker) : 3/22/2006 3:57:42 AM GMT
    555 x 731 - 57K
  • RandallRandall Posts: 5
    edited 2006-03-22 13:20
    Paul, thank you so much! I really appreciate the work.
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-03-22 14:31
    No problem, I forgot to mention that all transistors should also be able to handle a Vgs of 24V (-24V for the PMOSs)·as well.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
Sign In or Register to comment.