Andy David wrote: > > Scott, > > [discussion about generating PWM on a 12c508 snipped] > > > > > I wrote one this weekend that I can e-mail to those who want it. > > Salient features are: 3-bytes of RAM, 64-bytes of ROM, and 14 free > > cycles out of the 32 available for other things. > > > > how about posting your code to the list Here, I threw it out onto a web page: http://interstice.com/~sdattalo/technical/software/pic/pwm.txt I don't (yet) have a very convenient way to dynamically vary the pulse width. So currently, the program initializes a state machine for a given pulse width and loops indefinitely. Also, I've only tested the software with MPLAB. (The stopwatch feature proved invaluable.) Scott