In SX Microcontrollers, SX/B Compiler and SX-Key Tool, Sparks-R-Fun wrote: Eric, It seems that what you are trying to attempt may be rather tricky. If your ISR was designed such that each and every time it was called it took exactly the same number of clock cycles to complete, then the solution might be as easy as adjusting the effective frequency passed to the compiler. The compiler would then make adjustments to the serout routine so that the internal timing would work out correctly. Unfortunately, your ISR seems to be capable of taking variable length paths based upon encoder information and that can not be completely predicted and taken into account. [b] Some Considerations[/b] 1) Given that 2400 baud is such a slow baud rate, have you confirmed that it is indeed the ISR that is causing your problem? If you disable interrupts, is data transmitted correctly? 2) Have you considered using a synchronous serial transfer like the one provided by the 'shiftout' command? Granted, it will require the use of one or two additional pins, but the advantage of a synchronous transfer is that the clock rate can vary a great deal without affecting the data being sent. Those are just some thoughts I had. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=148015#m148077 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)