The call can only make a relative jump with a certain address range, it's only got a limited number of bits to store the jump value. It sounds like your "sub_one" is too far away. It cannot store the fit the required relative jump into the bits available in the assembly word. Try just putting the subroutine closer to the call to see if this works. I can't remember about the 12C509 but in the 16F84 you should load the PCLATH register with the high part of the address and then call the subroutine using the low address part. The PCLATH is like a PAGE selection Others will correct the detail here. Pete > -----Original Message----- > From: EXT Geoff Wootton [mailto:woottong@isdugp.bham.ac.uk] > Sent: Tuesday, July 11, 2000 1:22 PM > To: PICLIST@MITVMA.MIT.EDU > Subject: [PIC]: 12C509 calls and gotos > > > Hi, > > I've checked the archives and am having trouble sorting > this one out. When I try to build an asm file for a 12C509 > in MPLAB I get the error: > > jump not allowed at this address (must be in low half of page) > > This is in response to a call statement. I realise from the > documentation that I need to set bit 5 in the status register > but I still get the error message when I try this. The commands > I am using are: > > bsf status,5 > call sub_one > > I'd be grateful if anyone could help. > > Regards > > Geoff. > > -- > http://www.piclist.com hint: The PICList is archived three different > ways. See http://www.piclist.com/#archives for details. > -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.