In SX Microcontrollers, SX/B Compiler and SX-Key Tool, bean wrote: Joe, I'm away for the weekend. I'll try your code when I get back. I would just use Timer1 in PWM mode, and you'll need to clear Timer2 (I think that is why the long initial delay). You can use the new TIMER commands too. OUTPUT RB.6 TIMER1 PWM, 32768, 65535 T2CNTA = %00000100 ' Enable compare interrupts for Timer2 TIMER2 EXTERNAL TIMER2 R1, $08F0 TIMER2 CLEAR And all your should have to do in the interrupt is maybe "TIMER2 CLEAR". You don't need to reset R1. Bean. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=138101#m139041 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2006 (http://www.dotNetBB.com)