----- Original Message ----- From: "Jamie Jensen" To: Sent: Thursday, April 22, 2004 11:30 AM Subject: [PIC:] How fast can the B0 interupt occur > Pondering.....how fast of a signal can cause the B0 interupt to occur. I assume, as fast as you can enter the ISR, process the code for the interupt, clear the bit and return....you can enter it again. Yes > I also assume, if you clear the bit first thing, and another interupt occurs while processing the ISR, it will force you right back to the ISR as soon as you return. Yes To understand what is going on under the hood: Remember the INT signal is edge triggered. Basically the B0 pin is connected (possibly thru an inverter depending on which edge you are interested in) to the clock input of a D flip-flop. The D input is connected to a constant HI signal. The Q output of the flip-flop is the INTF interrupt flag. Clearing INTF actually resets the flip-flop. This means that any (positive/negative) edge that occurs after you clear INTF will result in setting INTF again. Things are somewhat complicated by a stage or two of logic that synchronizes the B0 input with the system clock to avoid metastable conditions, but this can generally be ignored. Bob Ammerman RAm Systems -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics