1

I'm looking for a way to build a cheap 1m linear encoder. Precision should be around 2cm (which is not really "precision").

Any advice will be welcome.

@Joe Hass : yes it is moving. Not really fast. Speed is not a concern. 1m per 10s is ok.

Edit : Thanks for help, as asked I give more details. The device will pick paper in drawers arranged vertically. There's one moving paper picking device, and dozen of drawers on top of each others. I need accuracy to locate the drawers to pick from. And a good notion of speed and position for the PID system that control the picking device. I think two laser cut optical rulers will do the trick. (there's a fablab in my city).

bokan
  • 301
  • 2
  • 9

5 Answers5

6

I'm not sure of the mechanics of what you describe but if it slides on a specific legth bar you can use an optical sensor that reads either slots on the bar or reflective areas (like a shiny sticker every 2cm)

enter image description here

Another idea is the use of a small wheel that has a similar optical sensor and by reading the wheel movement you can calculate the distance.

alexan_e
  • 11,070
  • 1
  • 28
  • 62
  • With two reflective sensors an a 'staggered' pattern you have in effect a linear form of a rotary encoder. Add a limit switch and a micro-controller can easily maintain the current position. – Wouter van Ooijen Jan 05 '14 at 22:45
  • I take this one ! I will use two rules, one with short gaps to keep track of the speed? The other with spaced larger gaps to mark the drawers position. – bokan Jan 06 '14 at 02:29
  • Given the task is to arrive at a given thing (drawer) rather than an absolute measured distance/position, I would consider using a few such sensors to prove an indexed system where you always know you're in exactly the right place by the combination of light/dark on the sensors. That way the drawers can be differently sized, imperfectly spaced, etc. - as long as you have an indexed system that knows when it's at a given "stop" you don't have to make changes when something moves, goes out of calibration, etc. – John U Jan 06 '14 at 18:07
  • @JohnU : Yes that's what I meant. Fine graduation ruler to keep track of speed. And another ruler with gap for each stops. – bokan Jan 06 '14 at 20:11
  • @bokan - I was meaning something a little different. You don't necessarily need the fine one for speed unless you are moving quite fast/hard and require significant accel/decel time, but with the addition of a unique binary combination of light/dark patches/flags for each drawer you can arrive at exactly the right place. Using optos as binary input, 3 optos would give 8 combinations, 4 would give 16, etc. although you might want to reserve combinations for end-stops and probably "all zero" would be the "not arrived yet / no flag" state. – John U Jan 07 '14 at 08:55
5

There's half a dozen good ways of doing this. The choice depends on the mechanical design and the environment in which the sensor will be operation (as @wzab had mentioned above).

Here's one more variant for the pile. A spring-loaded spool of thin cord. The shaft of the spool is connected to a rotary encoder. The end of the cable is connected to the moving part, while the spool remains on the stationary part, or vice versa. The spring takes (or some other tensioning mechanism) the slack out of the cord. As the cord unspools, it turns the rotary encoder. An advantage of this method is that it can work with long travel. This method is widely used in the telescoping cranes to keep track of extension.

enter image description here

Nick Alexeev
  • 37,739
  • 17
  • 97
  • 230
2

The suggested solution highly depends on the mechanical design of the system in which you are going to use it. E.g. if you are going to measure a distance between two objects, you may also consider using the ultrasonic transducer, e.g. something like: HC-SR04 (however its' applicability may depend on risk of interferences introduced by neighboring objects).

wzab
  • 629
  • 3
  • 10
2

I would suggest a string potentiometer.

Doug McClean
  • 493
  • 4
  • 16
  • I wonder if you and I wrote about essentially the same type of sensor under different names? – Nick Alexeev Jan 06 '14 at 02:16
  • Oh, I'm sorry, I didn't notice. It's essentially the same mechanically, it's different electrically. Instead of requiring pulse counting or gray code decoding you just read a voltage divider. Quite similar overall, I agree. – Doug McClean Jan 06 '14 at 02:43
2

If you want cheap and easy then, depending on many other aspects of the system, you might use an optical mouse or might be able to make it out of parts from one.

George White
  • 473
  • 3
  • 8