Skip to main content
Visitor II
March 31, 2005
Question

Duty Cycle using PCA

  • March 31, 2005
  • 4 replies
  • 881 views
Posted on March 31, 2005 at 05:23

Duty Cycle using PCA

    This topic has been closed for replies.

    4 replies

    luigi2Author
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 12:06

    Hello,

    I would calculate a duty-cycle usig the programmable counter array but I have confused ideas can to indicate some example to me

    TKS

    luigi2Author
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 12:06

    The interrupt vector for uPsd33xx identifies all interrupt and it is declarer in ups3300.h however the pca interrupt is the number 11

    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 12:06

    hi,

    assumed that you consider ''all-high''=0% and ''all-low''=100% duty-cycle (''active-low''):

    duty-cycle = CAPCOM_value / (max_counter_value+1)

    if you consider ''all-low''=0% and ''all-high''=100% duty-cycle:

    duty-cycle = (max_counter_value+1 - CAPCOM_value) / (max_counter_value+1)

    where:

    max_counter_value+1 = 2^8 for 8-bit-PWM, 2^16 for 16-bit-PWM

    (see datasheet: the output is high when the PCA-counter equals or exceeds the CAPCOM-value)

    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 12:06

    I have the same problem,

    I'm new to the uPSD, I have a DK3300 board and I want to interface a 2-axis accelerometer with PWM output, so my need is to decode the PWM ratio coming from an external signal.

    My problem is the configuration for the interrupt vectors;I can configure the registers following the user manual, but where do I define the interrupt vectors for the PCA?

    thank you very much!

    :-[