<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Debug: cannot set breakpoint in VS Code</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/110656/debug-cannot-set-breakpoint-in-vs-code</link><description>Hi guys, my setup: 
 - nRf Connect 2.6.0 
 - VS Code 1.88.1 
 - Apple Macbook M3 Max (ARM64 CPU) 
 - nRF52840-DK 
 
 I created a new project based on the zephyr button sample. It builds and it runs as expected. 
 I cannot set a breakpoint in the button_pressed</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 02 May 2024 01:55:56 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/110656/debug-cannot-set-breakpoint-in-vs-code" /><item><title>RE: Debug: cannot set breakpoint in VS Code</title><link>https://devzone.nordicsemi.com/thread/481417?ContentTypeID=1</link><pubDate>Thu, 02 May 2024 01:55:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2e34cbe8-1fbd-4919-8b21-690909d9200d</guid><dc:creator>Anders Nelson</dc:creator><description>&lt;p&gt;Hi Wes,&lt;/p&gt;
&lt;p&gt;Yes the optimization was set to -Og. I haven&amp;#39;t yet taken the intermediate course but I plan to once I exit a squeeze point at work.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debug: cannot set breakpoint in VS Code</title><link>https://devzone.nordicsemi.com/thread/481416?ContentTypeID=1</link><pubDate>Thu, 02 May 2024 01:54:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2721fc68-eb74-4e3c-9f9c-831ef98e7d26</guid><dc:creator>Anders Nelson</dc:creator><description>&lt;p&gt;The&amp;nbsp;problem was caused a single typo in &lt;strong&gt;an edit I made to&amp;nbsp;&lt;/strong&gt;&lt;span style="font-weight:400;"&gt;&lt;strong&gt;display_st7789v.c&lt;/strong&gt; within the nRF Connect SDK, as suggested by this ST7789V display project:&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/JON95Git/lvgl-nrf52840-mdk-sample"&gt;https://github.com/JON95Git/lvgl-nrf52840-mdk-sample&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The edit was this region:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;&lt;span style="font-weight:400;"&gt;#define&lt;/span&gt;&lt;span style="font-weight:400;"&gt; ST7789V_INIT(&lt;/span&gt;&lt;span style="font-weight:400;"&gt;inst&lt;/span&gt;&lt;span style="font-weight:400;"&gt;)&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;span style="font-weight:400;"&gt;static const struct st7789v_config st7789v_config_ ## inst &lt;/span&gt;&lt;span style="font-weight:400;"&gt;=&lt;/span&gt;&lt;span style="font-weight:400;"&gt; {&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;span style="font-weight:400;"&gt;.bus &lt;/span&gt;&lt;span style="font-weight:400;"&gt;=&lt;/span&gt;&lt;span style="font-weight:400;"&gt; SPI_DT_SPEC_INST_GET(inst, SPI_OP_MODE_MASTER &lt;/span&gt;&lt;span style="font-weight:400;"&gt;|&lt;/span&gt;&lt;span style="font-weight:400;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="font-weight:400;"&gt;SPI_WORD_SET(&lt;/span&gt;&lt;span style="font-weight:400;"&gt;8&lt;/span&gt;&lt;span style="font-weight:400;"&gt;)&amp;nbsp;&lt;/span&gt;&lt;span style="font-weight:400;"&gt;|&lt;/span&gt;&lt;span style="font-weight:400;"&gt; SPI_TRANSFER_MSB&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style="font-weight:400;"&gt;|&amp;nbsp;&lt;/span&gt;&lt;span style="font-weight:400;"&gt;SPI_MODE_CPOL , &lt;/span&gt;&lt;span style="font-weight:400;"&gt;0&lt;/span&gt;&lt;span style="font-weight:400;"&gt;),&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;span style="font-weight:400;"&gt;[...]&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-weight:400;"&gt;Somehow the project was still allowed to build without errors, even though the init routine for the display was throwing data access errors I could only see when debugging with Segger Ozone.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-weight:400;"&gt;After fixing the content of the &amp;quot;.bus&amp;quot; definition the system started working as intended.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debug: cannot set breakpoint in VS Code</title><link>https://devzone.nordicsemi.com/thread/481406?ContentTypeID=1</link><pubDate>Wed, 01 May 2024 20:38:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b90441a1-e5ba-4e60-834a-42d17fdc538d</guid><dc:creator>WesC</dc:creator><description>&lt;p&gt;Anders;&amp;nbsp;&amp;nbsp;&lt;br /&gt;are you setting the optimization level in the build configuration to debug?&lt;/p&gt;
&lt;p&gt;also take a look at this training on Debug to see if there is any insight there&lt;/p&gt;
&lt;p&gt;&lt;a id="" href="https://academy.nordicsemi.com/courses/nrf-connect-sdk-intermediate/lessons/lesson-2-debugging/"&gt;https://academy.nordicsemi.com/courses/nrf-connect-sdk-intermediate/lessons/lesson-2-debugging/&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>