User manual
MPLAB
®
REAL ICE
™
In-Circuit Emulator User’s Guide
DS51616B-page 46 © 2008 Microchip Technology Inc.
4.11.5 Setting Software Breakpoints
To change the breakpoint type from hardware to software:
•Select Debugger>Settings and click on the Configuration tab.
• Click the radio button next to “Use Software Breakpoints”.
•Click OK.
You will now use software breakpoints instead of the hardware breakpoints used
previously.
1. To set a single software breakpoint, follow the instructions in
Section 4.11.2 “Setting a Single Hardware Breakpoint”.
- When you set a software breakpoint, you will see the following in the Output
window:
Programming software breakpoint(s)...
Software breakpoint(s) set.
- If you have already set a hardware breakpoint in this tutorial, the variables will
already be added to the Watch window for use with the software breakpoint.
2. To set multiple software breakpoints, follow the instructions in
Section 4.11.3 “Setting Multiple Hardware Breakpoints”.
- There is no breakpoint skidding with software breakpoints, i.e., the program
halts on the breakpoint. This may affect how you see values change in the
Watch window.
- There is no maximum number of breakpoints with software breakpoints, i.e,
although this tutorial only uses two, the number of software breakpoints is
unlimited.
3. The stopwatch is meant to be used with hardware breakpoints. However, you can
use the stopwatch with software breakpoints, but they will be converted to hard-
ware breakpoints as you select them. In the Output window, you will see:
Converting breakpoint types...
Breakpoint type conversion complete.
Follow the steps as specified in Section 4.11.4 “Using the Stopwatch with
Breakpoints”.
4. Set the breakpoints to hardware again for the remainder of the tutorial. Select
Debugger>Settings
, click on the Configuration tab, click the radio button next to
“Use Hardware Breakpoints” and then click OK.
Note: Using software breakpoints for debug impacts device endurance. There-
fore, it is recommended that devices used in this manner not be used as
production parts.