----- Richard Gray wrote: > I think this example puts the stack-pointer into HL, doesn't it?
> Sorry! (I just woke up, and there is no pepsi in the house...) But isn't this sort of a trick question??? You usually know exactly what the PC is at every point in your program! The stack pointer is the one that is a bit tricky to get at. Now if you really want to know what the SP was when it hit a breakpoint (IOW, which breakpoint did you hit?), then the standard way to do that on z80 is to use restart inst., and then look on top of stack. But I see that OP asked about "hardware debugger", and I suppose in that case you might just want to know where the program was executing currently, and my answer would then be "ask the hardware debugger that you built". I always use software debugger, myself. Randy
------------------------------------------------------------------------------
_______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user