<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How many breakpoints or watchpoints can I set? in LPCXpresso IDE FAQs</title>
    <link>https://community.nxp.com/t5/LPCXpresso-IDE-FAQs/How-many-breakpoints-or-watchpoints-can-I-set/m-p/470591#M63</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When debugging code running from flash memory, the debugger is limited on how many breakpoints it can set at any time by the number of hardware breakpoint units provided by the ARM CPU within the MCU.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Code located in RAM can use a different mechanism offering the capability of essentially unlimited breakpoints.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Typically, the number of hardware breakpoints/watchpoints that can be set are as follows:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;TT&gt;Cortex-M0/M0+&amp;nbsp; - 4 breakpoints, 2 watchpoints&lt;/TT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;TT&gt;Cortex-M3/M4&amp;nbsp;&amp;nbsp; - 6 breakpoints, 4 watchpoints&lt;/TT&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px;"&gt;&lt;/P&gt;&lt;P&gt;ARM provides a level of implementation flexibility, so always consult your MCU documentation. Generally NXP MCUs implement the maximum possible number. &lt;STRONG&gt;Note&lt;/STRONG&gt; the Cortex-M0's within the LPC43xx multicore MCUs implement only 2 breakpoints and 1 watchpoint.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ARM's CPU documentation can be found &lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Finfocenter.arm.com%2F"&gt;here&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you try to set too many breakpoints/watchpoints when debugging, then you will see an error of the form ...&lt;/P&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px; padding: 5px 10px; background: #eeeeee;"&gt;&lt;SPAN style="font-size: 12pt;"&gt;&lt;TT&gt;&amp;nbsp;&amp;nbsp; 15: Target error from Set break/watch&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Unable to set an execution break - no resource available.&lt;/TT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also remember that a breakpoint will be (temporarily) required for the initial breakpoint set by LPCXpresso IDE by default on the function &lt;TT&gt;main()&lt;/TT&gt; when you debug your application. For more details of this, please see the FAQ &lt;A _jive_internal="true" data-containerid="11529" data-containertype="14" data-objectid="388988" data-objecttype="1" href="https://community.nxp.com/thread/388988"&gt;Changing the initial breakpoint on debug startup&lt;/A&gt;.&lt;/P&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px;"&gt;&lt;/P&gt;&lt;P&gt;A breakpoint may also be required (temporarily) when single stepping your code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;On ARM7 based MCUs, also be aware that if &lt;A _jive_internal="true" data-containerid="11529" data-containertype="14" data-objectid="389156" data-objecttype="1" href="https://community.nxp.com/thread/389156"&gt;semihosting functionality&lt;/A&gt; is being used, then this will consume one breakpoint, leaving only one for general use!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Viewing the breakpoints/watchpoints that are set&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When viewing source (or disassembly) during a debug session, you can toggle breakpoints by simply clicking/double clicking in the left most side of the source view, typically shown as a light blue column. This is also where the breakpoint symbol is shown when one is set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Breakpoints and watchpoints are also displayed, and can be deleted or disabled in the Breakpoints View. If you are using the "Develop" perspective, then by default it will be in the bottom left of the LPCXpresso window tabbed with the Quickstart and other views.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you have closed the Breakpoint view at some point, then you can reopen it using the "Window -&amp;gt; Show view" menu or 'Window -&amp;gt; Reset Perspective".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Skip All Breakpoints&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use the "Skip all breakpoints" icon in the Breakpoints view (or on the main toolbar) to temporarily disable all breakpoints. This can be particularly useful on parts with only a few breakpoints available, particularly when you want to reload your image, which will typically cause the default breakpoint on main() to be temporarily set again automatically by the tools.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Breakpoints in multi-project workspaces&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One other thing to watch is that breakpoints are stored in the workspace, and by default are effectively project independent. Thus if you set a breakpoint in one file, and have a file of the same name in another project within the workspace, then if you debug the second project you may hit breakpoints unexpectedly (or have all your breakpoint units consumed unexpectedly).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can configure your debug launch configuration such that breakpoints are set with absolute filenames to avoid this issue. To do these, right click on the project and select...&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN style="font-size: 12pt;"&gt;&lt;TT&gt;Launch Configurations -&amp;gt; Open Launch Configurations -&amp;gt; Debugger&lt;/TT&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;Then select the "&lt;TT&gt;Main&lt;/TT&gt;" tab and tick the "&lt;TT&gt;Use full file path to set breakpoints&lt;/TT&gt;" option.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; this assumes you have already debugged the project in question. If not simply select the "&lt;TT&gt;Create Launch Configurations&lt;/TT&gt;" option first.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 31 Mar 2016 19:37:42 GMT</pubDate>
    <dc:creator>lpcware-support</dc:creator>
    <dc:date>2016-03-31T19:37:42Z</dc:date>
    <item>
      <title>How many breakpoints or watchpoints can I set?</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE-FAQs/How-many-breakpoints-or-watchpoints-can-I-set/m-p/470591#M63</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When debugging code running from flash memory, the debugger is limited on how many breakpoints it can set at any time by the number of hardware breakpoint units provided by the ARM CPU within the MCU.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Code located in RAM can use a different mechanism offering the capability of essentially unlimited breakpoints.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Typically, the number of hardware breakpoints/watchpoints that can be set are as follows:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;TT&gt;Cortex-M0/M0+&amp;nbsp; - 4 breakpoints, 2 watchpoints&lt;/TT&gt;&lt;/LI&gt;&lt;LI&gt;&lt;TT&gt;Cortex-M3/M4&amp;nbsp;&amp;nbsp; - 6 breakpoints, 4 watchpoints&lt;/TT&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px;"&gt;&lt;/P&gt;&lt;P&gt;ARM provides a level of implementation flexibility, so always consult your MCU documentation. Generally NXP MCUs implement the maximum possible number. &lt;STRONG&gt;Note&lt;/STRONG&gt; the Cortex-M0's within the LPC43xx multicore MCUs implement only 2 breakpoints and 1 watchpoint.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ARM's CPU documentation can be found &lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Finfocenter.arm.com%2F"&gt;here&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you try to set too many breakpoints/watchpoints when debugging, then you will see an error of the form ...&lt;/P&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px; padding: 5px 10px; background: #eeeeee;"&gt;&lt;SPAN style="font-size: 12pt;"&gt;&lt;TT&gt;&amp;nbsp;&amp;nbsp; 15: Target error from Set break/watch&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Unable to set an execution break - no resource available.&lt;/TT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also remember that a breakpoint will be (temporarily) required for the initial breakpoint set by LPCXpresso IDE by default on the function &lt;TT&gt;main()&lt;/TT&gt; when you debug your application. For more details of this, please see the FAQ &lt;A _jive_internal="true" data-containerid="11529" data-containertype="14" data-objectid="388988" data-objecttype="1" href="https://community.nxp.com/thread/388988"&gt;Changing the initial breakpoint on debug startup&lt;/A&gt;.&lt;/P&gt;&lt;P style="color: #646464; font-family: Arial, sans-serif; font-size: 12px;"&gt;&lt;/P&gt;&lt;P&gt;A breakpoint may also be required (temporarily) when single stepping your code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;On ARM7 based MCUs, also be aware that if &lt;A _jive_internal="true" data-containerid="11529" data-containertype="14" data-objectid="389156" data-objecttype="1" href="https://community.nxp.com/thread/389156"&gt;semihosting functionality&lt;/A&gt; is being used, then this will consume one breakpoint, leaving only one for general use!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Viewing the breakpoints/watchpoints that are set&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When viewing source (or disassembly) during a debug session, you can toggle breakpoints by simply clicking/double clicking in the left most side of the source view, typically shown as a light blue column. This is also where the breakpoint symbol is shown when one is set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Breakpoints and watchpoints are also displayed, and can be deleted or disabled in the Breakpoints View. If you are using the "Develop" perspective, then by default it will be in the bottom left of the LPCXpresso window tabbed with the Quickstart and other views.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you have closed the Breakpoint view at some point, then you can reopen it using the "Window -&amp;gt; Show view" menu or 'Window -&amp;gt; Reset Perspective".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Skip All Breakpoints&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use the "Skip all breakpoints" icon in the Breakpoints view (or on the main toolbar) to temporarily disable all breakpoints. This can be particularly useful on parts with only a few breakpoints available, particularly when you want to reload your image, which will typically cause the default breakpoint on main() to be temporarily set again automatically by the tools.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H2&gt;&lt;SPAN style="color: #eb7a3d;"&gt;Breakpoints in multi-project workspaces&lt;/SPAN&gt;&lt;/H2&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One other thing to watch is that breakpoints are stored in the workspace, and by default are effectively project independent. Thus if you set a breakpoint in one file, and have a file of the same name in another project within the workspace, then if you debug the second project you may hit breakpoints unexpectedly (or have all your breakpoint units consumed unexpectedly).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can configure your debug launch configuration such that breakpoints are set with absolute filenames to avoid this issue. To do these, right click on the project and select...&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN style="font-size: 12pt;"&gt;&lt;TT&gt;Launch Configurations -&amp;gt; Open Launch Configurations -&amp;gt; Debugger&lt;/TT&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;Then select the "&lt;TT&gt;Main&lt;/TT&gt;" tab and tick the "&lt;TT&gt;Use full file path to set breakpoints&lt;/TT&gt;" option.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; this assumes you have already debugged the project in question. If not simply select the "&lt;TT&gt;Create Launch Configurations&lt;/TT&gt;" option first.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Mar 2016 19:37:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE-FAQs/How-many-breakpoints-or-watchpoints-can-I-set/m-p/470591#M63</guid>
      <dc:creator>lpcware-support</dc:creator>
      <dc:date>2016-03-31T19:37:42Z</dc:date>
    </item>
  </channel>
</rss>

