> > I am trying to have a variable be decremented and that result be used as > the BTFSC test bit > > For example > > movlw H'07' > movwf TestBit > decf TestBit, 1 > btfsc PORTB, TestBit > > Is this possible, Nope. > I tried using indirect referencing like > > movlw TestBit > movwf FSR > btfsc PORTB, INDF > > but that will not work. Any suggestions. There was a discussion of this a while ago on the list. The bit number for a btfsc instruction is fixed. Two possible ways of handling it. 1. Use a jump table to translate the bit number into a bit mask. Then use the mask to test the required bit (using and) then btfsc off the zero flag. 2. Build a jump table with 8 btfsc's and their associated no jumps in it. But you cannot perform the task they way you like unfortunately. BAJ