One way to use PIC hardware to get a jitter-free slow PWM is to use the Compare function of the CCP module. It will set the CCP pin to low or high when the CCP register matches Timer1, and trigger an interrupt. In that interrupt you reload the CCP register and change the mode (to toggle the CCP pin in the other direction this time). This is not less software effort than doing it all "by hand" in a timer interrupt, but it is jitter-free because the actual pin control is done by hardware at the timer match. Gerhard > Thanks for the suggestions. I wound up just doing it in software with (as > usual) a crude hack that works pretty well. It was way less painful than I > thought it would be, actually! Is there a reason Microchip doesn't make > this a little easier? It seems it would be a fairly common task at least. >>> Are there any clever tricks that can slow it down to about a 17ms >> >> No, I don't think so, you'll probably have to use the timer(s) or s/w. -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body