## Need some help with an automotive application circuit...

This is the place for any magazine-related discussions that don't fit in any of the column discussion boards below.
toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### Need some help with an automotive application circuit...

Hi all! Thanks in advance if you're able to help me here...

It's been 20+ years since I've toyed around with circuits, and I'll admit I forgot most of what I used to know.

My application is as follows:

I have a gauge in my car, that reads pressure (turbocharged car application). I'd like to drive that gauge with a different sender. Stock form, the sender drives the gauge from 0v to 5v, on a scale of 0psi to 28ish psi (14.7psi is atmospheric pressure - or at least thereabouts) , and the signal is linear. I'd like to replace the sender with a different one, which will also provide 0v-5v output, but on a different scale.

To clarify - right now, when my car is boosting to 1 bar (14.7psi), I get 2.5v out of the existing sender. IF I place the new sender in there, I'll get a smaller voltage, because the new sender has a larger range of values. Figure the new sender will have a range of 0-44 psi, so if I do the math, I expect to see about 1.666v. I want to be able to basically change the scale of the output so that the output of 1.666v from the new sender will actually send 2.5v to the gauge. Basically, it's a calibration circuit, and the new sender is also linear.

Ideally, I'd like to have a good way of selecting my range of voltages for the new sender, so I can use almost any sender I can find. Also, I'd love to be able to dial in the new sender and gauge, so that i can set the gauge to read any desired boost pressure. Like if I wanted the marking of 1 bar on the gauge to be atmospheric pressure, adjust a pot thusly, or if I wanted the 1 bar on the gauge to be 1 bar of boost, adjust accordingly.

So the circuit I'm looking for will read the input voltage, convert it to a different voltage, which could be higher or lower, (in a linear fasion) and then output that to my gauge. The circuit shouldn't send more than 5v to the gauge, ever.

Hoping someone can give me a hand...

Thanks!

Jay

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

### Re: Need some help with an automotive application circuit...

toolmaster wrote: Stock form, the sender drives the gauge from 0v to 5v, on a scale of 0psi to 28ish psi (14.7psi is atmospheric pressure - or at least thereabouts) , and the signal is linear.
You need a non-inverting analogue voltage
amplifier that has manual "gain" and "offset"

Gain is the ratio of input to output and could be
smaller than unity (i.e. input is attenuated).

Offset is a bias that is added or subtracted from
the output.

In instrumentation these terms may be called
"scale" or "slope" and "zero".
toolmaster wrote:Ideally, I'd like to have a good way of selecting my range of voltages for the new sender, so I can use almost any sender I can find. Also, I'd love to be able to dial in the new sender and gauge, so that i can set the gauge to read any desired boost pressure. Like if I wanted the marking of 1 bar on the gauge to be atmospheric pressure, adjust a pot thusly, or if I wanted the 1 bar on the gauge to be 1 bar of boost, adjust accordingly.
This can be done with a single IC (intergrated circuit)
called an Op Amp. Presumably you have a standard
12 volts (13.8V) supply and good ground available?

To make the circuit robust and reliable some effort
needs to go into protecting the new circuit from
automotive electrical noise and the harsh
environment. Hopefully you can install this in
the cab (not the engine area).

How comfortable are you with building a small circuit
by soldering together electrical components?

Do you have (at a minimum) a soldering iron,
small tools, a DMM (digital multimeter) and a
bench power supply (or fuilly charged car battery)?

Is either the existing gauge sender, the new one,
or the indicator gauge connected to chassis ground?
(Not a show stopper, but it affects what components
are selected and how the sender and gauge connect).

BTW, although I'm a firm follower of the KISS
principle, adding a red LED light at a certain
back off the gas pedal. Adding this feature would
be trivial once you have your original request
working.

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### I'm very comfortable building circuits..

Biggles -

Many thanks for the input. I can and will install this in the cab area, and have a good 12v and ground source readily available.

Like I said, Ideally I'd love to be able to dial in the gauge to any particular sensor, meaning that at atmosphere the gauge will read either 1 bar (normal) or beter yet for it to read nothing, and read only true pressure - meaning that when the sensor outputs 3.2v, the gauge sees 2.5v.

