After several days of playing with different ideas, I think I am on the verge of solving this problem -- very close -- but can't quite grasp how to fit in the mechanics.
The goal is: I am trying to measure the gap between two surfaces. The gap has a value between 3 and 9 mm and is closed together over time as a process occurs -- I'll need to measure the gap versus time, so I am considering a setup that I can leave in place and log the data to my Arduino Nano's EEPROM or use an SD shield.
The problem is that I want to measure the gap with a resolution of 0.1 mm or better ideally.
So I gave it a shot using inductive sensors (too big to fit in the gap), computer-vision-based attempt (not very portable), and a couple of other methods.
Finally one day, I was using a caliper and realized that a standard caliper which uses capacitive-plate measurement can easily get this kind of resolution (even 0.01 mm or better), so why not use this readymade device?
Of course, re-designing the whole caliper/capacitive-plates/etc. from scratch would be too complicated for a beginner-intermediate electronics hobbyist like me.
So I am wondering if there are any easy ways I can take my caliper and somehow repurpose it to solve this problem.
For example, something like in the below image. And since I only need 3-9 mm full range of movement, I could cut off all the unnecessary portion of the caliper (for example, in the below image, most of the right-hand section of the caliper.
But could I somehow make it compact or could there be a simplification of this?
I am pretty sure my suggestion isn't as smart with the mechanics as might be possible.
I think a leadscrew with a stepper motor, or a shaft encoder, or both. would be easier to implement, easier to calibrate, and easier to read. Probably more accurate too.
@Nick_Pyner:
Could you elaborate: The leadscrew placed where?
If you are suggesting to attach it behind/to the right of the moving Surface B and track the number of rotations as it closes in on the gap, this is not a viable option in my particular case because of these reasons:
a) the Surface B is actually large/massive (my picture is just an exaggerated illustration)
b) there is no convenient place behind/to the right of Surface B where I can station the encoder/leadscrew, etc.
c) I prefer to isolate the full setup to within the gap's neighborhood, so that I can simply move my setup to another place and use it again.
You can get versions of this calliper that have computer outputs that you may be able to connect to an arduino. Then you could maybe put some form of expansion spring between the external jaws of the callipers to hold them open while the internal jaws are measuring the gap. As the gap closes the spring compresses and as the gap open the spring pushes the callipers open to fit the gap. Maybe a spring is not ideal as the weigh will increase as the gap narrows but you get the idea.
@Riva: That's along the right lines I think -- But note that even the very tips of the internal jaws of the caliper are still a bit too thick for my gap. Hence, my thought of perhaps attaching something to the edges of the caliper jaws and then extending that something out into the gap. Hmm...
( Also, the spring you mentioned was just to provide counter-support to prevent the caliper from closing, am I correct? )
Just now, I have also updated the design idea to something like the following -- first image below. And then perhaps use a really compact caliper like the one in the second image at the bottom.
But really, I wish I could somehow just ditch the majority of the caliper altogether, and just find some compact way of measuring the stretching/de-stretching (compression and extension) of the scissor-shaped/alligator-clip-shaped blades in this setup:
Why not make a capacitive sensor and measure the capacitance? Depending on what A and B are made of, making the sensor might be as simple as gluing some metal foil on the faces of A and B.
If you're looking at solutions that involve connecting the moving parts to position sensors then you aren't measuring the gap any more - you're just measuring changes in position. If that's all you need then you just need to connect a potentiometer with a suitable gearing/leverage so that if gives you your 0.1mm resolution or better and use analogRead().
@Nick_Pyner and @PeterH:
That's the thing; I would like to minimize the number of moving parts, so that the assembly is relatively free, insert-and-remove, and ideally portable.
Gearing and shafts would introduce more moving parts which might contribute to drift over time unless I design it extremely well (which is not assured in my particular case of little mechanically skill).
dc42:
Why not make a capacitive sensor and measure the capacitance? Depending on what A and B are made of, making the sensor might be as simple as gluing some metal foil on the faces of A and B.
This might work well I think because the foils could be very thin.
This would also make it a very lightweight solution that I could insert and remove when needed.
So the dielectric is air, the cross-sectional area stays constant -- and only the distance between the plates would change, which the capacitance is inversely proportional to.
I presume I would have to use an RC circuit, apply a constant voltage, and track the charging/discharging to infer the time constant. So something like this: http://arduino.cc/en/Tutorial/CapacitanceMeter
@dc42: How immune would such a sensor be to environmental noise? I am trying to see how I can design this in way that would ensure the capacitance measurement is accurate (able to track the distance between the capacitor plates down to changes of 0.1 mm or better).
giantsfan3:
I presume I would have to use an RC circuit, apply a constant voltage, and track the charging/discharging to infer the time constant. So something like this: http://arduino.cc/en/Tutorial/CapacitanceMeter
@dc42: How immune would such a sensor be to environmental noise? I am trying to see how I can design this in way that would ensure the capacitance measurement is accurate (able to track the distance between the capacitor plates down to changes of 0.1 mm or better).
When used to measure low values of capacitance, the R-C time constant method needs high value resistors, making it susceptible to leakage and mains pickup. I prefer to use the capacitor in a 555 oscillator circuit, then measure the output frequency with the Arduino. I recommend using a CMOS 555 because it allows you to use higher value resistors than a regular 555. See Water level sensor w/ nichrome wire no, now capacitive - #17 by dc42 - Project Guidance - Arduino Forum and other posts in the same thread for an example.
giantsfan3: @Nick_Pyner and @PeterH:
That's the thing; I would like to minimize the number of moving parts, so that the assembly is relatively free, insert-and-remove, and ideally portable.
Gearing and shafts would introduce more moving parts which might contribute to drift over time unless I design it extremely well (which is not assured in my particular case of little mechanically skill).
So far you haven't mentioned any requirements for long term stability or repeatability. I don't see any reason why it would be any harder to meet those requirements with a mechanical system than with an electronic one, but you need to make it clear what the actual requirements are.
You can use a laser beam and count how many times the intensity increases and decreases during the motion. A laser is made into two beams using a prism and mirrors. The two beams hit a phototransistor. One beam is the reference beam and it does not move. The second beam hits the target surface and reflects back to the detector. The phototransistor will respond to constructive interference and destructive interference by giving an output current that is an analog of the number of wavelengths that the target has moved.
Example : IR laser beam infra red with a wavelength of 1um = .001mm
The target moves .1mm and the phototransistor current increases and decreases 100 times as 100 wavelengths are measured. When the reference beam has a positive phase and the target beam has a positive phase, the current is high. When the reference beams has a positive phase and the target beam has the opposite phase, the current is low.
This is pretty standard stuff for your typical boffin. It is written. So let it be done.