accessing program counter in 8051

Status
Not open for further replies.
There is no way to read the value of PC (internal Program Memory) ..
But, if you, for example, trigger an interrupt you can read (within interrupt routine) the very first two byes from the Stack - they will be PCH and PCL ..
This would be like asking: What address are you about to execute next (after returning from interrupt) ..

Regards,
IanP
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…