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

Measuring A Frequency

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







Measuring A Frequency
PostPosted: Tue Aug 17, 2004 2:32 pm     Reply with quote

Hi folks, i need to know how i can read in a frequency.
So far, i know I will need to use the ccp function to read in a time period of my source (around 6khz), from then i can convert into a frequency...from which i will use to convert into a relative humidity percentage on my humidity sensor(hs1101)

--- knowing i can do the following to initialize my hardware.....

Code:
setup_ccp1(CCP_CAPTURE_RE);       ///capture rising edge
setup_timer_1 (T1_INTERNAL);


i am now stuck as to what is the simplest way to write code to read my signal ......

thanks for any help!
sargent
Guest







PostPosted: Fri Aug 20, 2004 12:41 pm     Reply with quote

any takers???

all ive read so far in books and online is that you can do it ... that it sounds so obvious to use the ccp as the easiest way to read a frequency .... i see no code for its implementation.... i see alot of things on compare and pwm mode but nothing on capture mode!
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Fri Aug 20, 2004 12:50 pm     Reply with quote

Do a search on the forum for Tachometer.
One of my old posts has links to tach projects which
include sample code.
sar



Joined: 08 Sep 2003
Posts: 36

View user's profile Send private message

Tachometer
PostPosted: Sat Aug 21, 2004 11:45 am     Reply with quote

This example here;

http://www.vermontficks.org/dtachc.htm
lubing



Joined: 05 May 2008
Posts: 1

View user's profile Send private message

Re: Tachometer
PostPosted: Fri May 09, 2008 8:54 pm     Reply with quote

sar wrote:
This example here;

http://www.vermontficks.org/dtachc.htm


why this address can't connect
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