Need help on a 3Hz PWM - Cypress.com Forums http://www.cypress.com/? Re: Need help on a 3Hz PWM http://www.cypress.com/?rID=46341 Hi Terrence,

"The CY8c29666 device is a PSoC 1 device, so your post belongs in the PSoC 1 forum."

Thanks for the heads up.

Also thanks for your help on 3Hz PWM. Another solution would be to use internal 32kHz as clock and use period as clock (32k) divided by 3, which results a period equals to 10666.

Thanks for your help.

Regards,

Douglas


]]>
Mon, 20 Sep 2010 09:01:54 -0600
Re: Need help on a 3Hz PWM http://www.cypress.com/?rID=46310 Hi Douglas,

The CY8c29666 device is a PSoC 1 device, so your post belongs in the PSoC 1 forum.

On to your problem...

Assuming a sysclock of 24Mhz, and a wanted PWM of 3Hz, would require a divisor of 24Mhz/3Hz = 8Mhz.

VC1 and VC2 can divide by 16 each, and VC3 by 256. So, 16x16x256 = 65536. (Hold that thought)

8Mhz/65536 = 122.0703125

So, using an 8bit PWM, with a period of 122 will give you the requested 3Hz output.

In Summary:

VC1 /16

VC2/16

VC3 source = VC2

VC3/256

----------------

PWM:

Clock = VC3

Period = 122

---------------

Hope this helps.

]]>
Fri, 17 Sep 2010 13:15:00 -0600