µVision3 User's GuideµVision3 Overview User Interface Creating Applications Utilities Debugging Debug Commands ASM ASSIGN BreakAccess BreakDisable BreakEnable BreakKill BreakList BreakSet COVERAGE DEFINE DIR Display Enter EVALuate EXIT Go INCLUDE KILL LOAD LOG LogicAnalyze MAP MODE Ostep PerformanceAnalyze Pstep RESET SAVE SCOPE SET SIGNAL SLOG Tstep Unassemble WatchSet WatchKill Debug Functions Simulation Flash Programming Dialogs Example Programs Command Line Appendix
The DEFINE command lets you create a symbol with a type that can be used to hold a value. Symbols created this way may be used to hold return values for µVision3 functions or to specify input to µVision3 functions.
Symbols created with the DEFINE command are not placed in the memory space of the simulated or target CPU. They are just symbolic names for values of a specified type. A symbol created by DEFINE may be used just like any other public symbol.
The possible symbol types are listed in the following table.
The identifier is the name of the symbol. It must conform to the rules for variables or symbols.
>DEFINE CHAR TmpByte /* define TmpByte to be a char value */ >DEFINE FLOAT TmpFloat /* define TmpFloat to be a float value */ >TmpFloat = 3.14159 /* give TmpFloat a value */ >TmpFloat /* display the value of TmpFloat */ 3.14159
Use this command to add a button to the Toolbox window.
label is the name to assign to the button.
cmd is the µVision3 command or commands to assign to the button. This command is executed when the button is clicked.
>DEFINE BUTTON "clr dptr", "dptr=0" >DEFINE BUTTON "show main()", "u main" >DEFINE BUTTON "show r7", "printf (\"R7=%02XH\\n\",R7)"
When a button is defined, it is immediately added to the Toolbox window. Each button receives a button number which is displayed in the Toolbox window. This number is used to remove specific buttons from the Toolbox window.
of your data.