<?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>Source of Hardfault</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/99668/source-of-hardfault</link><description>Hello, I am using NRF SDK 15.3.0, working in Segger Embedded Studio. 
 
 I am intermittently receiving hardfault errors when debugging my code. I am wondering how best to troubleshoot this as the hardfault does not leave any trace, it simply pauses execution</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 12 May 2023 14:14:21 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/99668/source-of-hardfault" /><item><title>RE: Source of Hardfault</title><link>https://devzone.nordicsemi.com/thread/425383?ContentTypeID=1</link><pubDate>Fri, 12 May 2023 14:14:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7020bc92-8357-4edb-89d0-76f180f45cbf</guid><dc:creator>Caleb</dc:creator><description>&lt;p&gt;Alright, I will investigate using those methods. I know that because of softdevice you cannot step through the code but these other methods will be very helpful. &lt;br /&gt;Thank you!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Source of Hardfault</title><link>https://devzone.nordicsemi.com/thread/425224?ContentTypeID=1</link><pubDate>Fri, 12 May 2023 06:00:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3c6b2bba-51ea-403f-b02d-25c021ea38d5</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user=""]The new addition to the code is a driver for SPI flash memory. I am wondering if there are hardfaults associated with the nrf spi commands that might be the source?[/quote]
&lt;p&gt;If this is not related to the softdevice, then you should get the &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/27014/how-can-i-distinguish-the-reason-for-hardfault"&gt;faulting address of the instruction &lt;/a&gt;that is causing the hardfault to understand more about the nature of this fault.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Source of Hardfault</title><link>https://devzone.nordicsemi.com/thread/425223?ContentTypeID=1</link><pubDate>Fri, 12 May 2023 05:57:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:29f5e46c-cc9e-4b14-90de-c89fd9d205dc</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;If you have a BLE application and softdevice is enabled, then you cannot step or continue after a CPU halt when you are debugging. This is mentioned and discussed many many times in this forum for example like in &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/17/how-can-i-debug-a-softdevice-application"&gt;this&lt;/a&gt; thread.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You will have to use &lt;a href="https://github.com/NordicPlayground/j-link-monitoring-mode-debugging/#monitor-mode-debugging-in-keil-%C2%B5vision5-and-segger-embedded-studio"&gt;Monitor mode debugging&lt;/a&gt; to have the capabilities to break and step while softdevice is running in the background.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>