This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Breakpoint & Memory window questions

1) I am just getting started with the Keil 8051 IDE. For now, I am running the Hello World ASM example and would like to configure a breakpoint to break on read/write to DPTR, or any other SFR as a matter of fact. I go under Debug menu, Breakpoints and enter DPTR under expression and check off READ & WRITE check boxes yet when I go to define the breakpoint I get the message "breakpoint definition error". What's the proper way to define a breakpoint on an SFR read/write in the KEIL IDE?

2) The SP => 69H in the Hello world asm example. When the example steps into a function, the SP increments by two storing the return address. Yet when I go to View, Memory window, memory address 69h & 70h contain 0. Why can't I see the return address in memory?

Parents
  • Thank you for your reply.

    However to make a statement that almost every instruction is working with the special function registers and making it sound like all the SFRs are being accessed all the time is stretching it quite a bit.
    I can see accessing ACC or PSW all the time but for example B or DPTR is used less frequently. Hence for example in source code that I just inherited the DPTR register is accessed 6 times in 10000 lines of code - definitely not being accessed all the time. Irrespective of frequency, it would be very useful to be able to trap a write to a specific SFR such as the DPTR when for example troubleshooting what piece of code inadvertantly changes it.

    I looked through chapter 2 of the assembler user's guide again and understand IDATA space. How do you display IDATA space in a window using uVision IDE? Going under View, Memory Window seems to display XDATA space. How do you change the Memory Window to IDATA space? I can't seem to find where to do this.

Reply
  • Thank you for your reply.

    However to make a statement that almost every instruction is working with the special function registers and making it sound like all the SFRs are being accessed all the time is stretching it quite a bit.
    I can see accessing ACC or PSW all the time but for example B or DPTR is used less frequently. Hence for example in source code that I just inherited the DPTR register is accessed 6 times in 10000 lines of code - definitely not being accessed all the time. Irrespective of frequency, it would be very useful to be able to trap a write to a specific SFR such as the DPTR when for example troubleshooting what piece of code inadvertantly changes it.

    I looked through chapter 2 of the assembler user's guide again and understand IDATA space. How do you display IDATA space in a window using uVision IDE? Going under View, Memory Window seems to display XDATA space. How do you change the Memory Window to IDATA space? I can't seem to find where to do this.

Children