CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

temperature alert with LM335 sensor + pic 16F877A

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
lordmag



Joined: 09 Nov 2010
Posts: 1
Location: TN

View user's profile Send private message

temperature alert with LM335 sensor + pic 16F877A
PostPosted: Tue Nov 09, 2010 5:28 pm     Reply with quote

hi ,
My project is to make a temperature alert with pic 16f877A.

I'm using the LM335 sensor to detect the temperature this is the datasheet.

The input is RA2/AN2 so I should make the ADC and the code that make the RED LED which is the output RB3 on when the temperature reach 60 °c
notice that this sensor range is between (-50 ° 125 °).

The temperature sensor's voltage output is related to absolute temperature by the following equation: Vout = VoutT0 * T / T0, where T0 is the known reference temperature where VoutT0 was measured. The nominal VoutT0 is equal to T0 * 10 mV/K. So, at 25 C, VoutT0 is nominally 298 K * 10 mV/K = 2.98 V

Without the ADC the RED LED is on when the Vout=2,5v T= -23°c
so help me please to do that analog digital conversation to make the RED LED on when T reach 60°c = 333 k when Vout >= 3,33V the input is RA2/AN2
The pic is 16F877A and I'm using CCS C compiler.
Thank you !!
ezflyr



Joined: 25 Oct 2010
Posts: 1019
Location: Tewksbury, MA

View user's profile Send private message

PostPosted: Wed Nov 10, 2010 11:07 am     Reply with quote

Hi,

This is an interesting project, and probably a good start for a beginner. You have to take some initiative, however, if you want to get some help from the members of the forum. I suggest that you show us a program that controls your LED, and reads the A/D converter. Your circuit should include a serial interface so that you can get real time feedback from your circuit to aid in troubleshooting even if you don't need it in the final version of your project.

There are literally hundreds of serial interface, LED control, and A/D reading examples on the forum. Show us what you've got and we'll happily jump in to help!

John
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group