Shop OBEX P1 Docs P2 Docs Learn Events
Interfacing a STAMP with an Electronic Speed Controller — Parallax Forums

Interfacing a STAMP with an Electronic Speed Controller

gncguygncguy Posts: 35
edited 2008-10-23 16:34 in BASIC Stamp
My wife gave me a Traxxas 1/8 scale R/C car.· It has plently of room and so my first thought was to use it for a chassis for my Boe-Bot boards.· I would assume that that ESC works like a servo in terms of controlling with pulses via the pulse out command.· Does anyone have any knowledge of how to do this.· For instance how does the width of the pulse affect the motor speed.
Also does anyone know where you can get or how to design a board that would allow the reciever input to override the STAMP output.· That way if my program in the STAMP goes bezerk, I can overide with R/C control
thanks,
gncguy

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2008-10-23 14:18
    On the ESC you may have to experiment to see which PULSOUT values yield which results on you car. As for the over-ride concept, I used to use lack of signal from the receiver as an indicator that the transmitter was on and my program would then pass control to the R/C system. When I got a newer radio though, it didn’t work like that, instead putting out preset values when out of radio range. So what I did was used an extra channel (landing gear on this one) to tell the target whether I wanted to take over or not. I used this while testing an autonomous robot once. When it didn’t do as expected and was about to crash into my motorcycle, I flipped the switch, took over and steered it away.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Engineering
  • Jesse HastyJesse Hasty Posts: 29
    edited 2008-10-23 16:18
    The ESC works just like a regular servo, or it should. the pulse width should vary between about 410 micro seconds for 0 volts to about 1150 micro seconds for full voltage. If you send full voltage width pulses and control speed by sending the pulses closer together or further apart you will overcome static friction at low speeds more effectively. I would test on a bench with the wheels off the ground to prevent mishaps. Typically, if you stop the train of pulses to the ESC it will drop to zero volts, but Traxxas may have a proprietary system. I doubt they do.

    If you find the pulse control jerky you can shorten the pulses a bit at slow speeds. 8 MS between pulses should be full speed, while 200 MS between pulses should be almost zero speed. That ratio you would need to play around with.
  • Beau SchwabeBeau Schwabe Posts: 6,563
    edited 2008-10-23 16:24
    gncguy,

    Getting the wheels up off of the ground on the test bench is not a bad idea... if possible clamp the chassis down to something so inertia doesn't move the car around much during testing.· You should also consider that some ESC's are capable of reverse and some are not. If it does provide reverse control, then chances are that the Forward response does not equally reflect the Reverse response because typically you don't need or want that much speed in reverse.

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

    IC Layout Engineer
    Parallax, Inc.
  • Jesse HastyJesse Hasty Posts: 29
    edited 2008-10-23 16:33
    I believe that Traxxas used a servo to physically shift a gear into reverse on the transmission. I may be wrong on this.
  • gncguygncguy Posts: 35
    edited 2008-10-23 16:34
    Wow!· Great Stuff. I was just lighting a candle in the dark.· I didn't expect to get such concrete advise.· Thanks.
Sign In or Register to comment.