On Sun, 1 Aug 2004 11:55:24 -0400, csblondin@SYMPATICO.CA wrote: > Though having an interrupt happening between the set GIE and RET would need quite a big piece of luck! Errr - not really! If PICs work the way of other micros I've used (and I'm open to being corrected here), the GIE only masks the interrupt-causing event from being seen, it doesn't "stop it happening". So if an interrupt-causing event happened while GIE was clear, as soon as you set it the interrupt will occur. Consequently there's a really good chance of it happening just when you don't want it, which is why the RETFIE sets GIE "after" the return. Enabling an interrupt too early is a classic "trap for the unwary" :-) Cheers, Howard Winter St.Albans, England -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.