So I do think I need an op-amp with an attenuator circuit. The LED isn't a bad idea, or better if we can latch it when we hit a preset boost level (so we know something is wrong!).

Many thanks for any and all ideas!

Jay

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### Forgot to add...

The gauge is in fact connected to chassis ground, as is the current sender in the car.

Thanks!

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

### Re: I'm very comfortable building circuits..

toolmaster wrote: So I do think I need an op-amp with an attenuator circuit. The LED isn't a bad idea, or better if we can latch it when we hit a preset boost level (so we know something is wrong!).
While I'm scratching on the back of a bar napkin
perhaps others will jump in. I should have something
for you to try fairly soon.

The latching LED is no problem. I'm leaning towards
a push button to clear it, and a dial (volume control)
to set the trip point).

Also a toggle or slide switch to select "absolute" (gauge
shows 1bar at rest) or "boost" (gauge shows 1bar at
1bar above atmospheric).

Does your engine have a waste gate? I assume its
force-fed by a turbo or blower?

Engineer1138
Posts: 458
Joined: Thu Feb 05, 2004 1:01 am
Location: Minneapolis, MN
Contact:
Let's start simple and get more complex from there, OK

First, just the multiplier. Like Bigglez said, you need an opamp. To be sure that you don't exceed 5V at the output the best way is to make your power supply voltage 5V, so you need a voltage regulator. 7805 regs are cheap and easy to use. An opamp as simple as an LM324 (cost < \$1) should do the job. It has an offset voltage of up to about .025V, but since your sensor puts out about 8psi/V (44psi/5V), that offset error is only 8*.025= 0.22psi which should be negligible in an automotive circuit.

So we want to configure the LM324 in a non-inverting mode with a power supply of 5V and you want to scale the input voltage by 2.5/1.66= 1.5, so the gain of the circuit is 1.5. Pretty easy to achieve. Look around on the net for a non-inverting circuit for an LM324. If you use a trimpot in series with one of the gain resistors, you can adjust for different sensors.

To handle the car's power supply, I would suggest ( a full bridge rectifier cirucit on the input to handle power inversions along with a good filtering capacitor (100uF to start with). If the behavior is still noisy, then an inductor may be needed to improve the filtering. After this will come the 7805 supply and some small 0.1uF filter caps. The 7805 can safely handle 20V at the input, so momentary overvoltage shouldn't bother it. For additional safety clamping devices like TranZorbs can limit the input voltage when surges occur.

All told this circuit can probably be built for less than \$10 in parts including a perf board.

Getting attenuation instead of gain is what you need if a new sensor has a smaller range than the 0-28psi, but let's leave that feature for after this stuff all works

If you search the National Semiconductor website for the LM324 and LM7805 you should find plenty of circuits like the one I describe here, in greater detail. Come back when you have more questions.

-Lyndon

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### Answers, and one more question... ')

First off - thanks to the two of you - I may have to run to Radio Shack tomorrow to get stuff to start trying things out.

Biggles - the car does have a wastegate which dumps boost pressure to maintain a preset level. I know that part of the car is working fine.

Engineer - thanks for the info! Do you have a suggestion for a program or something I can use to diagram out the circuit I'm also scratching down? I found a non-inverting op amp circuit, and I agree on the 7805 idea with a bridge rectifier to protect it - totally.

10 bucks sounds like cheap to me. I'm getting excited to be able to use the gauge again.

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### Gauge Info...

Ok - gauge is about 1k in resistence. The stock configuration (at least I recall a little how to read schematics!) - the gauge is driven though a series of a 1.9k and a 2k ohm resistors. Makes sense to me, as right now - when the ignition is on and the gauge is reading 1 bar, I see about .45v on the two wires driving the gauge. That should mean about 2.5v if I disconnect the wires, which in fact is the case.

thanks!
Jay

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

### Re: Gauge Info...

toolmaster wrote:when the ignition is on and the gauge is reading 1 bar, I see about .45v on the two wires driving the gauge. That should mean about 2.5v if I disconnect the wires, which in fact is the case.
Two wires? Isn't the gauge connected to ground through
its metal mounting? Presummably the gauge powers
the sender, which is also grounded through its metal
mounting. How many wires connect the sender to the
gauge?

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### Gotta love German Engineering...

