Shop OBEX P1 Docs P2 Docs Learn Events
BS1 with precise motor movement — Parallax Forums

BS1 with precise motor movement

electrichauntelectrichaunt Posts: 3
edited 2009-03-15 04:35 in BASIC Stamp
Hello... I have a set of "scary eyes" that I want to·"pace" back and forth along a track. The track length is about 15 feet. When a sensor is triggered. I want the "eyes" to stop their "pacing", and to quickly zip over to a particular point on the track. (by either speeding forward or backing up)

I have been told that the Parallax "HB25 motor control" is what I need, but I didn't want to buy until I knew it was going to do the job.

I can figure out the programming part, but I need help with the mechanics... more specifically:

1. How to integrate this motor with a track(what gears and such)???
2. Should the track be just a continuous loop of string???
3. The "pacing" should be "move in one direction... stop... move in the other direction...stop...etc.
4. I don't the "eyes" to fall off one end of the track... or to "whip around" the end of the track and come back that way

I'll think of other questions later. Thanks. Bob

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-03-14 17:29
    The HB Motor Controller is just that ... a motor controller. There's no motor included. It's also much more powerful than you probably need. Something like the Pololu-made Micro Dual Serial Motor Controller is smaller and cheaper. Either would be used with an ordinary DC motor like you'd find in toys.

    The typical way you'd do this would be to have a nylon cord loop with pulleys at the ends of the track. The cord would fasten to the "eyes" at either side and the "eyes" would ride on the track on small nylon wheels. Maybe you'd use U-shaped channels for the wheels to run in. The nylon cord would need a spring to maintain tension in the cord and you'd need a pulley on the motor shaft with maybe 3 to 5 turns of the cord wrapped around it.

    The nylon cord would slip over time and the microcontroller would lose track of the actual position of the "eyes" trolley, so you'd need some kind of position sensor at the ends of the track. Something as simple as a microswitch pushed back by the trolley wheels as they go by would do. You could also use an optical sensor with an LED on one side of the track and a photodetector on the other side. with the trolley interrupting the light beam.
  • electrichauntelectrichaunt Posts: 3
    edited 2009-03-15 04:18
    Hey there, thanks for the help... I guess I don't know enough about the motor controller to know exactly what it does. I assume it can attach to the EFX-TEK prop1 controller with 3-pin servo connection?

    So an ordinary DC motor would be able to revolve in both directions?? (I didn't know that) I've got a couple of those little motors from Radio Shack and one of those "kid's pottery wheel" things (in which the motor is housed with a gear assembly to keep the RPM manageable) and thats another question... how to keep the RPMs low enough? Is that what the motor controller does?

    Would the pulley on the motor shaft be one of the pulleys at the end of the track?
    With so many windings, does the pulley "trench" have to be extra wide, so the cord wouldnt get tangled up?
    Sorry, I've never done a project that relied so heavily on object movement.

    So with break-beam sensors and snap-action switches, am I to assume that the only function of the motor would be "run in this direction until something triggers" ... now ... run in that direction until something triggers" ??

    Thanks again. Bob
  • Mike GreenMike Green Posts: 23,101
    edited 2009-03-15 04:35
    The motor controller controls the speed and direction of the motor. Read the documentation on Parallax's webstore page for it.

    I imagine the motor being mounted on the underside of the track where the "return" portion of the cord goes. The bobbin on the motor shaft would have a smaller diameter and greater width than the pulleys at the ends of the track in order to leave room for the multiple widths of cord.

    The Stamp controller could estimate the position of the "eyes" based on the speed and run-time of the motor, but there would be errors that would accumulate. The "end of track" sensors would be used to recalibrate things periodically when the "eyes" would normally move near the end of the track. If you also have a mechanical stop at each end, the motor's pulley would slip if the cord is not too tight and that would prevent damage to the mechanism.

    You could dispense with the motor controller and just use some relays or an H-bridge to turn the motor on and off and to change direction. It depends on how much control you want for the speed of the mechanism. On the other hand, a motor controller like the Pololu unit is inexpensive.
Sign In or Register to comment.