Author Topic: Thin String of circuits  (Read 1806 times)

0 Members and 1 Guest are viewing this topic.

Offline thefloridianTopic starter

  • Newbie
  • Posts: 8
  • Country: us
Thin String of circuits
« on: May 21, 2020, 06:10:05 pm »
Hello all. I am new to electronics and would love some help. I should probably "stay in my lane" but I'm trying to build a prototype and am hoping someone can point me in the right direction.

I need to report an absolute position to a numerical display (2 digit LCD).  I have to report positions along a straight line from position number "30" descending down to position number "0", in full number increments.  Each number has to be spaced 4.75 mm apart with a total length of roughly 150mm.  One of the catches is that the string of positions can only be a max of 7mm wide.

Also, it must be somewhat low cost as well to make this feasible.

So my thought was to approach this one of two ways. Either some kind of sensor head that is on a track that runs back and forth along the 150mm length and reports the numerical position as it moves.  Or, a series of contact circuits where as a device moves along the 150mm strip, a metal contact touches a - & + terminal and closes a circuit to indicate which position it is at. 

The device must be able to report the numerical position upon receiving power. So if the unit is at position 20 when it receives power, then "20" must report up to the LCD readout.

I hope this makes some sense. I attached a rough diagram that might help as well. If anyone has suggestions I would be appreciative.  I'm dealing in a very confined space so it is challenging me for sure.

Thanks!
 

Offline themadhippy

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: gb
Re: Thin String of circuits
« Reply #1 on: May 21, 2020, 07:11:24 pm »
Quote
a metal contact touches a - & + terminal and closes a circuit to indicate which position it is at
put a resistor at each position,1k at pos 1 ,2k at pos 2 etc and read the value with  a multimeter
 
The following users thanked this post: thefloridian

Offline Syntax Error

  • Frequent Contributor
  • **
  • Posts: 584
  • Country: gb
Re: Thin String of circuits
« Reply #2 on: May 21, 2020, 08:33:10 pm »
A contactless method could be to visually encode the track with a 'gray code' of parallel black and white lines. You'll need a read head containing five led-photo sensors which convert the code into a digital output, which you can then display.

In your case the code needs to be 5 bit or 5 lines wide as you're encoding from 00 to 30 (31 could be a locked or parking position). And it will read on power up.

This may not be the cheapest or best approach for your project, resistors will do fine, but this method is worth knowing about as reflected binary code (RBC), to use the technical name, is the basis of position encoding across engineering. Good luck with your project.

About Gray Code :  https://en.m.wikipedia.org/wiki/Gray_code
 
The following users thanked this post: thefloridian

Offline ebastler

  • Super Contributor
  • ***
  • Posts: 6984
  • Country: de
Re: Thin String of circuits
« Reply #3 on: May 21, 2020, 08:52:31 pm »
We might be jumping to solutions a bit too quickly here. Could you give a few more details about your requirements please?
  • You didn't mention any speed requirement. Does the display need to keep up with a fast-moving actuator? (How fast, or how slow, are the required changes?)
  • Also, is there a durability requirement? Electro-mechanical contacts may wear out -- again, depending on how often and how fast the actuator position changes.
  • Are dropouts critical? Two different flavors here: Depending on the chosen design, there might be "dead" positions between each of the contact positions, which would cause "stationary" dropouts. Or there can be contact bounce, which would only show up "dynamically", as the slider is moving. Are one or both of these acceptable?
 

Offline thefloridianTopic starter

  • Newbie
  • Posts: 8
  • Country: us
Re: Thin String of circuits
« Reply #4 on: May 21, 2020, 09:05:50 pm »
Ebastler, good questions.
1.There will be rapid jumps from one position to the next in sequential order. This speed will very depending on the user.
2.Durability is important so i do like contactless methods if possible. 
3.Dropouts between positions should not be an issue because the change from one position to the next will be rapid and should not be noticed by the user. The change in position will be near instant, but will linger on each position for variable amounts of time depending on the user.

Thanks
 

Offline wizard69

  • Super Contributor
  • ***
  • Posts: 1184
  • Country: us
