Electronics LED colour dependant on voltage (temperature sensor)?

Discussion in 'Modding' started by Ending Credits, 27 Sep 2008.

1. Ending CreditsBunned

Joined:
4 Jan 2008
Posts:
5,322
245
For my GCSE electronics coursework I want to make a bar of LEDs change from Blue to Red dependant on the temperature using a thermistor. Obviously some Dual colour LEDs are in order here but I don't know how to fade the colours from one to the other dependant on voltage.

I seem to remember this being done before here (a tap temp sensor) but I can't find it.

Thanks!

2. TAKTAKI R Pandi

Joined:
2 Jul 2008
Posts:
29
0
bi-colour LEDs just depend on which direction the current is flowing.

so all you would need is a circuit that changed the current flow direction when a certain temperature is reached ( when the thermistor reaches a certain resistance) to do that the easiest way is probably by using a potential divider connecting into a comparator...

3. Ending CreditsBunned

Joined:
4 Jan 2008
Posts:
5,322
245
I was thinking tri colour with a continuous transition from one color to another.

Joined:
22 Apr 2008
Posts:
553
42
5. jakenbakefull duplex

Joined:
5 Jun 2005
Posts:
495
3
eh, there has to be a sweet analog way to do this.

something like the thermistor sensor driving the base current of a transistor.

or a current to voltage converter to drive a mosfet, using the mosfet as a resistor in the linear region.

if you use a bicolor, a resistor would have to increase the base current or gate voltage at the same rate that the other resistor decreases, making them fade in and out equally.

6. cpemmaEcky thump

Joined:
27 Nov 2001
Posts:
12,328
55
With a bicolor you can use PWM, with the output sinking & sourcing. Not too dissimilar to a logic probe.

A 555, or maybe LM324

7. Ending CreditsBunned

Joined:
4 Jan 2008
Posts:
5,322
245
Is there a 555 circuit which can variate high time versus low time to any ratio including where it's high for longer than it is low? (Poorly phrased but I can't think how else to write it)

I cound wire the LEDs different way rounds so that one diode is off when it's high and one is on and vice versa for low eliminating the need for two transistors.

EDIT: would this be a good circuit to use (minus the stuff past the transistor)?

EDIT: I presume the ratio is controlled by the second potentiometer which could be replaced by a mosfet?

Last edited: 28 Sep 2008
8. SalgatWhat's a Dremel?

Joined:
30 Sep 2008
Posts:
2
0
If you're willing to go to the microcontroller route, a single micro can cover an unlimited number of colors using Pulse width modulation (along with preprogrammed color routines). Combine that with a Analog-to-Digital Converter and you have your whole setup done with one 20 pin micro, a 3 lead temperature sensor, and a couple of transistors/resistors.

9. mcg1seanWhat's a Dremel?

Joined:
5 Apr 2006
Posts:
56
0
The easiest way that I can think of doing what you want is to use an Arduino micro-controller. Basically its a prototyping micro-controller that has a USB-Serial connection, 8 analog inputs, and 13 outputs (mix of analog and digital supporting PWM). All you need is a temperature sensor plugged into the analog in and your LED's plugged into the outputs. Then you just need to tell it what you want to do which involves some programming in C but its all very easy. All of the supported syntax for the special Arduino C library are on the Arduino site (arduino.cc).

Joined:
4 Jan 2008
Posts:
5,322