Jump to content

Recommended Posts

Hi,

 

Reading the datasheet (PIC16F876), it appears the PWM controllers both use the same timer, timer 2.

 

Does this mean i cannot have 2 different PWM outputs at the same time?

 

I need 2 PWM outputs, at the same frequency, but with different duty cycles.

Link to post
Share on other sites

the duty cycle is set by CCPR1L and CCPR1H for pwm 1 and CCPR2L and CCPR2H for pwm 2. As far as I can see they operate independantly at the same frequency, though I have never run both, so I cant confirm it.

 

Hi,

 

Reading the datasheet (PIC16F876), it appears the PWM controllers both use the same timer, timer 2.

 

Does this mean i cannot have 2 different PWM outputs at the same time?

 

I need 2 PWM outputs, at the same frequency, but with different duty cycles.

Link to post
Share on other sites

TomF,

Any chance someone who is good with the simulator could confirm this? Im not too good with the sim as yet and will probably make a mistake!

The SB PIC16 simulator supports CCP1 and CCP2 - Capture and Compare 1 and 2, including:

Capture Mode

Compare Mode

PWM mode

 

This is stated in the user IDE user manual.

 

Regards

Dave

Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...