Content-Type: text/plain X-MIME-Autoconverted: from 8bit to quoted-printable by saule.edi.lv id QAA17216 Try this...... Maybe it is what U are looking for? Manuel Castro Caama–o wrote: > Hi piclisters! > I have a 'titanic' problem with my program, i made it with several > (sub)routines wich i put in bank 2 and bank 3. The Interrupt Service Routine > is at 0x04 and main program code comes from ORG 0x25 to 0x180 aprox. > > Routines can be called from main program and from other routines, and pic > (16f84) can't work well, because i don't know how PCLATH must be set after > execution of the subroutine. > > Does anyone solve this problem? > > Investimento e Investigacisn Industrial, S.L. > Av. Galicia 51-53 > 32300 Barco de Valdeorras (Orense) > Spain > TLF. : (+34)(9) 88 327370 > FAX : (+34)(9) 88 327338 > E-MAIL: manuel.castro@mx3.redestb.es ;--------------/ CGRAM TABLE SETS (FONTS#1) /-------------------- ;DISP_FONTT_SIZE SET .67 ;TABLE SIZE IN BYTES ;DISP_FONTT_ORG SET (3FEh-.67) #IFDEF INC_DISP_FONTT ORG DISP_FONTT_ORG DISP_FONTT #IF ((($>>8)&0x01)!=0) ;SET PCLATH BITS BSF PCLATH,0 #ELSE BCF PCLATH,0 #ENDIF #IF ((($>>8)&0x02)!=0) BSF PCLATH,1 #ELSE BCF PCLATH,1 #ENDIF #IF ((($>>8)&0x04)!=0) BSF PCLATH,2 #ELSE BCF PCLATH,2 #ENDIF ADDWF PCL,1 ;MUST BE IN ADDRESS <(100h+SIZE) #INCLUDE "I:\P_LIB\INC\SYMB_A.CHR" #INCLUDE "I:\P_LIB\INC\SYMB_C.CHR" #INCLUDE "I:\P_LIB\INC\SYMB_E.CHR" #INCLUDE "I:\P_LIB\INC\SYMB_U.CHR" ;! #INCLUDE "I:\P_LIB\INC\SYMB_I.CHR" #INCLUDE "I:\P_LIB\INC\SYMB_K.CHR" #INCLUDE "I:\P_LIB\INC\SYMB_L.CHR" ;! #INCLUDE "I:\P_LIB\INC\SYMB_N.CHR" ;! #ENDIF