Skip to main content
Visitor II
December 17, 2003
Question

Noise output in PWM1

  • December 17, 2003
  • 2 replies
  • 617 views
Posted on December 17, 2003 at 11:31

Noise output in PWM1

    This topic has been closed for replies.

    2 replies

    rbudman2Author
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 11:57

    Hello,

    I'm using both PWM0 and PWM1 at the same time.

    PWM0 is working correctly and smooth, however PWM1 that has

    the same configuration as the first PWM is not stable in the period time, i.e. the gap between the pulses. most of the time, every 4th cycle the pulse raise 1ms earlier, other times it can be in the next cycle, or 10th cycle. What should I do?

    I understand that PSCL0H and PSCL0L configure the prescaler0, that corespond to PWM0, but it also controls PWM1. how is that? and what is the second prescaler used? for PWM4?

    PWMCON is set as 0xAF.

    Ron.
    rbudman2Author
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 11:57

    To Modurator,

    Thanks but I already figured it out, the PWM1 was anded with

    down_counter signal, to enlarge the period time, but it made problems.

    also I undrstood that the prescaler0 controls PWM0-PWM3.

    Thanks.