Pages: [1]   Go Down
Author Topic: Uno Internal Temperature Sensor  (Read 1242 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 33
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Has anybody used or played with the on chip internal temperature sensor on the uno. There is reference to it in the 328 and tiny 48 data sheet (section 23.9) which gives some code to directly access the registers, but what about using it alongside the other analog pins on the arduino? If there is code around for doing both in the same sketch then I'm not looking in the right place and would be gratefull for any pointers?
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17294
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Has anybody used or played with the on chip internal temperature sensor on the uno. There is reference to it in the 328 and tiny 48 data sheet (section 23.9) which gives some code to directly access the registers, but what about using it alongside the other analog pins on the arduino? If there is code around for doing both in the same sketch then I'm not looking in the right place and would be gratefull for any pointers?

There have been postings on the use of the internal temp sensor from time to time, you just have to search a little. However in my opinion it's a pretty worthless (in my opinion) sensor as the chips internal temperature is going to be more effected by how much current the output pins are having to supply to their external circuitry. So maybe if you are not using any output pins, or they are supplying only minimum and steady value current, it's possible to utilize the sensor somehow. As I recall it requires quite a bit of calibration effort even then.

 So first question is what is it that you are expecting to be measuring with the sensor and what will you do with the information from it?

Lefty
Logged

Brunsbüttel, SH, F.Rep.GERM
Offline Offline
God Member
*****
Karma: 4
Posts: 596
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

So first question is what is it that you are expecting to be measuring with the sensor and what will you do with the information from it?
I like to use it for emergency shutdown:
when it is higher than 350K (or so) it pulls down the alarm line... smiley

here it showed up before (search words: internal temperature sensor):
http://arduino.cc/forum/index.php/topic,122103.0.html
Logged

-Arne

Global Moderator
Netherlands
Offline Offline
Shannon Member
*****
Karma: 217
Posts: 13739
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


I used it to get "random" bits from the internal heat source.

see - http://arduino.cc/forum/index.php/topic,38091.0.html -

Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

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

Hi,
I eventually found some of the reference code and the responces, thankyou, have pointed out a bit more. In my application its the temperature of the die that I'm after including the heating effects of sinking current on the digital pins!

When in use this particular 'box of magic' of a uno and ethernet shield inside will live in a pretty hot enviroment so I'm probably going to need to turn on a cooling fan or a peltier cell from time to time to stop it from getting cooked. Hence consistency is more important than absolute accuracy . I want to do this with out sacrificing any of the analog inputs to a separate temperature sensor. Trouble is those other inputs need an external Vref. I read that you cant turn on the internal reference voltage if an external one is connected. I suppose using an external reference 1.2V from a potential divider accross the 5V rail and ground will alter the maths a bit. Any body know if the internal reference is also just a potential divider?

Another of my projects, see separate post, has a tendancy to die unexpectedly. That is probably due to RF interferance but it could be  heat as well.
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17294
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
I eventually found some of the reference code and the responces, thankyou, have pointed out a bit more. In my application its the temperature of the die that I'm after including the heating effects of sinking current on the digital pins!

When in use this particular 'box of magic' of a uno and ethernet shield inside will live in a pretty hot enviroment so I'm probably going to need to turn on a cooling fan or a peltier cell from time to time to stop it from getting cooked. Hence consistency is more important than absolute accuracy . I want to do this with out sacrificing any of the analog inputs to a separate temperature sensor. Trouble is those other inputs need an external Vref. I read that you cant turn on the internal reference voltage if an external one is connected.
That is true. If you have any voltage wired to the Aref pin and have any of the internal reference voltages selected (Avcc and 1.1vdc for a Uno) then there will be a direct conduction path between that external Aref voltage and the internal voltage, never a good idea. A higher value series resistor on the Aref applied voltage can mitigate against possible damage perhaps per the second warning here: http://arduino.cc/en/Reference/AnalogReference

 I suppose using an external reference 1.2V from a potential divider accross the 5V rail and ground will alter the maths a bit. Any body know if the internal reference is also just a potential divider?

No, it's a fixed 'band-gap' voltage developed across an internal semiconductor, so it's accuracy is not effected by any variation of the applied Vcc or Avcc voltages.

Another of my projects, see separate post, has a tendancy to die unexpectedly. That is probably due to RF interferance but it could be  heat as well.
Logged

Nice, France
Offline Offline
Full Member
***
Karma: 11
Posts: 237
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another of my projects, see separate post, has a tendancy to die unexpectedly. That is probably due to RF interferance but it could be  heat as well.

Since you know which of your projects you are referring to, and we don't, taking a second to link to it would be a help to others reading the thread.
Logged

Offline Offline
Edison Member
*
Karma: 26
Posts: 1339
You do some programming to solve a problem, and some to solve it in a particular language. (CC2)
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

(OT): lefty, to quote-and-answer multiple times, just copy-n-paste the auto-added "quote" tag on top of the next paragraph, and add closing code tags by hand.
Logged

Pages: [1]   Go Up
Jump to: