Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help for 12V->5V opamp buffer for A/D

Status
Not open for further replies.

Chancy99

Computer
May 13, 2002
104
Hi All -

Please take a quick look at if you get a chance ...

I'm building a datalogger for in-car use, and am stuck at the A/D input design stage. I don't know analog/opamps :(

Basically, I need an opamp buffer for each input channel that will take a signal that can range from 0-14V and map it to the A/D input range of 0-5V.

It should have high input impedance so as not to load down the signal being monitored, and have low output impedance to allow the A/D to sample nice and quickly.

What little I know about opamps leads me to believe I can use a 14k resistor for RI and a 5k for Rf to get a less-than-unity gain to do that mapping. Is that right ?

Help ...

Thanks -

Dean.
 
Replies continue below

Recommended for you

Dang it - got the thread wrong ... Use this one :

thread108-20335 'bout that.

Dean.
 
You can have an input divider -- 9k/5k or even 900k/500k --
buffered with a voltage follower ( OP AMP output and -inp.
connected, input to +inp.)
<nbucska@pcperipherals.com>
 
Would you *have* to use a voltage divider to front the opamp ? Couldn't you set up the opamp to have a less-than-one gain, to reduce the signal voltage range ?

Less parts, less cost, easier pcb routing ...

Dean.
 
Non-inverting amp's gain is not less than 1. -- you have to divide the input.
<nbucska@pcperipherals.com>
 
Hi, and by the way you also need to put in a low pass filter for antialiasing.
 
True, 2 resistors is pretty simple, even easier using resistor packs for multiple opamps.

I just want to be sure that I don't change the signal being measured by pulling too much from it. For example, a 180k/100k divider will pull about 0.5mA - that isn't much, but it might be enough to throw the signal to the car ECU off ...

Dean.
 
you may use FET input (J or MOSFET) amp with femtoAmp
input current. You can't reduce the current to zero but
close... <nbucska@pcperipherals.com>
 
Or just add a simple clamping diode. Actually, you will want to clamp your input to VCC (5V) and Ground. By clamping it high, you will protect for excessive voltage if your resistive divider breaks down. And by placing a ground, or negative transient, clamping diode, you will protect against any negtive voltages in excess of -0.7V. This will help protect your micro.

Otherwise, I agree with the resistor posts. There is really no need to try an buffer you input signals too much. By simply providing a good resistive divider (try to stay away from large R values, any amount of leakage current will produce voltage that can become signifigant), you will effectively clamp your input signal. One reason I feel so strongly about this, is because I use these circuits to level shift input singals for automotive applications. Therefore, these circuits are subjected to very hostile applications and have always proved to be very robust (providing that you size the components correctly).

Good luck and keep us posted!!!
 
Hi, in your 1st post you mentioned 14k and 5k resistor values, now you want to change things.
 
The 14k and 5k were to get an opamp to do an appropriate <1 gain to reduce the signal from 14V to 5V.

The 180k and 100k are for a voltage divider to do the same thing. This would go in front of a unity voltage-follower opamp.

Problem is, I don't know if the opamp-only way will work, me being opamp-clueless. I would prefer it muchly if it would ... two less resistors per channel, 16 channels, that's a fair amount of board space.

Dean.

PS, Ron/buzz41 has shown a nice way to do it in thread

thread108-20335 will handle all the cases I would need I think. 0-5V, 0-14V and 9-14V.
 
Adding active components only compounds your problems. I am a big believer in the KISS theory. Passive components are much more robust and will generally be easier to troubleshoot / characterize. Adding an op-amp circuit will only increase the complexity of the circuit, while giving limited benefits. Resistors vary the same with repect to temperature, while op-amps follow a non-linear trend. If the A/D reading has to be stable over temperature, then keeping the input voltage at a constant level, with respect to temperature, is easily accomplished with a simple resistive divider. Once you start putting in op-amp circuitry to compensate over temperature, then your circuit complexity get higher (getting away from KISS).

Did you try a simple resistive divider with clamping diodes? If not, take a few minutes to wire it up. You might be pleasantly surprised!

Good luck and keep us posted!!!
 
melone:

I'll take a look at just the divider, but I'm a little worried about the loading that will put on the signal. The AVR wants a 10kohm or less output impedance from the sensor in order to drive the successive-approx A/D. Any higher and it takes too long.

I want to make sure that the act of measuring won't affect the signal itself. So an ideal interface between the signal and the A/D would have a high input impedance and low output impedance.

I've talked/emailed a linear.com engineer, and it looks like there isn't a simple way to do the 0-14V -> 0-5V scaling with just an opamp. So it will need the resistor divider up front, with a voltage-follower opamp buffer after.

What do you think of Ron/buzz41's design in the other thread ?

thread108-20335
 
If you use large R values (I know, it contradicts my earlier post), then your input impedance will be fairly high. BTW, what type of signal are you trying to sample? What is the frequency, current, output drive capabilities, etc.?

Don't get me wrong, Ron/Buzz41's suggestions will work, but I just try to avoid putting in active components as much as possible since they are the most likely to fail. They are also the most difficult to troubleshoot since you generally don't know exactly the internal workings of the IC, and &quot;strange&quot; outputs can be easily attributed to IC functionality.

Good luck and keep us posted!
 
melone:

Unfortunately, most of the signal definitions are vague at best from Toyota. They are simply to allow the service engineers to know whether or not a signal is within spec.

I'm sure it's the same case with most of the other car manufacturers ... Although they do define when the signals are pulse-generation ones.

For example, throttle position is a resistive element, providing a variable voltage. The service manuals spec this out as &quot;2.3-4.9V&quot; being valid. I've measured this one, and it's a linear representation, so that's an easy one.

Some of the others are spec'd out as &quot;9-14V&quot; with engine running, or &quot;1.2-2.2V&quot; with ignition on. I tend to think that these are HI/LO signals - low voltage when ignition is on, and higher after the engine actually starts. But we won't know until we actually start grabbing values.

As so current or output drive capabilities, no way will ToyCo release that info. Heavens-to-Betsy, you might be able to <gasp> alter those signals to fool the ECU into doing things it wouldn't normally do ! Umm, kind of how most aftermarket fuel-management computers do, like the Apex'i S-AFC.

So you think we can do away with the buffers, and just use a high-R voltage divider network ? That would be a lot easier to do, especially just for 0-5V or 0-14V signals. What about the 9-14V ones ? Putting that through a 0-14V divider will lose the bottom 2/3 or the range.

Ideally, I would like to be able to map

0-5V -> 0-5V unity mapping
0-14V -> 0-5V scale down
9-14V -> 0-5V unity mapping with offset

Dean.
 
Let's just say that I have been designing automotive engine controllers for the past 3 years for a very large American automobile manufacturer, and I use resistive dividers exclusively. The 5V signals are very simple, just have a good series element to prevent over-driving the input. The 14V signals, simply need a resistive divider that will drop the voltage down to 5V. The 9-14V signals, are a little unique. You might have to translate the signals with an op-amp network, but I would be willing to bet that basically they are using these signals as ON/OFF (digital) signals.

Wait, another idea, how about a series zener to drop the incoming voltage from 9 to 1V. This should allow a simple resistive divider the ability to translate the remaining voltage. If you choose your resistors correctly, the current through the zener will be around 2.5-5mA and everything will work.

Good luck with your customer. I have dealt with them in a previous job and do not envy you. Take everything they say with a grain of salt, and always ask what is the circuit supposed to do, and what is it connected to EXACTLY (no approximations).

Good luck and keep us posted!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor