Loading...
Pages: [1]   Go Down
Author Topic: TMP36 - Temperature Sensor drops over time  (Read 445 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I made a simple temperature readout using this:https://www.sparkfun.com/products/10988

I set it up so I could see a readout on my LCD of the current temp, highest recorded and lowest recorded. It starts off just fine, reading room temp right around 71 degrees, but over time the temperature readout trends lower and lower, eventually going down as low as 64/65 (Fahrenheit). If I restart the temperature starts out again and a more expected range. What are some reasons why this dropoff might occur?
« Last Edit: February 28, 2013, 03:34:50 pm by runningdude22 » Logged

Offline Offline
God Member
*****
Karma: 15
Posts: 967
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You have at least one bug in your code.

Pete
Logged

Johannesburg UTC+2
Offline Offline
Edison Member
*
Karma: 34
Posts: 1705
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
You have at least one bug in your code.

Or, the ambient temp was dropping.

Seriously, though, do you have another thermometer to check it against? How do you know it's misbehaving?
« Last Edit: February 24, 2013, 01:53:11 am by JimboZA » Logged

IT Crowd:
Roy... "Have you tried turning it off and on again?"
Moss.. "Have you tried forcing an unexpected reboot?"

Toledo, OH
Offline Offline
Sr. Member
****
Karma: 16
Posts: 410
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
You have at least one bug in your code.

Or, the ambient temp was dropping.

Seriously, though, do you have another thermometer to check it against? How do you know it's misbehaving?

If he restarts the temperature returns to a correct range.  Therefore, it's not that it's just getting colder.  An increase in temp could mean that the circuit is heating up.  But, it's getting colder so that's not it either.  It really does sound like a bug in the sketch.

Tim
Logged

Arduino Uno - Teensy 2.0 - Teensy 3.0 - Raspberry Pi Model B w/512MB RAM
My libraries: NewPing library - LCDBitmap library - toneAC library - NewTone library

Netherlands
Offline Offline
Tesla Member
***
Karma: 101
Posts: 9553
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
What are some reasons why this dropoff might occur?

If you do averaging with integer values you can get drifting values due to integer rounding.

Think it is time to post the code



Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Pittsburgh, PA, USA
Offline Offline
Faraday Member
**
Karma: 33
Posts: 3017
I only know some basic electricity....
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If the sensor is wired for too much impedance coming into the analog pin and too little resistance going to ground then that will happen too, especially if you do a lot of reads per second. Been there trying to sense very low currents.

Logged

Examples can be found at Learning in the Main Site and at the Playground

Sussex UK / CT USA
Offline Offline
Edison Member
*
Karma: 0
Posts: 1026
Forums forever
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

How long are the wires between sensor and Arduino? A few degrees drift is a VERY small difference in voltage. Maybe (exceeding my knowledge of physics here) some induced voltage is building up/ draining off?

Part of the reason I prefer to deal with the "little problems" that the 1-Wire sensors throw up... at least the signal, when you finally master getting it, is immune to such issues. Please, maybe, revise the subject of this thread to include "TMP36" in it?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The wires are 3 inches or so.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Might a voltage regulator on the power source help?
Logged

Pittsburgh, PA, USA
Offline Offline
Faraday Member
**
Karma: 33
Posts: 3017
I only know some basic electricity....
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You might watch the Arduino 5V with a meter first, assuming that's your power source.

What's powering the LCD? Do you have another Arduino with nothing attached you could try the sensor with and print to serial monitor instead of the LCD?

Logged

Examples can be found at Learning in the Main Site and at the Playground

Pages: [1]   Go Up
Print
 
Jump to: