You don't have enough resolution to get a decimal point with your current setup. Can you change your reference voltage to something like 2V, this would give a reading around 125 for 25°C. Depending on which pic you are using you may be able to use the internal voltage reference to do this. With this setup you could simply multiply by 2 and convert to decimal - the decimal point would be placed before the last digit.
Why don't you go whole hog:
25C=250 steps
50C=500 steps
100C=1000 steps
Then there is no math to do and the increment will look natural. Just place the decimal point and display!
Use an OpAmp to scale the input if Vref can't go low enough.
The 877 has an internal voltage reference that can be outputted on AN2, this could be connected to AN3 to use as a reference for the ADC. However, as this is just a resistive divider you may as well use a couple of resistors (put a cap across the bottom one to smooth it a little). Your accuracy will only be as good as your supply but the LM35 is only accurate to 0.5° anyway. Alternatively, a resistor/zener type reference with a pot across the zener for adjustment would be more accurate. As mentioned by kchriste, the most accurate solution would be an opamp.
You use an OpAmp.
What's so bad about OpAmps? It will allow you to scale the voltage to take advantage of the full dynamic range of the ADC and add a calibration POT so you can adjust the accuracy of your thermometer.
It is a pig. The expression "go whole hog" means that you commit fully and do the full job without cutting corners. Probably comes from the days when the man brought home the bacon and cooked the "whole hog" on a spit over the fire. The meat would spoil, without refrigeration, if you didn't cook and eat it right away so there was no point in cooking half a hog.
A hog:
hi Suraj,
As you are using a LM35, use a simple opa, so that 5.12Vout gives 1023 adc value.
Use the PIC's internal +5Vref
When you convert this value to ascii for the display, just insert a 'dp' between the two lsd's
This will give a temperature range of +2C thru +100.0C with a 0.1Cdeg resolution.
As the LM35 give a +10mV change per Cdeg, at 102.3Cdeg its 1.023Vout.
A simple NI opa with again of approx 5 will raise this to 5.12V
If you only need to go as high as 60Cdeg, the opa can be powered from +5V,
for the full 102.3C the opa needs at least 9V on the power rail.
Do you follow OK.?
This is the method I use with a CA3140 opa, [goes close 0Vout]
Eric's diagram shows what I had in mind. If you can't find the CA3140 then the TS912 or any other rail-to-rail OpAmp which works with a 5V supply will do. Make sure the OpAmp you choose has both rail-to-rail inputs AND outputs. The pin out will be different from the CA3140.
Whilst the opamp solution with give the greatest range of readings on the ADC it may not be the most accurate solution. The accuracy will be dependent on the stability of the 5V supply as this is what the ADC uses as its reference voltage. Using an accurate 2V reference will be more stable and supply independent but will only have half the resolution - 0.2°C. A combination of opamp and an accurate voltage reference would be the most accurate, however it's pretty academic as the LM35 is only accurate to 0.5°C.