Well, It seems a speed problem. I'm using internal clock, and if I use RC4 as described, the program loose the ZZ switch, but if i lock the switch, it works ok.
It's possible that the use of PORTA.4 speed down the PIC?
The switch that fails is connected to PORTA.5 (MCLR pin), don't know if this is important.
Regards
Bookmarks