Motor Encoder and Motion Control Suggestions
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
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
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When the going gets weird, the weird turn pro. -- HST
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
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