EEVblog Electronics Community Forum

Electronics => Projects, Designs, and Technical Stuff => Topic started by: DiTBho on September 03, 2022, 01:22:13 pm

Title: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 03, 2022, 01:22:13 pm
So, I have to measure eight positions on braided steel cable like in the attached picture.

(https://www.eevblog.com/forum/projects/lets-design-a-sensor-to-measure-eight-positions-on-a-braided-steel-wire/?action=dlattach;attach=1581208;image)

How to make the sensor?
Eight LEDs + photo-detectors, and a thin black ring on the wire?

STL design possible for the support-frame.

Ideas? Suggestions? All welcome  :D

[attachurl=1]
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: Stray Electron on September 03, 2022, 02:46:47 pm
  Eight optical sensors and a piece of shiny aluminum foil tape on the cable?  Depending on how dirty the signal from the sensors is, you might to use some schmitt triggers to clean up their outputs.

  Eight pieces of foil on the cable and one sensor feeding a ring counter would give you the same octal output. But it would only count up or down and you'd need a home sensor to start it from a Known position.

   If you wrap your cable around a pulley that has the same circumference as the spacing between the positions that you want to detect, then you could use an optical (or other) sensor that counts each time the pulley rotated one revolution.  Or perhaps even better would be to attack the pulley to a gear or to a star tooth reluctor and use an automotive sensor to count the teeth of the gear as they move past. That's the way that modern automobile engines keep track of the crank shaft position and control the ignition, fuel injuction and valve timing.

   If your environment is too dirty to use optics, you could clamp ferrules onto the cable  even use mechanical microswitches to detect when a ferrules reaches that position.

   Or do like the old dot matrix printers and use a stepper motor to drive the cable and once you start at a Known position, you can keep track of it's current position and you could drive it forward or backwards and always know where it's at.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: jmelson on September 03, 2022, 04:35:14 pm
Wrap the cable over a pulley and have a low resolution encoder on the pulley?
Jon
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: T3sl4co1l on September 03, 2022, 05:30:46 pm
Use 3 sensors and a binary code under each.  You need triple the length of the unary (8-sensor) solution.  Which, seems worth the mention.

If sensors can be arranged around the cable (and it doesn't rotate independently!), those three sensors can be arranged in the same place, using no extra length.

Wait scratch that -- gray code.  The sensors won't be perfectly aligned and binary code will give glitch states between.

Tim
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: mariush on September 03, 2022, 06:49:30 pm
Thinking of computer mouse ... put a wheel like the scroll wheel on the steel wire and count how many times the infrared / led light shines through the wheel spokes : https://www.techpowerup.com/forums/threads/mouse-scroll-wheel.242704/#post-3822135 (https://www.techpowerup.com/forums/threads/mouse-scroll-wheel.242704/#post-3822135)

I was thinking also of having something attached to the steel wire that consumes a bit of power, so that as you go up and down, the amount of current consumed changes and you'd be able to use a clampmeter like ring / loop around the steel wire to measure the current  - i guess the ring could be fixed on the steel wire and everything else could be on the sensor box.

Could glue or fix some sort of bar with teeth on the steel wire and have another steel wheel with teeth be turning clockwise and counterclockwise.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: fourfathom on September 03, 2022, 08:54:15 pm
It would be helpful to know why you want to do this.  What problem are you trying to solve?
Yes, gray code if you end up using some sort of parallel sensing.
You can sense eight positions using five detectors (actually, nine positions), by having the reflective strip (or whatever you use) be long enough to overlap two detectors.  This way you get a mid-position detection as well, like this:

10000 = 1
11000 = 2
01000 = 3
01100 = 4
00100 = 5
00110 = 6
00010 = 7
00011 = 8
00001 = 9

As a bonus, while this isn't exactly gray code it also has the property of glitchless transitions with no dead spots.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 03, 2022, 10:35:46 pm
sorry guys, I can't wrap the cable over a pulley, the cable needs to work straight line.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 03, 2022, 11:54:06 pm
(https://www.eevblog.com/forum/projects/lets-design-a-sensor-to-measure-eight-positions-on-a-braided-steel-wire/?action=dlattach;attach=1581757;image)

this is the problem I need to solve

[attachurl=1]
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: Warpspeed on September 04, 2022, 12:01:06 am
sorry guys, I can't wrap the cable over a pulley, the cable needs to work straight line.
Then you will have to attach something to the cable, no escaping that.
Either optical or magnetic.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: T3sl4co1l on September 04, 2022, 12:24:25 am
What about an encoder on the handlebars where it's set?

Tim
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: Someone on September 04, 2022, 12:38:37 am
It would be helpful to know why you want to do this.  What problem are you trying to solve?
What about an encoder on the handlebars where it's set?
It makes about 1000% more sense if in context with the previous thread asking pretty much the identical base problem.
https://www.eevblog.com/forum/chat/how-does-campagnolo-automatically-detect-the-teeth-on-the-bicycle-sprocket/ (https://www.eevblog.com/forum/chat/how-does-campagnolo-automatically-detect-the-teeth-on-the-bicycle-sprocket/)
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 04, 2022, 12:50:01 am
Then you will have to attach something to the cable, no escaping that.
Either optical or magnetic.

Yes, the cable is partially reflective, so - I have to test it, but - I could attach a thin opaque ring, so it won't reflect photons.

Kind of negative logic
11111110
11111101
11111011
11110111
11101111
11011111
10111111
01111111

not a problem

Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 04, 2022, 12:54:50 am
What about an encoder on the handlebars where it's set?

This can be easily done with Shimano but not with old Campagnolor shifters.

Also, I'd like to take advantage to the plastic case to also insert a cadence sensor: all in one, two sensors!
- gear sensor ---> useful for the bicycle computer
- cadence sensor ---> useful for me, the RPM will be displayed on the handlebar
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: DiTBho on September 04, 2022, 01:00:03 am
It makes about 1000% more sense if in context with the previous thread asking pretty much the identical base problem

In that topic in the chat area I was just curious, now I have to fix a problem!
Personally I think a gear sensor makes no sense until you have a cycling computer that needs this information for its purpose.
Title: Re: let's design a sensor to measure eight positions on a braided steel wire
Post by: joeqsmith on September 04, 2022, 01:51:20 am
From your other threads,  are you just trying to measure the gear ratio of your bicycle?  If so,  why not just look at the input and output shaft speeds and calculate it?    This is what I am doing with my bikes.