0

Temperature readings
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Temperature readings

by Felixe on Tue Sep 25, 2007 9:13 pm

Hi,

I have an Arduino Diecimilla board and I have been able to successfully program various examples. Now I'm into something a little bit more involved. This time I'm reading a temperature from a LM35 sensor. It works and I can read the data even on Hyperterminal. That's fine.

Now, I'm trying to write that value (obtained with the AnalogRead() function) to the digital outputs as a byte. The value is 10 bits long when read but dividing by 4 I can have it in a 8 bit range. The problem is that I'm not quite sure if I can do something like PORTD(byte(temp)). Is it possible? In the arduino.cc page I have found little info regarding this topic but I'm sure it can be done just don't know how.

Any info will be greatly appreciated and I could have a nice desktop thermometer gadget in my office 8)

Felixe

EDIT: forgot to add my main source of info: http://www.arduino.cc/playground/Learni ... nipulation
Felixe
 
Posts: 6
Joined: Fri Aug 31, 2007 6:06 pm
Location: Cholula, Pue., Mex.

by adafruit on Tue Sep 25, 2007 9:38 pm

at this time im not doing general arduino support
only starter kit/tutorial stuff
general purpose arduino questions should be posted to the arduino support forum, www.arduino.cc
thanks!

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm
Location: nyc

Please be positive and constructive with your questions and comments.