Re: Thin String of circuits
« Reply #5 on: May 21, 2020, 09:59:45 pm »
Hello all. I am new to electronics and would love some help. I should probably "stay in my lane" but I'm trying to build a prototype and am hoping someone can point me in the right direction.
We can point you in any imaginable direction
Quote
I need to report an absolute position to a numerical display (2 digit LCD).  I have to report positions along a straight line from position number "30" descending down to position number "0", in full number increments. 
This is where your communications starts to break down.
Quote
Each number has to be spaced 4.75 mm apart with a total length of roughly 150mm. 
I hope you mean that the positions are 4.75mm apart
Quote
One of the catches is that the string of positions can only be a max of 7mm wide.
I have no idea what you mean by this.   I could take it to mean that you only have 7mm of usable physical width for the detector.
[quote

Also, it must be somewhat low cost as well to make this feasible.
[/quote]
Well yeah that is what they all say.    One off devices/solutions by their nature are expensive.   Further you have no indications of the environmental conditions.
Quote
So my thought was to approach this one of two ways. Either some kind of sensor head that is on a track that runs back and forth along the 150mm length and reports the numerical position as it moves.  Or, a series of contact circuits where as a device moves along the 150mm strip, a metal contact touches a - & + terminal and closes a circuit to indicate which position it is at. 
The best solution depends upon many factors that you have offered no information on.

For example my background is more industrial and in a rough positioning system like this we might use a relatively cheap linear sensor.    Linear resistors can be had in all sorts of lengths with very easy connection to a microprocessor (you basically have a voltage divider): https://www.megatron.de/en/category/linear-sensors.html.    If that doesn't float your boat Temposonics has an interesting series of sensors: http://www.mtssensors.com/products/industrial/index.html   These are the sorts of things that come to mind first as most of the engineering is done for you.

Other things that are often used are prox switches set up to provide a binary position value.    How useful this would be in your application is unknown.   You would need 5 bits of data to cover 30 positions so this is a lot of prox switches.   You also need a series of "cams" to actuate them.

While a bit far from industrial practice you could use Electronic circuitry methods to fabricate a PCB with holes optimally spaced and use through hole optical detection.  You still need 5 bits of data.    You seem to have thought about something similar that uses physical contact detection.   Without specifics it is hard to say which would be better.   In a dust free environment I'd go for an optical solution.   Unless you put a lot of engineering into it, contact detection will be a pain to make reliable and long lasting.   Actually for optical detection you might be able to do reflective of a gold plate and dark solder mask.
Quote

The device must be able to report the numerical position upon receiving power. So if the unit is at position 20 when it receives power, then "20" must report up to the LCD readout.
That leaves out a lot of incremental solutions.
Quote
I hope this makes some sense. I attached a rough diagram that might help as well. If anyone has suggestions I would be appreciative.  I'm dealing in a very confined space so it is challenging me for sure.

Thanks!

Confined space can be an issue but you need to look for free space that might not be obvious.    EDIT:

Right after posting this I realized I forgot one way that might be better for this application.   You can buy these days laser sensors that allow for an analog output and that output can represent distance to target.   I've actually have forgotten which ones we use at work but there are many suppliers including Baumer, Wenglor, Banner Engineering, Keyence, Rockwell and a whole bunch of others.    I've seen such sensors used to count stacks of trays 3/4" thick very reliably.   The trick is finding one that fits your application with minimal distance requirements.    Sensors like this ae not universally cheap but they can solve problems that can't be solved quickly any other way.
« Last Edit: May 21, 2020, 10:22:50 pm by wizard69 »
 

Offline senso

  • Frequent Contributor
  • **
  • Posts: 951
  • Country: pt
    • My AVR tutorials
Re: Thin String of circuits
« Reply #6 on: May 21, 2020, 10:04:13 pm »
Just hack a cheapo ebay caliper, read current position from the caliper, done.
 

Offline wizard69

  • Super Contributor
  • ***
  • Posts: 1184
  • Country: us
Re: Thin String of circuits
« Reply #7 on: May 21, 2020, 10:34:24 pm »
Just hack a cheapo ebay caliper, read current position from the caliper, done.

This is a good idea if he can fit one in.   For most of these calipers or linear scales the data ports are well understood so creating a remote display is fairly easy.

One could also go the cheap Chinese linear scale route such as : https://www.dropros.com/DRO_PROS_Digital_Readout_Magnetic_Scale.htm. but I don't believe these are absolute.   He wants the position data to remain after a power cycle, so maybe not a good choice.
 

Offline ebastler

  • Super Contributor
  • ***
  • Posts: 6984
  • Country: de
Re: Thin String of circuits
« Reply #8 on: May 22, 2020, 08:49:39 am »
A contactless method could be to visually encode the track with a 'gray code' of parallel black and white lines. You'll need a read head containing five led-photo sensors which convert the code into a digital output, which you can then display.

If it needs to be a linear geometry and contact-less, that's probably the way to go. The digital calipers suggested elsewhere might be an alternative, if you can get some with absolute readout which also meet the "max. 7mm wide" requirement.

In principle, what you are looking for is an "absolute linear encoder". These are commercially available of course, in many different lengths and most commonly with optical readout. But they are probably too expensive (a few $100), and are much more precise than what you need.

If you could reduce the travel range to 100mm, a linear potentiometer and a microcontroller with built-in A/D converter would be a very simple solution which doesn't require any mechanical tinkering. Or could you convert the linear motion into a rotary one (e.g. via a dial cord or a lever), and then either read a rotary potentiometer or a rotary optical encoder?
 

Offline Syntax Error

  • Frequent Contributor
  • **
  • Posts: 584
  • Country: gb
Re: Thin String of circuits
« Reply #9 on: May 22, 2020, 09:26:16 am »
As @eblaster says, if you can reduce the travel range then you can read a static potentimeter - using the ADC on an Arduino. Connect the slide to the pot using a taut string in the same way an old radio dial works. Some reduction gearing is needed to convert 150mm of linear travel into 270 to 300 degrees of turn on the pot.

This would be contactless, slim, cheap and always read true on power on. The potentiometer output may need to be buffered through an opamp to ensure the voltage range is stable and predictable.

Lots of ways of achieving the same outcome :)
 
