Hi guys!

How’s the summer going?Here in Italy is terribly HOT (today +35) and, as usual for me, I don’t care to sweat liters close to the welding station 🙂

Today I discovered a tmp102 temperature sensor in the drawer.I both it a long time ago on Sparkfun with its breakout pcb for something like 5€.So why don’t build a digital thermometer with a 7-segment like interface?

The main requirement for this project is: Don’t buy anything!At this point I’m poor and I can’t spend more money 😦

Ok…great!Let’s see what we need:

Sensor? OK

Protoboard? OK

Battery pack? OK

Voltage regulators? OK

MCU? i can use a pic18f2523 so… OK

Leds? uhc….if I want to make it with two leds per segment I must change color but….OK

Resistances? uhc again…I don’t have any more small values like 220 or 330 ohms.Well I can limit the current in some other way 🙂

In the end I came up with this schematic:

thermometer2

I’m using a digital potentiometer through spi in order to change the base current of the pnp.In this way depending on the number of segments turned on I can limit the current flowing through the leds.Remember that the leds, apart the colors, are all the same(same Vfwd and Iled)

The rest of the schematic has just some digital stuff.

2

1

The software handles the i2c and spi communication and enables the npn transistors depending on the number to represent.

There is a PWM like switching for the leds in order to reduce the power consumption without changing too much the brightness.

The worst case current consumption is about 12mA.This is pretty much considering the 4500-5000mAh of the battery package.

For this reason the leds are turned on for 4 seconds every 40 seconds or when there is a change in the temperature.A change of temperature is filtered by an hysteresis mechanism and the measurement is the average value of 20 measurements per second.

This time I don’t feel like publishing the source code.

3

Of course it could be better to have it in a container but I didn’t have anything to mod or money to spend for a new one.

Now the funny part…the test:

After some time it came back to the actual temperature: +32 degs!

Stay tuned!