This is part of a too-elaborate "super-assembler" I've developed, which I hope to post on the Web soon. I use a 16C76 or '77 because of the "bankless ROM" feature, a good location for TempW. This works on MPLAB 3.99. ;*************************************************************************** *** GoSub MACRO Subrtn ;Perform a "call subroutine" anywhere in memory. ;Note: W is preserved, so GoSub behaves just like a call. ;*************************************************************************** *** movwf TempW movlw HIGH Subrtn movwf PCLATH movfw TempW call Subrtn movwf TempW movlw HIGH $ movwf PCLATH movfw TempW ENDM > ---------- > From: White Horse Design[SMTP:whd@ZETNET.CO.UK] > Reply To: pic microcontroller discussion list > Sent: Friday, December 04, 1998 5:58 AM > To: PICLIST@MITVMA.MIT.EDU > Subject: PIC page seleclt macros > > Has anyone written a simple macro to call subroutines across page > boundaries? > > e.g. > > pcall func_in_page0 > pcall func_in_page1 > > ??? > > Regards > > Adrian > --- > WWW WWW Adrian Gothard > WWW WW WWW White Horse Design > WWWWWWWWWW +44-385-970009 (Mobile/SMS), +44-118-962-8913/4 (voice/fax) > WWWW WWWW whd@zetnet.co.uk, http://www.users.zetnet.co.uk/whd > --- > Developers of GPS satellite-based tracking systems for > vehicles/helicopters >