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

PWM I2C ... Timer2 ??

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



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Fri Apr 03, 2009 3:38 pm     Reply with quote

Quote:
How can I activate and control the 3 channels : P1A, P1B and P1C ?

The 18F4525 has only 2 independent PWM channels. Each one can
have its own frequency and duty cycle.

One of the two channels is an ECCP channel. It can have up to 4 outputs
but they all run from the same PWM channel. They have the same
frequency, and the same duty cycle. The ECCP channel is intended
to drive a motor control circuit. It can be configured for Half-Bridge or
Full-Bridge mode.

With this PIC, you only have 2 independent, hardware PWM channels.
Do you understand this ?
jjacob



Joined: 08 Mar 2008
Posts: 54
Location: PORTUGAL (PORTO)

View user's profile Send private message

PostPosted: Sat Apr 04, 2009 4:35 am     Reply with quote

Unfortunately i understand ...

Quote:
The ECCP channel is intended to drive a motor control circuit.

With this sentence, I understand why they talk about bridge and half bridge in the datasheet.

I'll change the PIC to 18F4331, as mentioned in topic:
http://www.ccsinfo.com/forum/viewtopic.php?t=37206

If i use this PIC and similar code to the referred topic, then I can have 3 (or more) independent duty cycle PWM.

Thank you for your explanation.
I'm always learning in this forum Very Happy

Jacob
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