Help - Search - Members - Calendar
Full Version: Home made rich/lean indicator
LR4x4 - The Land Rover Forum > The Lounge > Tools and Fabrication
ThreeSheds
I have a lambda sensor of the Zirconia type taking up space on the bench and I was wondering if it's possible to make a rich/lean indicator (two LEDs perhaps) using it. I have no real knowledge of electronics, but can solder to a vero-board and have recently put together a Megajolt kit and installation.

Normally I like to 'have a go' before asking and so after a couple of hours on the web I have come up with a circuit which I think may work - however the calculation of the various values and the choices of components are beyond me, so could anyone answer the following questions please:

1. Would it work?
2. What would be the suggested values for R1, R2, R3, R4 and VR1
3. What are suitable common types/codes for TR1 and A

Click to view attachment

BTW - I have never heard of op-amp's before today - they sure look like useful little blighters! smile.gif

p.s. I just about understand the circuit other than why it has R3 and R4 - but all similar circuits I have seen appear to have them so I put them in unsure.gif

Cheers,

Roger
simonr
Your circuit would undoubtedly work with appropriate resistor values - although a single indication of rich/lean isn't going to be all that helpful when tuning. You need something to tell you when the output is in the middle. Perhaps you had intended to build three?

I would be more inclined to buy comparators than op-amps as they are more or less pre-packaged as the circuit you want. The LM339 is a reasonable choice. They give a logic high if one output is at a higher voltage than the other and low if not. Use a preset potentiometer connected between your power rails (or better still a voltage regulator) with the wiper connected to one comparator input and the lambda sensor to the other.

The LM339 has 4 comparators on board which you could set up to give you LED's for rich, lean and OK. The output will drive LED's directly through a 330R resistor.

Alternatively just use a digital volt meter and adjust the engine for 0.5v reading.

Is your sensor a 3 or 4 wire type with a built in heater? If not, you will need to heat it up for it to work reasonably. Just poking it up the exhaust pipe is unlikely to get it hot enough!

To partially answer your actual question:
R1 & VR1 form a voltage divider and deliver a variable voltage to the - input of the amp. This is a voltage reference which the amplifier uses as it's zero point. It amplifies any difference from that voltage.

R2,3 & 4 set the gain of the amp (the 'Volume').

The output of an amp is actually a current which is proportional to the input. R3 & R4 turn that current into a measurable voltage. R4 is to insulate the amplifier from whatever you connect to it. Otherwise, the resistance of what you connect to the output will affect the gain.

Si
ThreeSheds
Simon,
Many thanks for the detailed and informative answer - there's a load more to think about now smile.gif - I never thought it would be easy though!

Please bear in mind I have no experience of electronics and all of what follows is from what I have read on the internet this morning blink.gif Oh and I have no
experience of lambdas either, is it really possible to manually tune the mixture so that it is balanced between it's two extreme outputs?

QUOTE (simonr @ Aug 2 2008, 11:12 AM) *
Your circuit would undoubtedly work with appropriate resistor values - although a single indication of rich/lean isn't going to be all that helpful when tuning. You need something to tell you when the output is in the middle. Perhaps you had intended to build three?

No... Only one: The lambda sensor that I have is a 'narrow band' Zirconia device which are (apparently) extremely difficult to 'balance'. Apparently (again) ECUs normally just repeatedly apply the logic: If it's rich - lean it off, if it's lean - richen it. (I guess it is implied that "if it's balanced, look again and it won't be" smile.gif ) So I thought I can have the output from the circuit controlling a two way relay so that either one of two LEDs would light up and I could manually follow the same logic as above until it's flicking close enough.

QUOTE (simonr @ Aug 2 2008, 11:12 AM) *
I would be more inclined to buy comparators than op-amps as they are more or less pre-packaged as the circuit you want. The LM339 is a reasonable choice. They give a logic high if one output is at a higher voltage than the other and low if not. Use a preset potentiometer connected between your power rails (or better still a voltage regulator) with the wiper connected to one comparator input and the lambda sensor to the other.

The LM339 has 4 comparators on board which you could set up to give you LED's for rich, lean and OK. The output will drive LED's directly through a 330R resistor.

