In the original design of a timer RA4 is used as an output pin. The condition of the pin is set with BSF PORTA,OUTPUT or BCF PORTA,OUTPUT. OUTPUT being defined as D'4'. Bank selection unknown.
Since PORTA has it's own unique adress 05h i do not understand why the status does not change. Although not understanding I experimented and selected Bank1 prior to changeing the status of RA4 and that works.
I can leave it that way. But i dont like the change if I do not understand why.
Some enlightment is required.
; Not working without bank1 BSF PORTA, OUTPUT or BCF PORTA, OUTPUT ; working BSF STATUS,RP0 ; Bank1 BSF PORTA,OUTPUT or BCF PORTA, OUTPUT BCF STATUS,RPO ; Bank0
From the datasheet PORTA is in Bank0 and not in Bank1 then why the selection of bank1 is working?
Not knowing the actual bank I could have saved the current STATUS but intend to do that when cleaning up after understanding.
Edit after comment. CMCON is set to 0x7.