Shop OBEX P1 Docs P2 Docs Learn Events
I Need to control 2 ea. 24v 50 amp DC reversible motors. Has anyone done this? — Parallax Forums

I Need to control 2 ea. 24v 50 amp DC reversible motors. Has anyone done this?

bildobobbildobob Posts: 2
edited 2009-12-08 20:13 in General Discussion
OK, I'm using a BS2 and using a sabertooth (Dimension Engineering) servo mode drive power unit for differential control of 2 brush type 24 v dc motors.· I've got code to control 2 servomotors with a joystick, but need to "mix" it.· Any suggestions?

Post Edited (bildobob) : 12/8/2009 11:21:41 AM GMT

Comments

  • Peter KG6LSEPeter KG6LSE Posts: 1,383
    edited 2009-12-07 01:01
    relays are simple and are cheap but are not super fast at switching


    A H-Bridge is Ideal but is not super easy to make ..
    Attached is a simple relay controller with MOSFET Motor control..

    If You PWM the Drive FET you can vary the speed of the motor ...

    What is the Motor runnning ??


    Peter KG6LSE

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Carpe Ducktum" "seize the tape!!"
    peterthethinker.com/tesla/Venom/Venom.html
    Never underestimate the bandwidth of a station wagon full of tapes hurtling down the highway. —Tanenbaum, Andrew S.
    LOL
    467 x 477 - 58K
  • Mike GreenMike Green Posts: 23,101
    edited 2009-12-07 01:28
    In the future, please remember that this forum is called "Completed Projects". Use "The Sandbox" forum for questions like this.

    "Completed Projects" is limited to descriptions of just that and any new threads should include a complete description of the project and any schematics and program sources as attachments to the description. The intention is for people to have enough information to be able to duplicate the project or a modification of it.
  • bennettdanbennettdan Posts: 614
    edited 2009-12-07 01:47
    bildobob,

    ·· When you say control it do you mean speed or direction also are you using a microcontroller like a basic stamp? How do you you plan to use themotors for may help out.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2009-12-07 18:36
    This thread is being moved to the Sandbox Forum as it is off-topic in the Completed Projects Forum. Before posting in the Completed Projects Forum members are encouraged to read the sticky thread, "please read before posting projects".

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage

    Parallax Engineering
    50 72 6F 6A 65 63 74 20 53 69 74 65
    ·
  • ercoerco Posts: 20,260
    edited 2009-12-07 21:59
    For manual control, here's a $30·24V 30A scooter controller with reverse. Not 50A though...

    http://www.tncscooters.com/YK48-2.php

    more at http://tncscooters.com/partsdb.php?type=ES

    I built an electric bike with one of their 36V, 250W gearmotors. Those are nice units with internal gearing already.




    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."

    Post Edited (erco) : 12/7/2009 10:04:26 PM GMT
  • W9GFOW9GFO Posts: 4,010
    edited 2009-12-08 03:22
    Here is one that I have been considering, at least one person on this forum has one and I am eager to find out what they think of it.

    Sabertooth dual 25A regenerative motor driver.

    attachment.php?attachmentid=63712

    Rich H

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    The Simple Servo Tester, a kit from Gadget Gangster.
  • bildobobbildobob Posts: 2
    edited 2009-12-08 10:39
    Thanks W9GF0, I've just got the sabertooth 2 x 25 and figure that if necessary I could parallel 2 together and am writing the code to control 2 servos and have gotten it to the point where the joystick is controlling 2 servo channels, but need to mix the y (fwd/rev) and the x (lt/rt) together for steering control.· I'm a real virgin at this code business and have·modified one of the examples out of the "What's a microcontroller" book and am at a loss of how to mix 2 servo signals.· Here's the code, does anyone have the trick for modifying?

    ' {$STAMP BS2}
    ' {$PBASIC 2.5}


    'ControlServoWithJoystick.bs2
    'Use Analog Joystick To Control 2 Servomotors for differential steering
    'Scale time by factor and offset by 500 for the servos
    'Servos to stay between 500 to 1000
    '*/ operator offset = Y18/X19, need caps for 100K pots
    '12/7/2009

    'DEBUG "Program Running"

    timeY·· VAR··· Word·············· 'This is the Y channel FWD/REV
    timeX·· VAR··· Word·············· 'This is the X channel LT/RT

    DO
    · HIGH 7······························ 'This is for the Y channel
    · HIGH 8·······························'This is for the X channel
    · PAUSE 10
    · RCTIME 7, 1, timeY············· 'This is the Y channel FWD/REV
    · RCTIME 8, 1, timeX············· 'This is the X channel LT/RT
    · timeY = timeY */ 18············ 'Gain/Scale by .0703 (X 256 for */).
    · timeY = timeY + 500············ 'Offset by 500.
    · timeX = timeX */ 19············ 'Gain/Scale by .0742 (X 256 for */).
    · timeX = timeX + 500············ 'Offset by 500.
    · PULSOUT 14, timeY·············· 'send pulse to Y servo.
    · PULSOUT 15, timeX·············· 'send pulse to X servo.
    · DEBUG HOME,······················ 'Display on computer screen servotimer values
    · " FWD/REV ", DEC5 timeY, CR,··· 'Servotimer Y
    · " LEFT/RIGHT ", DEC5 timeX····· 'Servotimer X

    LOOP
  • W9GFOW9GFO Posts: 4,010
    edited 2009-12-08 20:13
    I would start with somethng like this;
    PULSOUT 14, timeX + (timeY - 750)
    PULSOUT 15, timeX - (timeY - 750)
    
    


    You'll need to limit the MIN/MAX values going to the PULSOUT with some more code but it ought to be pretty easy to do that.

    Rich H

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    The Simple Servo Tester, a kit from Gadget Gangster.
Sign In or Register to comment.