13.07.2015 Views

MPLAB ICD 3 In-Circuit Debugger User's Guide

MPLAB ICD 3 In-Circuit Debugger User's Guide

MPLAB ICD 3 In-Circuit Debugger User's Guide

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>MPLAB</strong> ® <strong>ICD</strong> 3 IN-CIRCUITDEBUGGER USER’S GUIDEChapter 8. Basic Debug Functions8.1 INTRODUCTION8.2 BREAKPOINTS8.3 STOPWATCHBasic <strong>MPLAB</strong> <strong>ICD</strong> 3 in-circuit debugger debug functions of breakpoints and stopwatchare discussed.Use breakpoints to halt code execution at specified lines in your code.Breakpoints and triggers use the same resources. Therefore, the available number ofbreakpoints is actually the available number of combined breakpoints/triggers.To select hardware or software breakpoints:1. Select <strong>Debugger</strong>>Settings and click the Configuration tab.2. Select the desired type of breakpoints for your application. A list of features foreach breakpoint type, hardware or software, is shown under that type. (SeeSection 9.5.2 “Settings Dialog, Configuration Tab” for more information.)Note:Using software breakpoints for debug impacts device endurance.Therefore, it is recommended that devices used in this manner not beused as production parts.Use the stopwatch with breakpoints to time code execution.To set a breakpoint in code, do one of the following:• Double click or right click on a line of code to set up an individual breakpoint.• Select <strong>Debugger</strong>>Breakpoints to open the Breakpoints dialog and set up multiplebreakpoints and breakpoint conditions. See Section 9.3.1 “Breakpoints Dialog”for more information.To determine the time between the breakpoints, use the stopwatch:1. Open the Breakpoints dialog (<strong>Debugger</strong>>Breakpoints).1. Click Stopwatch on the Breakpoints dialog to open the Stopwatch dialog.2. Under “Start Condition”, select a breakpoint from the drop-down list. Also decideif “Start condition will cause the target device to halt”.3. Under “Stop Condition”, select another breakpoint from the drop-down list. Alsodecide if “Stop condition will cause the target device to halt”.4. Decide if there will be a “Reset stopwatch on run”.5. Click OK.© 2008 Microchip Technology <strong>In</strong>c. DS51766A-page 63

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!