Right - I am with that. (BTW, aren't these things cheap! )

So I would preset the pot (note the use of jargon already wink.gif ) to give the switchover voltage required (.5v as you said) and the output of that comparator would go on/off as the lambda voltage transited the reference voltage. And also if I then set up another comparator in the LM339 wired to the lambda and the pot-wiper, but the other way round to the first, then the output of that one would be the inverse of the first and I have what I wanted - with no need of a relay or assembling all of those other bits - GREAT biggrin.gif

Oh - one bit I don't get is "drive LED's directly through a 330R resistor." do you mean this:
CODE

Comp-Out---/\/\/\---(LED)---gnd
R1
330ohm

EDIT: Sorted this now - I found a really useful little LED Resistor calculator and explanation.


QUOTE (simonr @ Aug 2 2008, 11:12 AM) *
Alternatively just use a digital volt meter and adjust the engine for 0.5v reading.

That was my first thought - but then why keep it simple when I can complicate things and learn something along the way !)

QUOTE (simonr @ Aug 2 2008, 11:12 AM) *
Is your sensor a 3 or 4 wire type with a built in heater? If not, you will need to heat it up for it to work reasonably. Just poking it up the exhaust pipe is unlikely to get it hot enough!
It's a four wire and if I build the circuit then I will mount it in the correct area - near the header - and have the LEDs where they can be seen as a bit of bling. Initially though, I was intending just wiring the lambda to my Fluke and sticking it up me pipe... I was wondering if (even with the heater) it would work there, but it wouldn't cost anything to try.

QUOTE (simonr @ Aug 2 2008, 11:12 AM) *
To partially answer your actual question:
R1 & VR1 form a voltage divider and deliver a variable voltage to the - input of the amp. This is a voltage reference which the amplifier uses as it's zero point. It amplifies any difference from that voltage.

R2,3 & 4 set the gain of the amp (the 'Volume').

The output of an amp is actually a current which is proportional to the input. R3 & R4 turn that current into a measurable voltage. R4 is to insulate the amplifier from whatever you connect to it. Otherwise, the resistance of what you connect to the output will affect the gain.

Si

Brilliant! Thanks for that. Simple when you know eh?

I think (since rain has stopped any other sort of play) I will shoot over to Maplins now and get the bits. Ill let you know how I get on.

Rog
A Twig
Yep, I'd agree with all the above, although using an op-amp ladder is quite a bulky way of doing it? From the component Si has suggested, to get your "bling" LED rack you'll need to have essentially that circuit you've drawn four times?

Personally I'm a big fan of PICs (programmable ICs) and you can easily and fairly cheaply buy a beginner set with an analogue input on the PIC. You then write a program (in the appropriate code if you can, if not most offer a simple flow-chart option). That will do all your comparing for the lights in one IC?

I'm not sure if you're planing to drive anything else from your 12V output. Even if you are, you'd then only need one op-amp/comparator to provide enough current. Most pics can handle driving LEDs straight from the output pins.

The best thing with a PIC is if you decide to add to it, you just take it out, re-program it, and put it back in. Depending on the spec of the PIC you will be able to get more accurate readings as well. biggrin.gif
ThreeSheds
QUOTE (A Twig @ Aug 2 2008, 06:31 PM) *
Yep, I'd agree with all the above, although using an op-amp ladder is quite a bulky way of doing it? From the component Si has suggested, to get your "bling" LED rack you'll need to have essentially that circuit you've drawn four times?

Personally I'm a big fan of PICs <cut&shut>

Hmm - something else to consider! This PIC stuff sounds interesting - can you suggest a decent introductory site? If not then I am sure that Wiki will have something smile.gif

Well I made my interpretation of Simon's suggestion and it doesn't work sad.gif It should have lit up green with 0v on the yellow wire and turn to red at about 0.5v, but it stays off nomatter what I put on the yellow wire.
Click to view attachment
Unfortunately I am suffering from too much brain fade to investigate at the moment blink.gif - I will try to work it out tomorrow.

It's been a big day...

Rog

FridgeFreezer
I'd use an LM3914 which will give you a 10-LED bar graph, use two preset pots to set it to 0-1v range and you're away.

As you can see (this was the prototype) there's not a hell of a lot to it:


ThreeSheds
Thanks for that. smile.gif
Do you have a pic of it finished? I had a look on the internet for a LM3914 and it does exactly what I (we?) need, apparently without much else - think I'll have a go at one of these next since my current design doesn't work.
Today was a nice day, so I was working outside. It may be a while before I try again since it's not exactly a critical path job...

Roger
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.