Hi everyone. Sorry if this is a silly question. I have a subroutine called PULSE that oscilates one of the pins on the = 16F84. It does this by using BCF and BSF to set and clear that pins bit = on porta.. so basically there are some loops and instructions like=20 BCF PORTA,1 My question is: how can I modify my subroutine so that I can set which = pin to oscillate. I want to be able to do something like: movlw 1; load w with number of pin on porta to pulse call ping; oscillate pin 1 movlw 2;now load in new pin number call ping ; oscillate pin 2. How can I do this? Are instructions like BCF porta,w valid? I've tried = this and it doesn't seem to work.=20 Any suggestions much appreciated. sam. -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.