The following users thanked this post: thefloridian

Online mikerj

  • Super Contributor
  • ***
  • Posts: 3326
  • Country: gb
Re: Thin String of circuits
« Reply #10 on: May 22, 2020, 11:10:59 am »
Is there a possibility of using a rotary sensor (e.g. multiturn potentiometer) coupled to the sliding part e.g. by a tensioned string system as used on old radio tuning dials or a small toothed belt?  A rotary encoder is bulky compared to the dimensions of the system described in the OP, but if it could be mounted remotely that might not matter.
 

Offline Syntax Error

  • Frequent Contributor
  • **
  • Posts: 584
  • Country: gb
Re: Thin String of circuits
« Reply #11 on: May 22, 2020, 12:02:19 pm »
Another way?

Place 30 LEDs on the track and illuminate them in sequence (multiplex) faster than the eye can see. The slide has a photosensor that detects the LED blink. The microcontroller software knows which LED blinked, and there's your number. You'll just need plenty of GPIO pins to multiplex 30 LEDs. You could make this look really cool if you included RGB leds into the design.
 

Offline ebastler

  • Super Contributor
  • ***
  • Posts: 6984
  • Country: de
Re: Thin String of circuits
« Reply #12 on: May 22, 2020, 03:47:55 pm »
Is there a possibility of using a rotary sensor (e.g. multiturn potentiometer) coupled to the sliding part e.g. by a tensioned string system as used on old radio tuning dials or a small toothed belt? 

You mean, different from the possibility discussed in reply #8 ("convert the linear motion into a rotary one, e.g. via a dial cord") or in reply #9 ("connect the slide to the pot using a taut string in the same way an old radio dial works")? 

Geez, does anybody actually read the replies before posting?  :P
 

Offline ebastler

  • Super Contributor
  • ***
  • Posts: 6984
  • Country: de
Re: Thin String of circuits
« Reply #13 on: May 22, 2020, 03:59:20 pm »
Another way?

Place 30 LEDs on the track and illuminate them in sequence (multiplex) faster than the eye can see. The slide has a photosensor that detects the LED blink. The microcontroller software knows which LED blinked, and there's your number. You'll just need plenty of GPIO pins to multiplex 30 LEDs. You could make this look really cool if you included RGB leds into the design.

That's a nice one! No contacts or potentionmeter surfaces that could wear down over time, and it doesn't require any optical resolution to speak of (unlike the 5-bit-per-position binary code).

