derrick826
New Member
Hi guys ,
i have a problem with interfacing the THERMO LM35 into PIC16F877. Basically i have already done a program to calculate the voltage converted in the PIC16F877 by using the internal ADC in to a temperature value. I have simulated my program in the PIC simulator IDE using the 7-segments LED ( common cathode) and it actually works. As the voltage value of the ADC changes due to the LM35 which converts the temperature to voltage value , it basically gives me the correct display on the 7-segment LEDS.
Based on the LM35 DZ data shee, + 10.0 mV/°C scale factor, i have calculated that let's say it's a temperature of 25 celcius , .....so the device itself will output about 0.25v which goes to the 10-bit ADC of the PIC that converts into a digital value of 51 in decimal. With that converted value , i have divided the 51 decimal by 2 to get back my temperature value which is approximately 25.5 celcius which will be displayed on the 3 7-segments leds.
i build the hardware as followed :
**broken link removed**
but it didn't give the expected display on the 3 7-segments LEDS. The displays didn't turn out to be numbers. Is my PIC program has something wrong or the hardware which i have build is wrong? hope you guys can give me a helping hand.. thanks
i have a problem with interfacing the THERMO LM35 into PIC16F877. Basically i have already done a program to calculate the voltage converted in the PIC16F877 by using the internal ADC in to a temperature value. I have simulated my program in the PIC simulator IDE using the 7-segments LED ( common cathode) and it actually works. As the voltage value of the ADC changes due to the LM35 which converts the temperature to voltage value , it basically gives me the correct display on the 7-segment LEDS.
Based on the LM35 DZ data shee, + 10.0 mV/°C scale factor, i have calculated that let's say it's a temperature of 25 celcius , .....so the device itself will output about 0.25v which goes to the 10-bit ADC of the PIC that converts into a digital value of 51 in decimal. With that converted value , i have divided the 51 decimal by 2 to get back my temperature value which is approximately 25.5 celcius which will be displayed on the 3 7-segments leds.
i build the hardware as followed :
**broken link removed**
but it didn't give the expected display on the 3 7-segments LEDS. The displays didn't turn out to be numbers. Is my PIC program has something wrong or the hardware which i have build is wrong? hope you guys can give me a helping hand.. thanks