toftat@cowshed.us wrote: > I don't have a fancy in-circuit debugger, and I think the problems > lies with receiving serial data (which simulators seem to emulate > universally poorly) > > I want to use the WDT to "reign in" the wayward handler, and I'd like > to use a flag to indicate where it was. Will this flag be available > after the WDT reset? Yes, but there's no reason for the watchdog timer to expire and trigger the reset anywhere near the error in your code; the reset is likely to happen long after the error, so you may not get much information from it. If you have an oscilloscope (digital or analog storage preferred, but not absolutely required), you'd probably have more luck tracking the progress of the PIC by toggling I/O pins on and off at strategically- located points in the code. If you don't have a scope, Microchip's simulator -- although moderately painful to configure -- IS actually pretty good. Of course, if you're using the WDT to "fix" the problem rather than debug it, the coarse program-counter info you'd get from your method will probably be fine. -Andrew === Andrew Warren - fastfwd@ix.netcom.com -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist