Related: High Resolution ADC for Noisy Sensors in Variable Conditions

I'm building an interface using resistive textile-based sensors that may have different resistance ranges depending on environmental conditions. In order to best make use of my A/D converters, I'd like to explore using an adaptive amplifier that will help compensate for the unreliable performance of the sensors.

What are my options here? Or can you point me to some references on the topic?

I can think of two general schemes that would be useful:

  1. Auto-calibration by finding min and max values in a given analysis window (~30s-2min)
  2. Explicit calibration using a toggle-to-train interface
  3. ... Are there alternative schemes I'm not thinking of?

Some Constraints

  • It should be a one-chip solution (small) if possible (like capacitive sensing chips)
  • It should be easy to configure and use (I'm not an engineer and I'm not getting paid)
  • There will probably be a microcontroller nearby

Even better would be a do-it-all chip with Wheatstone bridge / voltage divider, lowpass filter and amplifier.

More About My Particular Setup

  • A/D converters will either be the converters built into an Atmel chip (could be ATtiny85 or ATmega32u4) or the converters built into an XBee series 2 radio. I've never used dedicated A/D chips before – I'm not sure if there would be any benefit to doing that.
  • The sensor will be a piece of polymer-doped conductive lycra from Eeonyx. The resistance changes by about 1 order of magnitude at 30% stretch.
  • The whole thing will be mounted on the hand of a performer, so it must be small and physically robust. There's a good chance it will be wireless.
  • Precision is important. The interface will be used to continuously vary realtime audio effects i.e. it's not a switch.
  • \$\begingroup\$ Are you able to provide any more details as to your current setup? ie: type of ADCs used, which touch sensor, which touch controller. \$\endgroup\$
    – tyblu
    Mar 19, 2011 at 16:03
  • \$\begingroup\$ How big are the variation you expect to get from environment changes? \$\endgroup\$
    – jpc
    Mar 21, 2011 at 3:33
  • \$\begingroup\$ What kind of bit-resolution do you need? I ask because I think it would be simpler to increase the spec on your ADCs by 4 bits (x16), and do the adaptation in software. That should be sufficient to capture a single order of magnitude variation. Of course, if you need 16 or 20 bits of resolution already, then that's going to be very expensive. \$\endgroup\$
    – anthony137
    Mar 21, 2011 at 19:27
  • \$\begingroup\$ @anthony137 that's an interesting idea. I've been thinking in terms of 10-bit converters since that's what microcontrollers usually have built in, but I'll have a look at high-rez converters. \$\endgroup\$
    – terrace
    Mar 22, 2011 at 16:09
  • \$\begingroup\$ @jpc I'll have to test. I'd like to have a system that can adapt to a wide range unknown of conditions, but I can get some ballpark figures. \$\endgroup\$
    – terrace
    Mar 22, 2011 at 16:10

3 Answers 3


Here is the basic idea:


V1 is the filtered PWM output and R2 is your sensor. U1 is voltage to current converter, with current through the load R1 being I = V1/R2. This means that voltage across R1 depends on both inputs. U2 and U3 is an instrumentation amplifier with gain 10, which amplifies the voltage across R1.

With R1 = 100 Ohms and V1 = 0..5V the circuit works for R2 = 50..5000 e.g. across two orders of magnitude, which from what you say should be enough.

What you do is take out and compare it with reference voltage (4V would be appropriate here for maximum dynamic range) and use successive approximation on V1 to get out as close as possible to the reference voltage. From V1 and known voltage drop across R1 (e.g. reference voltage) you can now calculate value of R2, your sensor. This will of course get you result only within the resolution of PWM, but you can use second instrumentation amp to amplify the error (difference between out and reference voltage) to get it within the range of your microcontroller's ADC and this will get you additional bits of resolution.

You need two opamps (U1 and comparator) and two instrumentation amps. Use real ones instead of making them from opamps, because the imprecisions of resistors and opamps will introduce error.

If two orders of magnitude were not enough, you can replace R1 with digital potentiometer to get another degree of freedom. I have never worked with one, so I don't know how precise they are and whether such solution would need some calibration or not.

Also, I should mention that it was jpc who came with the idea.


Ok, I have to agree with OP that this is not really the the answer to his question (though it solves the problem technically). I allowed myself to be carried away by "adaptive amplifier" in the title as an excuse to do some analog design. Forget everything writen above, unless you want to learn something (little) about opamps. Here is, I hope, better answer and much simpler solution:

