maths of measuring temperature with the AdC

Discussion in 'Embedded Systems and Microcontrollers' started by clintonb, Feb 26, 2015.

  1. clintonb

    Thread Starter Active Member

    Mar 6, 2011
    42
    0
    I bought a temperature sensor that has a impedence of 5kohm. I connected it to the ADC0 pin and I got a result of 1024 with the ten bit value.

    I thought I had an issue with the ADC setup etc but this isn't the case because my voltmeter also shows 4.96V where the mcu is using the internal voltage reference.

    I connected the voltage out pin for temperature directly to ADC0 and one half of me tells me that the voltage reading should be 5V(thermometer input). How does one connect this to get a reading? Do I need a second resistor like I did when connecting the LED or having 2 equal resistors to cut voltage in half.
     
  2. ericgibbs

    AAC Fanatic!

    Jan 29, 2010
    2,503
    380
    hi,
    You need to make the sensor and a suitable value resistor into a 'voltage divider'
    The sensor can be at the top or bottom of the divider, depending on the sensor type.

    Do you have a datasheet or link for the sensor.?

    E
     
  3. shteii01

    AAC Fanatic!

    Feb 19, 2010
    3,387
    497
Loading...