5+6 pins to drive a matrix of 30 LEDs, plus one input for the photosensor, sounds quite reasonable. Or, of course, you could use external shift registers to drive the LEDs, or WS2812-style LEDs which can be cascaded.
 

Offline Syntax Error

  • Frequent Contributor
  • **
  • Posts: 584
  • Country: gb
Re: Thin String of circuits
« Reply #14 on: May 22, 2020, 04:16:04 pm »
@eblaster - neopixels would be perfect as they only need one GPIO pin and, their color could change to indicate the pointer position. The only challenge is how to get the photosensor coupled to the leds without the need for flying leads or copper contacts? Some kind of refractive light pipe?
 

Offline thefloridianTopic starter

  • Newbie
  • Posts: 8
  • Country: us
Re: Thin String of circuits
« Reply #15 on: May 22, 2020, 05:24:11 pm »
Quote
a metal contact touches a - & + terminal and closes a circuit to indicate which position it is at
put a resistor at each position,1k at pos 1 ,2k at pos 2 etc and read the value with  a multimeter

I appreciate your suggestion. This seems to be the simplest option.  Question for you. If the goal with this method is to use a multimeter to measure the volt readout on each descending position and have each voltage correlate with a position number, do multimeter's read voltage nearly instantaneous? I am concerned with a delay in readout with this method.
 

Offline themadhippy

  • Super Contributor
  • ***
  • Posts: 2986
  • Country: gb
Re: Thin String of circuits
« Reply #16 on: May 22, 2020, 05:31:12 pm »
Quote
to use a multimeter to measure the volt readout
no need to read volts and convert,use 1k steps and read the output directly from an ohmeter (multimeter set to ohms) .The speed depends on how quick your meter can take and display the reading

Quote
5+6 pins to drive a matrix of 30 LED
or just 6 if you charlieplex them.
 

Offline thefloridianTopic starter

  • Newbie
  • Posts: 8
  • Country: us
Re: Thin String of circuits
« Reply #17 on: May 22, 2020, 05:51:28 pm »
A contactless method could be to visually encode the track with a 'gray code' of parallel black and white lines. You'll need a read head containing five led-photo sensors which convert the code into a digital output, which you can then display.

In your case the code needs to be 5 bit or 5 lines wide as you're encoding from 00 to 30 (31 could be a locked or parking position). And it will read on power up.

This may not be the cheapest or best approach for your project, resistors will do fine, but this method is worth knowing about as reflected binary code (RBC), to use the technical name, is the basis of position encoding across engineering. Good luck with your project.

About Gray Code :  https://en.m.wikipedia.org/wiki/Gray_code

Is this what you are referring too? https://www.components.omron.com/product-detail?partNumber=B5W-LB&gclid=CjwKCAjw8J32BRBCEiwApQEKgXFvB-YbIb7bgijePBkyF1pA-YAW-SXLR6w1JGtKxVnDxb8PB38yahoC2YYQAvD_BwE
 

Online mikerj

  • Super Contributor
  • ***
  • Posts: 3326
  • Country: gb
Re: Thin String of circuits
« Reply #18 on: May 23, 2020, 03:55:43 pm »
Is there a possibility of using a rotary sensor (e.g. multiturn potentiometer) coupled to the sliding part e.g. by a tensioned string system as used on old radio tuning dials or a small toothed belt? 

You mean, different from the possibility discussed in reply #8 ("convert the linear motion into a rotary one, e.g. via a dial cord") or in reply #9 ("connect the slide to the pot using a taut string in the same way an old radio dial works")? 

Geez, does anybody actually read the replies before posting?  :P

I tend to miss stuff when it's buried at the end of a load of other stuff talking about a different solution.  Geez, does no one here bother to lay out solutions clearly?
 

Offline thefloridianTopic starter

  • Newbie
  • Posts: 8
  • Country: us
Re: Thin String of circuits
« Reply #19 on: June 05, 2020, 06:44:17 pm »
Thanks again for all of you that have posted suggestions.
I believe i have settled on a direction.
IF anyone has experience diagraming circuit boards (flex specifically) in a format that I can submit to a manufacturer for quote and production, and wants to do some side work please message me.  I need to get a prototype manufactured but am out of my element. 

thanks,
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf