User`s guide

Additional Features
© 2006 Microchip Technology Inc. DS51519B-page 83
To import Watch variable values from a table:
Click on an entry to select the SFR/Symbol. Right click in the window and select
Import Table. In the Table Setup dialog, check or change import information and
click OK.
6.3.7 C Language Usage – Watch Window
If you are developing your application code in C, the following features are available in
the Watch window to you:
Bitfield value mouseover available. Enable/disable this feature using the right
mouse button menu in the Watch window. The Watch window must be the active
window (in focus) for this feature to work.
Click in the Symbol Name field and enter a pointer name, e.g., *count. The
variable must be a pointer to an intrinsic type or structure.
Click in the Symbol Name field and enter a structure member name, e.g.,
porta.ra0. The variable must be of the form struct.membername.
Click in the Symbol Name field and enter a structure pointer member name, e.g.,
porta->pin. The variable must be of the form struct->pointername.
Symbol names may be typed, copied/pasted or dragged/dropped. Also, you can select
from the SFR/Symbol lists, and then edit the Symbol name to add the extra info.
Example 1:
int J = 2;
int* pint = &J;
Enter in Watch: *pInt, Value: 2
Example 2:
char[] string = "Test";
char* pstring = string;
Enter in Watch: *pstring, Value: "Test"
Example 3:
typedef struct
{
int str_int;
char str_ch;
} TestStruct;
TestStruct struct1;
TestStruct* pstruct1 = &struct1;
pstruct1->str_ch = 'A';
Enter in Watch: *pstruct1, Value: tree for struct.
Enter in Watch: struct1.str_int, Value: 'A'
6.3.8 C Language Usage – Local Variable Window
In addition to the Watch window, the Local Variable window may be used to watch local
C variables. See Section 12.13 “Locals Window” for more details.
Note: The Watch window will display only 32 bits for MPLAB C30 type long
long int and only 16 bits for MPLAB C18 type short long int.
Change the display through the Watch dialog.