> >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. This is correct. Even a MOVWF, as I understand it, does a read on the port before writing the new value. This isn't an issue when dealing with the pin-capacitance, back-to-back I/O, shadow register stuff. But it DOES mess up interrupt-on-change. Bob Ammerman RAm Systems (contract development of high performance, high function, low-level software) -- 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