<?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>Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58</link><description>I&amp;#39;m using SDK 15.1, nRF52 in custom units, toolchain GDB, addr2line 
 
 A little background - 
 
 We use System off mode and then use a button press to come out of it. 
 Before going back to system off mode again, we delete all flash records (requirement</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 24 Apr 2019 07:48:30 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58" /><item><title>RE: Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/thread/183328?ContentTypeID=1</link><pubDate>Wed, 24 Apr 2019 07:48:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6a3c4006-acd7-4e46-80f8-7588623fdbdc</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Ok, are you running the garbage collection, i.e.&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.2.0/group__fds.html#ga90285f376c435c64b352023e725b7ebb"&gt;fds_gc&lt;/a&gt;, to reclaim the flash space?&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.2.0/group__fds.html#gaf97cabe15afd74024e4250e931c720cd"&gt;fds_record_delete&lt;/a&gt;&amp;nbsp;only marks the record for deletion. Quote from the FDS API documentation.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Note that deleting a record does not free the space it occupies in flash memory. To reclaim flash space used by deleted records, call&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.2.0/group__fds.html#ga90285f376c435c64b352023e725b7ebb"&gt;fds_gc&lt;/a&gt;&amp;nbsp;to run garbage collection.&lt;/em&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/thread/183312?ContentTypeID=1</link><pubDate>Wed, 24 Apr 2019 06:59:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3bc082db-b264-44a6-a5c6-251b5d92b5e0</guid><dc:creator>shreyab</dc:creator><description>[quote userid="7571" url="~/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58/183123"]How are you erasing the pages prior to entering SystemOFF?[/quote]
&lt;p&gt;yes, we are waiting for FDS_EVT_DEL_RECORD&amp;nbsp; event before entering into System OFF.&lt;/p&gt;
[quote userid="7571" url="~/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58/183123"]Are you using the NVMC directly to do the erase or are you using the fstorage or FDS APIs?[/quote]
&lt;p&gt;We are using fds APIs for all flash related activities.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/thread/183123?ContentTypeID=1</link><pubDate>Tue, 23 Apr 2019 12:44:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fccd2588-0a54-44cc-886f-5cd2954dff6c</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;OK,&amp;nbsp; if the bootlaoder is SD independent then it will call __SEV() as a part of the &lt;span&gt;wait_for_event()&amp;nbsp;function which is called in the infinite for loop. So for some reason you are not jumping from the bootloader to the application when waking up from SystemOFF.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
[quote user="shreyab"]Further investigation reveals that, both data storage flash pages are full (probably corrupted) and in certain addresses there are random characters stored in ASCII sequence (the swap space is empty though and not at all corrupted).[/quote]
&lt;p&gt;How are you erasing the pages prior to entering SystemOFF? Are you using the NVMC directly to do the erase or are you using the fstorage or FDS APIs?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/thread/181984?ContentTypeID=1</link><pubDate>Mon, 15 Apr 2019 06:46:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3e9365c3-612b-44d8-b019-6448b58b70f1</guid><dc:creator>shreyab</dc:creator><description>[quote userid="7571" url="~/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58/181626"]Are you entering System OFF from the application or the bootloader? Have you configured the button to be a wakeup source in both the bootloader and the application?[/quote]
&lt;p&gt;We are entering System OFF from the application, and we have configured the button to be a wakeup source in JUST the application.&lt;/p&gt;
[quote userid="7571" url="~/f/nordic-q-a/46024/device-hang---program-counter-stuck-at-__sev-address-0x00078d58/181626"] Are using the SoftDevice in your bootloader is it not dependent on the SD?[/quote]
&lt;p&gt;Bootloader is not dependent on softdevice.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;UPDATE -&lt;/p&gt;
&lt;p&gt;Further investigation reveals that, both data storage flash pages are full (probably corrupted) and in certain addresses there are random characters stored in ASCII sequence (the swap space is empty though and not at all corrupted).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device HANG - Program counter stuck at __SEV()  (Address 0x00078d58)</title><link>https://devzone.nordicsemi.com/thread/181626?ContentTypeID=1</link><pubDate>Thu, 11 Apr 2019 13:14:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2cabfc3a-3f1c-4d62-873d-464cfcb3ec51</guid><dc:creator>bjorn-spockeli</dc:creator><description>[quote user=""]We use System off mode and then use a button press to come out of it.[/quote]
&lt;p&gt;Are you entering System OFF from the application or the bootloader? Have you configured the button to be a wakeup source in both the bootloader and the application?&lt;/p&gt;
[quote user=""]debugger also stuck at Address 0x00078d58 which is at __SEV()[/quote]
&lt;p&gt;&amp;nbsp;The address indicated that you&amp;#39;re in the bootloader. Are using the SoftDevice in your bootloader is it not dependent on the SD? The __SEV() function is used in the&amp;nbsp;wait_for_event() function, so the bootloader is simply waiting for an event.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards&lt;/p&gt;
&lt;p&gt;Bjørn&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>