User`s guide
Develop an Application
© 2008 Microchip Technology Inc. DS51700A-page 17
3.3 RUNNING THE EXAMPLE APPLICATION
The starter kit executes in either real-time (Run) or steps (Step Into, Step Over, Ani-
mate.) Real-time execution occurs when you select Run in MPLAB IDE. Once the
device code is halted, either by Halt or a breakpoint, you can step.
The following toolbar buttons can be used for quick access to commonly used debug
operations:
To see how these options function, do the following:
1. Select Debugger>Reset>Processor Reset
or click the Reset button to reset the
program.
2. Select Debugger>Run
or click the Run button. Observe how the application
operates.
3. Select Debugger>Halt
or click the Halt button to stop the program execution. A
green solid arrow will mark the line of code in the File window where the program
halted.
4. Select Debugger>Step Into
or click the Step Into button to step the program exe-
cution once. The green solid arrow will move down one line of code in the File
window. Click the button several times to step through some code.
5. Select Debugger>Reset>Processor Reset
click the Reset button to reset the
program again. The arrow will disappear, meaning the device is reset.
3.4 DEBUGGING THE EXAMPLE APPLICATION
For the example code given, everything works fine. However, when you are developing
code, it will likely not work the first time and need to be debugged. MPLAB IDE provides
an editor and several debug features such as breakpoints and Watch windows to aid
in application code debugging.
This section includes:
• Editing Application Code
• Using Breakpoints and Mouseovers
• Using Watch Windows
Debugger Menu Toolbar Buttons
Run
Halt
Animate
Step Into
Step Over
Reset