I have some code written in the JAL language (simplified a little with = basic) which i would like to have some help converting to assembler i = have some ideas but i cant seem to realize them with the assembler that = i know and Easy PIC'n doesnt provide much information about making "if - = then - else" statements with variables. Maybe the answer lies within = the logic operators ?=20 var byte a =3D 0 var byte b =3D 0=20 if pin_a4 =3D=3D high then=20 if b =3D=3D 0 then a =3D a + 1 end if=20 if b =3D=3D 1 then a =3D a - 1 end if=20 if a =3D=3D 8 then b =3D 1 end if=20 if a =3D=3D b then b =3D 0 end if=20 if a =3D=3D 1 then goto "subroutine 1" if a =3D=3D 2 then goto "subroutine 2" ... if a =3D=3D 8 then goto "subroutine 8" end if=20 What happens is that the variable "a" can vary from 1 to 8 changes = eighter +1 untill it reaches 8 then it goes -1 back to 1 and +1 to 8 again ....=20 "a" is eithter increased or decreased by setting pin RA4 high with in the change procedure "a" calls a subroutine which matches "a" = current number Hope that someone will enlighten me on this. Best regards and thanks for reading !=20 Lasse Madsen -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.