cancel
Showing results for 
Search instead for 
Did you mean: 

PCL, PCH

rob2
Associate
Posted on September 23, 2003 at 09:07

PCL, PCH

2 REPLIES 2
rob2
Associate
Posted on September 22, 2003 at 14:54

I am trying to get the entry point for a subroutine and store it in memory. My first try was to have the subroutine store the program counter upon its first entry (of course subtracting off for the load commands).

But, the assembler does not recognize PCL or PCH. In trying to put these into my include file, I cannot find the hardware addresses of the PC.

A) what are the hardware addresses of the PC?

B) is there an easier way of doing this (like having the linker place the address in a given ROM location)?

Thanks

simonharrison9
Associate II
Posted on September 23, 2003 at 09:07

Hi,

You can not directly access the PC.

When you declare a label, such as a routine label, that can be used as a value within your code - just the same as when you create a table.

Hope this helps - if not, please give more detail of how you wish to use this address?

Simon