In A51 the next definitions takes two cells of RAM, (0AH), for example, and (0BH): data_variable: DS 1 typeless_number EQU 0BH and can be treated with the same instruction: MOV A,data_variable (F50A) MOV A,typeless_number (F50B) ,but there is the value of "data_variable" displays properly in the "Watch" window, "typeless_number" shows it's address instead of the value. How can I trace such a variable?
-Thanks alot, for a patience for silly questions :)! -I'm sorry for the incorrect formulation. Of corse, the first case is a "pure" variable, the second, -is a constant to refer to as an address, for example. But anyway, how it could be done, to see a random SFR using it's address? When I've typed following: ( WS 1, 0x0B ), in watch window appears name: 0x0B with the value: (0x000C)
to see a random SFR using it's address? Ah, but that's quite a completely different question! And the answer to this one is, I think, that you can't, because there is no such thing as a random SFR in the 8051 architecture to start with. SFR are direct addressing only, i.e. there's no such thing as a "pointer to an SFR" that you could dereference to access it. In a sense, 8051 SFRs don't have addresses. If your program uses a given SFR, it has to be accessing by name, in the source. So you should access it by name in the debugger, too.
-Thank You so much!, but, still confused I've to ask, is it possible to display the "ram dump" in uVision3 debugger. What a mechanism can allow to trace changes in data memory caused by a program using addresation through "a constant as an address"
-Wow, I did find it! -It's just a matter of overriding the "memory" window from default "code" to the wanted.
View all questions in Keil forum