Keil Logo

GENERAL: CAN'T WATCH A, B, AND C VARIABLES IN DEBUGGER


Information in this article applies to:

  • dScope All Versions
  • µVision All Versions

QUESTION

I load my program into the debugger and try to watch the variables a, b, and c in my program. The watch window shows strange values that are not correct for my variables. What's going on?

ANSWER

By default, the debugger (dScope or µVision) uses the name a to reference the accumulator (in the 51 and 251), b to access the B register (in the 51 and 251) and c to access the carry bit (in the 51 and 251). To access the variables from your program named a, b, and c, use a back quote (') before the variable. For example:

ws 'a
ws 'b
ws 'c

adds watchpoints for your variables. Note that you must use the back quote for all variables that have the same name as any reserved symbols (like r0, r1, r2, ...) in the debugger.

Last Reviewed: Monday, June 7, 2004


Did this article provide the answer you needed?
 
Yes
No
Not Sure
 
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.