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 support@ccsinfo.com

Multiple Frequency PWM's

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







Multiple Frequency PWM's
PostPosted: Wed Jul 20, 2005 2:31 pm     Reply with quote

With respect to the PIC18Fxx2x data sheet "CCP and TIMER interconnect Configurations". I am wondering how to program 2 independent PWMs WITH 2 independent frequencies and pulse widths and I still need a timer with a 16bit prescaler left over. How do I specify which configuration I need in CCS?
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Wed Jul 20, 2005 2:50 pm     Reply with quote

What's the exact part number of your PIC ?
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Wed Jul 20, 2005 6:02 pm     Reply with quote

You can also use the CCP module in compare mode to generate the PWMs. You just alternate between a low time and a high time or with enough CCP's you can use one to turn on and another to turn off.
ccooper



Joined: 21 Jul 2005
Posts: 1

View user's profile Send private message

PostPosted: Thu Jul 21, 2005 6:45 am     Reply with quote

I am using a PIC18F6621, but they all look about alike except some have only CCP and some are both CCP & ECCP. This CCP Module and Timer resouces figure is so confusing. These PICs have PR2 and PR4, but can you use both with seperate CCP (or ECCP if you have them) modules at the same to operate at different freqencies? Does "or" in the Timer resource table mean "xor" or "and/or" ? Even if I get the Microchip business straight - How do I allocate specifice timer resources for a particular individual CCP's in CCS?
Also is there a ap note that deals with using CCP's w/o PWM to generate PWM? I can dig into the Capture and Compare, but it would save time if I could see it first. Thanks
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