Shop OBEX P1 Docs P2 Docs Learn Events
Motor Encoder and Motion Control Suggestions — Parallax Forums

Motor Encoder and Motion Control Suggestions

ZootZoot Posts: 2,227
edited 2006-10-29 23:37 in Robotics
Hi all -- I am looking for clever suggestions on devising encoders for the big surplus motor/wheel combos that drive my 'bot.

Attached below are some photos of the drive units disassembled and assembled. A few comments/requirements:

- I was hoping to avoid optical encoding since dust and pet hair and the like build up quickly around here. Optical encoders tend to gunk up pretty quickly (our Roomba doesn't last a week without serious cleaning). But I'm not sure there's a better way...

- I had hoped to use the Parallax Hall effect sensor on the main wheel gear, but it is totally non-ferrous (or seems to be).

- maybe very narrow focus IR interrupter (like on a mouse wheel) on the main wheel gear?

- I could paint optical strips on the non-gear part of the wheels rather than having a separate disk

- the motor shaft is accessible on the gearbox side (I've read about some 'bot projects where an optical encoder is super-glued to the shaft a sensor is attached, and then the whole thing covered with a film canister or the like to keep out interfering light, dust, etc). I don't really care for this option as it would make the thing pretty bulky.

- it's pretty easy to disassemble the whole thing and throw the mounts on a drill press for creating access holes or sensor mounts

My basic goal is to program an SX-28 to do all the counting and parsing for the encoders for two motors. I don't think I will do quadrature encoding per se at first -- just getting reasonably accurate speed/distance would be great (the 'bot's speed varies widely depending on the surface, battery charge, etc).

The second step will be add code (or probably another SX) to do motion control calculations -- speed, rotation angle, turn radius, distance. The idea is to have my BS2p40 be freed of the task of all the geometry. I've looked at some of the commercially available motion controllers, some distributed by Parallax, and none of them do exactly what I need, so I figured I'd be better off using those spiffy SX chips, e.g.,

Stamp sends simple angle, dist, speed info to SX ->
motion SX parses geometry and handles PID for speed, using output from encoder SX ->
final parsed speed is sent to motor controller (i2c) ->

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When the going gets weird, the weird turn pro. -- HST
1050 x 1400 - 580K

Comments

  • ZootZoot Posts: 2,227
    edited 2006-10-28 17:44
    More pictures...

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    When the going gets weird, the weird turn pro. -- HST
    1050 x 1400 - 627K
    1050 x 1400 - 467K
    1050 x 1400 - 625K
    1050 x 1400 - 608K
    1050 x 1400 - 518K
  • Desy2820Desy2820 Posts: 138
    edited 2006-10-29 04:18
    I'd suggest using epoxy to attach a small magnet on the wheels, then using the magnet to activate the hall effect sensor.· How strong rhe magnet needs to be will depend on the distance between the wheel and sensor.

    I'd try using a·small·powerful rare-earth magnet, but you'll probably still need to expeirement some.· I can't offer any other suggestions regarding the rest of the·items.
  • kelvin jameskelvin james Posts: 531
    edited 2006-10-29 05:29
    Your best bet is a shaft encoder that is mounted to the motor shaft, front or back, size would not be an issue. Most are sealed units, so no worry about the enviroment. Better to keep the electronics away from the wheels, where it is apt to pick up a lot of dirt and other Smile.

    kelvin
  • ZootZoot Posts: 2,227
    edited 2006-10-29 23:37
    Thanks, all, for some of the suggestions. I'm still not sure a sealed encoder on the motor shaft will work -- partly because I'm looking to keep things really simple and partly because when the units are mounted in the bot, if I have any more bulk hanging off either side, I either hit the inside of the chassis or it will stick out far enough on the outside that it will get snagged on objects like dogs, people, etc.

    The idea of epoxying a magnet to the main wheel or main drive gear is not bad -- I need better resolution, though, and I'm not sure about glueing on lots of magnets.

    But that got me to thinking --- what about a ferrous disk with hole or spokes or something mounted on to the main hub bushing up against the main gear? Sort of like mounted a magnetic encoder disk rather than an optical one -- that might give me something fairly simple to construct, that doesn't have dust problems, and wouldn't cost a whole lot of $$. Look at the very first picture above where there is a good shot of the main bushing, gear and wheel, and you'll see what I mean.

    Suggestions on what kind of metal/substance would work for Hall effect sensors? The idea would be to mount one of those Parallax magnets on one side, the Hall effect sensor on the other, and have the spoked or sprocketed ferrous disk between them? Thoughts? Suggestions?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    When the going gets weird, the weird turn pro. -- HST
Sign In or Register to comment.