In SX Microcontrollers, SX/B Compiler and SX-Key Tool, Chong wrote: Sorry, I wasn't very clear with my use of the term debug. I realize that I can't change input pin conditions in the debugger. I was bug tracing while running my program regularly. I placed commands to light LEDs at various program points with no instructions to clear the LED. That way when a point was reached, an LED was lit and left on so I didn't have to try to catch an LED flashing at MHz type frequencies. I was using the RA port to control LEDs and found that RB configured interrupts weren't triggering consistently with signal inputs which should have worked. I suspected that I got stuck in a loop somewhere and tried leaving LED test points througout my code and wasn't able to get a clear consistent picture as I wasn't able to follow the flashing lights quick enough. I then laid commands using 5 spare pins in the RB port which were config'd as outputs so I could trace the pin state in a high speed manner with a datalogger which would simultaneously monitor the 2x RB interrupt inputs and the 5x RB outputs so I could see where the program was running. When I made the changes, the program mysteriously started functioning correctly even though I hadn't put any instructions which should have affected program flow. I've gotten a bit further. I've commented out most of my code which was outputting bits for my datalogger. I found one command which mysteriously fixes things. It's at the end of my ISR. All it does is raise a RB pin config'd as an output. Wierd because it doesn't get cleared anywhere. Once it's set, it's never cleared again. All I can guess is that it makes the processer look at the RB port once more before RETI which resets the interrupt triggers somehow. I've attached code. Maybe I've found something new? ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=108128#m108131 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)