LM 393 switching soft

T

Terminal Crazy

Guest
Hi guys, hope someone can help.

I've got a LM393 on a 12v supply measuring a thermistor. I've got it
switching around the right temperature but have a grey area where the
output ramps up brightening the LED until it switches fully on.

How do i increase the feed back so the output switches from 0 to 1 ?

TIA

--
Mitch

terminal_crazy@sand-hill.freeserve.co.uk
www.sand-hill.freeserve.co.uk/terminal_crazy
 
On Thu, 04 Jun 2009 18:56:12 +0100, Terminal Crazy
<Terminal_Crazy@sand-hill.freeserve.co.uk> wrote:

Hi guys, hope someone can help.

I've got a LM393 on a 12v supply measuring a thermistor. I've got it
switching around the right temperature but have a grey area where the
output ramps up brightening the LED until it switches fully on.

How do i increase the feed back so the output switches from 0 to 1 ?
---
You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.

Got a schematic?

JF
 
In article <2c4g25124lebd9ghg61cnmjjd94kqc01c8@4ax.com>,
John Fields <jfields@austininstruments.com> wrote:
You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.
thanks

I'd tried feedback to the +ve side of the sensor(on the -ve input) .
Presumably feeding back to the +ve input would raise it towards the +ve
rail ?

Got a schematic?
I'll have a play with this first thanks.

--
Terminal_Crazy

Mitch - 1995 Z28 LT1 M6 terminal_crazy@sand-hill.freeserve.co.uk
Lancashire England http://www.sand-hill.freeserve.co.uk/terminal_crazy/
 
Terminal Crazy wrote:
How do i increase the feed back so the output switches from 0 to 1 ?
http://google.com/images?q=comparator+hysteresis
 
On Thu, 04 Jun 2009 19:47:27 +0100, Terminal Crazy
<Terminal_Crazy@sand-hill.freeserve.co.uk> wrote:

You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.
This is an op amp? A smidgen of positive feedback is what it takes.
Output of the amp to the + input (with very high value resistor)
actual value depends on resistors in the sensor and reference but
usually 100Ks to meg ohms.

Frequently a resistor in series with a pot to ground on the output
will be used to take a small voltage off the output and gives an
adjustable hysteresis to feed back to the non inverting input. Cheap
and dirty is a high value resistor from out to non-inverting.
--
 
John Fields wrote:

Terminal Crazy <Terminal_Crazy@sand-hill.freeserve.co.uk> wrote:

Hi guys, hope someone can help.

I've got a LM393 on a 12v supply measuring a thermistor. I've got it
switching around the right temperature but have a grey area where the
output ramps up brightening the LED until it switches fully on.

How do i increase the feed back so the output switches from 0 to 1 ?

---
You'll need to introduce some hysteresis
i.e. some small positive feedback.


by connecting a large-valued
resistor form the output to the + input.
Typically. Cs can help too.


Got a schematic?
Always a good place to start.

Graham


--
due to the hugely increased level of spam please make the obvious
adjustment to my email address
 
Terminal Crazy wrote:

John Fields <jfields@austininstruments.com> wrote:
You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.

I'd tried feedback to the +ve side of the sensor(on the -ve input) .
Presumably feeding back to the +ve input would raise it towards the +ve
rail ?
You need to know what you're doing to get it right, especially if this is to be a
volume manufactured item. 'Fiddling' with components is not the way. It's calculable
and you should understand exactly the effect you're introducing.

Graham

due to the hugely increased level of spam please make the obvious adjustment to my
email address
 
default wrote:

Terminal_Crazy@sand-hill.freeserve.co.uk> wrote:

You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.

This is an op amp?
No. An LM393 is a dual comparator

Graham

due to the hugely increased level of spam please make the obvious adjustment
to my email address
 
On Thu, 4 Jun 2009, Terminal Crazy wrote:

In article <2c4g25124lebd9ghg61cnmjjd94kqc01c8@4ax.com>,
John Fields <jfields@austininstruments.com> wrote:
You'll need to introduce some hysteresis by connecting a large-valued
resistor form the output to the + input.
thanks

I'd tried feedback to the +ve side of the sensor(on the -ve input) .
Presumably feeding back to the +ve input would raise it towards the +ve
rail ?

Feedback to the inverting input will change the gain of the comparator
from "infinite" to some finite value. That's not what you want.

This is about hysterisis, adding "snap" to the changeover of the
comparator. Hence some positive feedback, ie a resistor from the output
to the non-inverting input, means that when the input goes above the
value on the other input of the opamp (that other input sets the
level at which the comparator will switch) the comparator output will go
"high" and that resistor will add some voltage to the input. The
input thus sees more voltage than the incoming voltage, and thus
the comparator is "more" on.

Michael


Got a schematic?
I'll have a play with this first thanks.

--
Terminal_Crazy

