This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Debug Server Scripting



Hello,

I am writing scripts using debug server scripting (DSS) on Eclipse IDE. I have ezDSP 28335 board & I am using Code composer version 4.2.4.00033 .

1) Since I have the access to the symbols for all global variables, I know how to access the global variables through DSS (I am doing this using debugSession.symbol.getAddress() & debugSession.memory.readWord() APIs).  However, I did not come across any API to access local variables using DSS. Is there any facility available in DSS to access local variables.

2) Is there any API to place "Hardware Watchpoint" in DSS?

Thank you!!

Bhavin


  • Hi Bhavin,

    Bhavinkumar Parmar said:
    1) Since I have the access to the symbols for all global variables, I know how to access the global variables through DSS (I am doing this using debugSession.symbol.getAddress() & debugSession.memory.readWord() APIs).  However, I did not come across any API to access local variables using DSS. Is there any facility available in DSS to access local variables.

    Accessing local variables by name via DSS is the same as if you were debugging via CCS. If the local variables are in scope, you can access them. You would use the same APIs you used for globals for locals too. Just make sure when you call symbol.getAddress(), the local variable is in scope.

    Bhavinkumar Parmar said:
    2) Is there any API to place "Hardware Watchpoint" in DSS?

    Yes. It is a little complex though. You need to create a breakpoint property object with the correct parameters. See the below wiki topic for more details:

    http://processors.wiki.ti.com/index.php/Breakpoint

    See the section on DSS.

    Thanks

    ki

  • Hi,

    I tried to access the local variables using DSS using debugSession.symbol.getAddress(). I got an exception from this statement saying that it cannot find the address. Then I tried debugging the issue using CCS. I found that the the values of the local variables are stored in CPU registers. If I have 5 local variables in a function, it uses 5 different CPU registers to perform write operation. The value of the local variables is stored in random CPU registers (e.g var1-->AR1, var2-->AR6 etc), it's not in sequence. So, my question is how do i know which CPU register do i need to read the value from for accessing a local variable.

    Do you have any other suggestion on accessing a local variable?

    Thank you,

    Bhavin