The gauge is powered through 2 wires. One of them is connected to chassis ground, the other coming off of the 'KLR' computer, on pin 5, which swings 0v to 5v depending on the level of boost.

The gauge itself has 2 wires on the back of it - which I actually connected the other night. (This car is a conversion to a Turbo, making it a very rare car indeed.)

Thanks!

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

### Re: Gotta love German Engineering...

toolmaster wrote:The gauge is powered through 2 wires. One of them is connected to chassis ground, the other coming off of the 'KLR' computer, on pin 5, which swings 0v to 5v depending on the level of boost.
Okay, that makes sense. Had me worried for a
bit - some OEM gauges operate from switched 12V and
the sender goes to ground (drawing current to deflect
the pointer).

On the sender, you think it's 1000 ohms (no boost)?
Does this value go up or go down under pressure?
At full scale what is the resistance?

To work it needs a bias from the switched battery.
In the new scheme I had it in mind that you would
only have the sender (one wire) and the gauge
(two wires, one is ground), and switched battery
(plus a chassis ground).

Here's what we have so far (crude sketch).

toolmaster
Posts: 14
Joined: Fri Oct 31, 2008 10:09 am
Contact:

### I think I've got something now...

Gents - thanks again! I'll hopefully head over to Radio Shack today to get the parts and stary playing soon.

Did have one question... If I use the 7805 regulator for 5V power, and use that to supply the op-amp's power requirements, what happens when the input signal goes above 3.3ish volts? If I have a gain of 1.5 on the op-amp, input is 3.4 for example, does the output of the op-amp get limited to 5v max because of the 5v input?

This isn't an 'issue' per say, as I'm really only concerned with reporting the up to 3.3ish volts on the meter as 5 volts, which will in effect peg the meter on the positive side. I'm more concerned about sending more than 5V to the meter which could damage it.

And if I wanted to change the scale, I could put a switch in the same box, and just run the input signal through a series of resistors as a voltage divider, which means I could then divide by 1.5 (meaning 3.333v which equates to 2 bar of pressure divides down to 2.5v, reading 1 bar positive pressure on the gauge).

Engineer1138
Posts: 458
Joined: Thu Feb 05, 2004 1:01 am
Location: Minneapolis, MN
Contact:
Bigglez:
I don't think your diagram came through OK. Looks like it's missing a few R's & C's. Why do you think the gauge needs a DC bias?

toolmaker:
That is correct: the opamp will be limited to its power supply rails (0-5V).

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

### Re: I think I've got something now...

toolmaster wrote: If I use the 7805 regulator for 5V power, and use that to supply the op-amp's power requirements, what happens when the input signal goes above 3.3ish volts?
Correct. use an LM7808 or equivalent (8V output)
You could also use an adjustable three terminal
regulator (LM317 for example) which has two resistors
to set the output voltage (from 1.2V min to Vin less
two volts).

Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:
Engineer1138 wrote:I don't think your diagram came through OK. Looks like it's missing a few R's & C's. Why do you think the gauge needs a DC bias?
The diagram is deliberately incomplete. I was seeking
feedback on the system level arrangement. Call me
slow but I couldn't follow the OPs description of the
gauge wiring (I now know it goes to ground on a
dedicated wire). Also, the sender needs an excitation
current, which may have been from the engine
control computer, and has to be replicated here.
So far I know the sender is 1,000 ohms (at rest?)
and the resitance goes down as the pressure goes
up. I don't know the transfer function, hopefully
it linear.
Engineer1138 wrote:That is correct: the opamp will be limited to its power supply rails (0-5V).
Depends upon the op amp type. The LM324
recommended earlier is not R-R (Rail to Rail). It
can't source more than 3.5V on a five volt supply.
To get a full 5V swing at the ouput you need to
raise the power supply (see comments above) and
select a R-R amplifier. The National Semi page for the
LM324
shows several suggestions.

Don't expect Radio Shack to carry these, though.

### Who is online

Users browsing this forum: No registered users and 33 guests