I was beginning to wonder! :) Usually, replies here are fast and furious. >Assuming a Timer2 prescaler of 1:1, then the PWM frequency when PR2 = 255 >would be: >((Fosc/4) / (PR2+1)) or > 2,500,000 / 256 = 9,765.625 hz Ok, that's what I was hoping. I didn't want to have to mess with both registers to keep the freq the same. >With an xtal frequency of 10Mhz, your choices of PWM frequencys that will >still give you maximum 10-bit duty cycle resolution are: > >2,500,000 / 256 = 9,765.625 hz >2,500,000 / (256 * 4) = 2,441.40625 hz >2,500,000 / (256 * 16) = 610.3515625 hz The chip giveth, and the chip taketh away.. I definitely need to switch better than 9.7k, looks like 7 or even 6 bits is about the best I'll be seeing. Ok, well at least I understand the machine now. Thanks :) (Maybe the mfgrs should let us re-write their manuals for them!) -- Where's dave? http://www.findu.com/cgi-bin/find.cgi?kc6ete-9 -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]: PIC only [EE]: engineering [OT]: off topic [AD]: advertisements