>The read-modify-write operations are performed on the >shadow register where there are no problems with this, >then the new shadow register value is written (no read) to PORTB. Humm, I seem to recall a discussion through this list a while back on Interrupt on Change, and someone demonstrated that a write to a port fouls up the interrupt detection the same as a read/modify/write on the port. The write does actually do a dummy read apparently, even though the info it is writing is not what was read. I cannot remember just when the discussion was, you will need to search the archive - should not be hard with James' new search bot. -- 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