Mitch - 1995 Z28 LT1 M6 terminal_crazy@sand-hill.freeserve.co.uk
Lancashire England http://www.sand-hill.freeserve.co.uk/terminal_crazy/
 
On Fri, 05 Jun 2009 10:51:16 +0100, Eeyore
<rabbitsfriendsandrelations@notcoldmail.com> wrote:

No. An LM393 is a dual comparator
Only real difference is the open collector out versus push-pull out ?
--
 
On Sat, 6 Jun 2009, default wrote:

On Fri, 05 Jun 2009 10:51:16 +0100, Eeyore
rabbitsfriendsandrelations@notcoldmail.com> wrote:

No. An LM393 is a dual comparator

Only real difference is the open collector out versus push-pull out ?
Maybe, it there may be some specific shaping of the circuitry to make
it better for comparator use.

Any op-amp can be used as a comparator, it is the same general
circuitry.

Michael
 
In article <2c4g25124lebd9ghg61cnmjjd94kqc01c8@4ax.com>, John Fields
<jfields@austininstruments.com> wrote:
Got a schematic?
I've had a play and read a bit more about them and got this layout now...

12v
____________________________________________________________
| | | |
| | | |
| / | |
| \ / _____________ |
| /10K \ | / |
| \ |\ /10k | \4K7|
| / 2 | \ \ | / |
| |-------------| - \ / | \ C|\
| | | \ | | /---B| | 2N3906
| / |LM393 \_|______| _ E|/
/ \ | / | _______|
\ /10K 3 | / | | |_______
/<----\----/\/\/\---| + / | / | |
\ / 47k | | / | 4K7 \ r / | d
/ | | |/ | / e \ _|_ i
| | | 470k | __\__ l / /_\ o
| | |-----\/\/\/\--| led \ / a \ | d
___|_____|______________________________________\_/______y_|___| e
0v

I've got hysteresis set at 12 / ( 470K / 47K) = 1.2V which appears ok for
now.

The relay doesn't buzz now around the switching point but
I'm still getting the LED to illuminate just before the relay energises,
any suggestion please.

TIA

--
Terminal_Crazy

Mitch - 1995 Z28 LT1 M6 terminal_crazy@sand-hill.freeserve.co.uk
Lancashire England http://www.sand-hill.freeserve.co.uk/terminal_crazy/
 
In article <506748aa22Terminal_Crazy@sand-
hill.freeserve.co.uk>, Terminal_Crazy@sand-
hill.freeserve.co.uk says...

[snip]

The relay doesn't buzz now around the switching point but
I'm still getting the LED to illuminate just before the relay energises,
any suggestion please.
Perhaps a capacitor in parallel with the LED?

That might delay the turn-on of the LED until
the relay engages. You'd have to experiment
with various values of cap, though...
 
Terminal Crazy wrote:
In article <2c4g25124lebd9ghg61cnmjjd94kqc01c8@4ax.com>, John Fields
jfields@austininstruments.com> wrote:
Got a schematic?

I've had a play and read a bit more about them and got this layout now...

12v
____________________________________________________________
| | | |
| | | |
| / | |
| \ / _____________ |
| /10K \ | / |
| \ |\ /10k | \4K7|
| / 2 | \ \ | / |
| |-------------| - \ / | \ C|\
| | | \ | | /---B| | 2N3906
| / |LM393 \_|______| _ E|/
/ \ | / | _______|
\ /10K 3 | / | | |_______
/<----\----/\/\/\---| + / | / | |
\ / 47k | | / | 4K7 \ r / | d
/ | | |/ | / e \ _|_ i
| | | 470k | __\__ l / /_\ o
| | |-----\/\/\/\--| led \ / a \ | d
___|_____|______________________________________\_/______y_|___| e
0v

I've got hysteresis set at 12 / ( 470K / 47K) = 1.2V which appears ok for
now.

The relay doesn't buzz now around the switching point but
I'm still getting the LED to illuminate just before the relay energises,
any suggestion please.

TIA
Are you really using and 2N3906? If so then you have it connected
incorrectly. The 2N3906 is a PNP transistor. You need to either:

1) Swap the collector and emitter connections so that the collector
is connected to the relay/LED and the emitter is connected to 12v.
A 1K resistor from the base to the 12v supply might also help ensure
the the transistor is turned off.

or:

2) Use a NPN transistor with your current circuit.

The 2N3906 might work (I have never tried it) in your current arrangement
but if so then it will work very poorly. The resulting very low gain from
using the transistor 'backwards' might explain the results that you are
seeing.


Dan
 
On Sat, 06 Jun 2009 19:33:10 +0100, Terminal Crazy
<Terminal_Crazy@sand-hill.freeserve.co.uk> wrote:

In article <2c4g25124lebd9ghg61cnmjjd94kqc01c8@4ax.com>, John Fields
jfields@austininstruments.com> wrote:
Got a schematic?