Use resistive divider powered from a voltage regulator (to separate it from other circuitry's noise), with upper resistor set to about the maximum resistance your sensors can have (Rmax), and with the lower resistor being the sensor.

Set the reference voltage for your ADC to half the voltage regulator's output.

Then you sample the voltage on the sensor with your ADC. This way you need only one single-ended channel per sensor. I made ADC recommendation in the other post.

If you use 10 bit ADC that is integrated in the microcontrollers you mentioned, you will not get much of a dynamic range, though. Enhancing the range using analog circuitry, like the one I originaly posted, would add too many additional parts, which is why I would recommend simply to use some 24 bit ADC, like the ADS1256 I recommended in the other post, because it will give you low noise and high dynamic range, in a single chip (plus the reference, which is tiny, and the voltage regulator, which can be also tiny - you can also try to leave the regulator out and power the resistive divider directly from the reference - this will rob you of 1 bit of resolution, but there are plenty of them anyway). You will have to do some number crunching ("Auto-calibration by finding min and max values in a given analysis window" - is a good idea), but that's easy in this case.

I hope this is little more usefull.


This is the last one: I have been going through MSP430 microcontrollers from TI and I have found that some of them have 16 bit sigma-delta ADC with internal reference. Namely MSP430F2003 and MSP430F20013. That would be your one chip solution if you are willing to give up on Atmels. Very low power too. And they have in queue microcontrollers with 24 ADCs, but these are not in production yet. Than there are also PSoC microcontrollers from Cypress, which have 20 bit sigma-delta ADCs (PSoC 3 and PSoC 5 series), also with reference. These would be even better.

  • \$\begingroup\$ @Jaroslav I'm not sure I understand. In a voltage to current converter, V1 is usually from the sensor – in this case, since R2 is the sensor, what is the effect of U1? What are U3 and U2 for? Are they the instrumentation amplifiers? What are they fore? Finally, you say something about measuring the voltage drop across R1. How do I measure this drop and why do I need it? Finally, what kind of calibration scheme do you have in mind (see the two options I present in the post)? Thanks! \$\endgroup\$
    – terrace
    Mar 25, 2011 at 23:33
  • \$\begingroup\$ @Jaroslav Ah, I think you've responded to the wrong post. See here: electronics.stackexchange.com/questions/11978/… \$\endgroup\$
    – terrace
    Mar 25, 2011 at 23:40
  • \$\begingroup\$ Thanks for the acknowledgement but to be honest I was imagining something simpler. :) I think you are not really using the ADC much here? \$\endgroup\$
    – jpc
    Mar 26, 2011 at 1:07
  • \$\begingroup\$ @jpc indeed, 3 op-amps will take two much space anyway (8-channels, wrist-mounted) \$\endgroup\$
    – terrace
    Mar 26, 2011 at 1:44
  • \$\begingroup\$ @jpc Your solution does not really increase dynamic range. Simulate or measure to find out why. Also, it has a non-linearity during first 0.6V or so due to base-emitor diode. \$\endgroup\$ Mar 26, 2011 at 5:50

If the changes in sensor resistance are large (> 50%) then you could use a voltage divider circuit instead of the (more complicated) Wheatstone bridge. You can then easily improve the dynamic range by varying the supply voltage.

Adjustable supply voltage can easily be made from the PWM in your microcontroller together with a RC filter and a voltage-controlled current source.

Here is a rough schematic of my idea:

Schematic(from Socratic Electronics by Tony R. Kuphaldt)

You then connect the filtered PWM voltage to the non-inverting (+) input of the op amp.

For fast multiplexing you could make two such current sources. If you connect all even sensors to one and all odd to the other then you can change the voltage on the next sensor while your ADC is still sampling.

You should use a precision voltage reference for the ADC. You can also gain 1 or 2 bits by using a moving average filter in your software.

PS. I'd like to thank Jaroslav Cmunt for his vast improvements to this answer.


Have you read this site?

There are lots of examples of wearable electronics including some with Eeonyx fabrics. The site has examples of sensing circuits (ardunio and xbee).

You don't need many components to build a Wheatstone bridge and your likely best off with 1 sensing circuit multiplexed to the 8 sensors, you can still get 100 samples a second or more quite easily on each input. Use a fabric PCB (again check the site above) to create the bridge. Or just run sensor wires to the glove and put all the sensing electronics in a belt mounted pack. Most fabric 'sensors' i've seen have relatively high resistance, the 0.1 ohms you can get from the wire between the belt unit and gloves doesn't matter.

Put a temperature sensor in each glove and use the result to make a correction in the software if needed to adapt for environmental changes. Maybe calibrate the gloves before each use, may not be needed depending on the intelligence of the interpreter.

I assume the Xbee module transmits to a computer, build the calibration function into the computer, in fact do as much processing as you can, such as temperature correction, on the computer.

Bonus points if you just use a neural network to convert the sensor input to an action. This will make training it easy and adapt for different people's hand motions.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.