I've had a play and read a bit more about them and got this layout now...

12v
____________________________________________________________
| | | |
| | | |
| / | |
| \ / _____________ |
| /10K \ | / |
| \ |\ /10k | \4K7|
| / 2 | \ \ | / |
| |-------------| - \ / | \ C|\
| | | \ | | /---B| | 2N3906
| / |LM393 \_|______| _ E|/
/ \ | / | _______|
\ /10K 3 | / | | |_______
/<----\----/\/\/\---| + / | / | |
\ / 47k | | / | 4K7 \ r / | d
/ | | |/ | / e \ _|_ i
| | | 470k | __\__ l / /_\ o
| | |-----\/\/\/\--| led \ / a \ | d
___|_____|______________________________________\_/______y_|___| e
0v

I've got hysteresis set at 12 / ( 470K / 47K) = 1.2V which appears ok for
now.
---
It should be less than that; you forgot about the switch point adjust
pot.
---

The relay doesn't buzz now around the switching point but
I'm still getting the LED to illuminate just before the relay energises,
any suggestion please.
---
Probably the current required to get the relay to switch takes longer to
build up in the coil than the current required for you to see the LED
start to illuminate does.

Also:

1. You don't want to be using an emitter follower, you want to be using
a common emitter.

2. If you're using a PNP, like you show, you've got the emitter and
collector connections reversed and the diode really isn't doing
anything.

Try this:

+12V>--+-----+-------+--------+-----+-------+-[4K7]-+
| | | | | K| |A
| [10k] | [3k9] [COIL] [DIODE] [LED]
| | | | | | |
| | +---|--[1M]--+ +-------+-------+
| | | | | |
[POT]<--|---+--|+\ | C
| | | >------+---B 2N3904
| +------|-/ LM393 E
| | | |
| [10k] | |
| | | |
GND>---+-----+-------+--------------+---->GND

BTW, which 10k is the thermistor and how is the relay supposed to act
when the thermistor drives the voltage on the - input more negative than
the reference?

JF
 
On Sat, 06 Jun 2009 13:50:46 -0400, Michael Black wrote:

No. An LM393 is a dual comparator

Only real difference is the open collector out versus push-pull out ?

Maybe, it there may be some specific shaping of the circuitry to make
it better for comparator use.

Any op-amp can be used as a comparator, it is the same general
circuitry.
Some op-amps don't like being driven into saturation.
 
In article <sajl25h6v5to7ljbcd15lnv0s3i2pp57v7@4ax.com>, John Fields
<jfields@austininstruments.com> wrote:
. If you're using a PNP, like you show, you've got the emitter and
collector connections reversed and the diode really isn't doing
anything.

Try this:
thanks Dan & John.
I'm just measuring the thermister atm temp vs resistance.

The circuit was of the internet (one i've got stashed as notes) but didn't
really explain enough re feedback etc.

The transister pinout is now confusing.. also from the same set of
circuits.

The Phillips specsheet shows pinout as

TO-92
c | \
b | |
e | / but doesn't state view(ie above / below)

My Electronic catalogue shows it as
b | \
c | |
e | / Viewed from BELOW

Can anyone confirm orientation. I'll try it now with the 2N3904.

Thanks

--
Terminal_Crazy

Mitch - 1995 Z28 LT1 M6 terminal_crazy@sand-hill.freeserve.co.uk
Lancashire England http://www.sand-hill.freeserve.co.uk/terminal_crazy/
 
Michael Black wrote:

On Sat, 6 Jun 2009, default wrote:
Eeyore <rabbitsfriendsandrelations@notcoldmail.com> wrote:

No. An LM393 is a dual comparator

Only real difference is the open collector out versus push-pull out ?
Yes, many comparators including this one are open-collector. It tends to be
useful.


Maybe, it there may be some specific shaping of the circuitry to make
it better for comparator use.

Any op-amp can be used as a comparator, it is the same general
circuitry.
But usually much slower.

Graham
--
due to the hugely increased level of spam please make the obvious
adjustment to my email address
 
Nobody wrote:

On Sat, 06 Jun 2009 13:50:46 -0400, Michael Black wrote:

No. An LM393 is a dual comparator

Only real difference is the open collector out versus push-pull out ?

Maybe, it there may be some specific shaping of the circuitry to make
it better for comparator use.

Any op-amp can be used as a comparator, it is the same general
circuitry.

Some op-amps don't like being driven into saturation.
And indeed some can reverse their output if overdriven.

Graham

--
due to the hugely increased level of spam please make the obvious adjustment
to my email address
 
Terminal Crazy wrote:

The circuit was of the internet
There really is some utter rubbish out there.

Graham

due to the hugely increased level of spam please make the obvious adjustment to my
email address
 

Welcome to EDABoard.com

Sponsor

Back
Top