<?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>SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/68482/softdevice-assertion-0x0002715e</link><description>Hello, 
 Looking for some background info for SOFTDEVICE ASSERTION 0x0002715e. sdk 15.3, SD s132_nrf52_6.1.1 
 Maybe related, there is no Assert if fds_record_write() is done before connecting, but Assert received during fds_record_write() after connecting</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 01 Dec 2020 02:22:19 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/68482/softdevice-assertion-0x0002715e" /><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282569?ContentTypeID=1</link><pubDate>Tue, 01 Dec 2020 02:22:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7a81d955-54ea-448d-b149-24eb3a444bcc</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;having,&lt;br /&gt;#define HARDFAULT_HANDLER_ENABLED 1&lt;/p&gt;
&lt;p&gt;shows,&lt;br /&gt;&amp;lt;00&amp;gt; error&amp;gt; hardfault: HARD FAULT at 0x0002930E&lt;br /&gt;&amp;lt;00&amp;gt; error&amp;gt; hardfault: R0: 0x0007E090 R1: 0x2000307C R2: 0x00000001 R3: 0x20003114&lt;br /&gt;&amp;lt;00&amp;gt; error&amp;gt; hardfault: R12: 0x00000000 LR: 0x00029461 PSR: 0x61000034&lt;/p&gt;
&lt;p&gt;which 0x0002930E leads to SD_FLASH_WRITE svc #029 as in this &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/49861/hardfault-occurs-when-sd_flash_write-returns" rel="noopener noreferrer" target="_blank"&gt;ticket&lt;/a&gt;,&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/calendar_2D00_2.PNG" /&gt;&lt;/p&gt;
&lt;p&gt;then this &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/60974/nrf_fault_id_sd_assert-every-once-in-a-while/247923#247923" rel="noopener noreferrer" target="_blank"&gt;ticket&lt;/a&gt; comment &amp;quot;interrupt handler running at priority 3, shouldn&amp;#39;t call any Softdevice API .... can&amp;#39;t run at that context level.&amp;quot;&lt;br /&gt;leads to CAL_RTC_IRQ_Priority=6&lt;br /&gt;Seems like only this ticket links the pieces together.&lt;/p&gt;
&lt;p&gt;thank-you,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282378?ContentTypeID=1</link><pubDate>Mon, 30 Nov 2020 07:55:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:29307a0f-bb4e-4289-ac41-74a64181d765</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Simon,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If you add hardfault_handler_gcc.c (under nRF5_SDK\external\components\libraries\hardfault\nrf52\handler) to your project, it will show the hard fault at&amp;nbsp;&lt;span&gt;0x0029032 which is&amp;nbsp;SD_FLASH_WRITE. Most of that might be caused by initial or SD APIs priority.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-Amanda H.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282324?ContentTypeID=1</link><pubDate>Fri, 27 Nov 2020 19:12:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f1e8a3b3-6764-4166-bcc6-6658d0fda3c7</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Not sure what the linkage is between the address of the hardfault at 0x0029032,&lt;br /&gt;and CAL_RTC_IRQ_Priority=6?&lt;br /&gt;Is this something that you just knew, &lt;br /&gt;or there is some documentation as to the remedy?&lt;/p&gt;
&lt;p&gt;When the requester verifies an answer, &lt;br /&gt;the follow-up goes unanswered because the ticket is now Closed.&lt;/p&gt;
&lt;p&gt;thank-you,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282205?ContentTypeID=1</link><pubDate>Fri, 27 Nov 2020 08:11:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:612a7b0c-1217-4b1d-be22-4e898f6a88dd</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Simon,&lt;/p&gt;
&lt;p&gt;If you add&amp;nbsp;hardfault_handler_gcc.c to your project, you might get the address of the hardfault as 0x0029032 which is&amp;nbsp;&lt;span&gt;sd_flash_write() called from nrf_cal_set_callback.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/640x114/__key/communityserver-discussions-components-files/4/2311.pastedimage1606464487379v1.png" /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Please verify the answer to benefit other users seeking the solution if it helps.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/0257.001_5F00_Verify-Answer.png" /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-Amanda H.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282159?ContentTypeID=1</link><pubDate>Thu, 26 Nov 2020 17:19:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:79d67580-5704-466e-a88b-629d9b87be23</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Hi Amanda,&lt;br /&gt;&lt;br /&gt;That setting worked, much appreciated.&lt;br /&gt;Now the calendar cycles after fds write().&lt;br /&gt;Not sure what led to that conclusion.&lt;br /&gt;I had read this (only) other &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/56237/how-to-use-time-sync-in-nrf52840/228622#228622" rel="noopener noreferrer" target="_blank"&gt;ticket&lt;/a&gt; in devzone,&lt;br /&gt;but missed that last sentence.&lt;br /&gt;&lt;br /&gt;thank-you,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/282082?ContentTypeID=1</link><pubDate>Thu, 26 Nov 2020 13:18:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:80264b7a-0ce7-4f3e-a9c4-ab8376354823</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Simon,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The hardfault is caused by the sd_flash_write() which you cannot use the&amp;nbsp;SD APIs from int. priority 3. Try to set it to &amp;#39;6&amp;#39; as&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;#define CAL_RTC_IRQ_Priority  6&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281682?ContentTypeID=1</link><pubDate>Tue, 24 Nov 2020 23:37:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:707a7ba1-1480-4321-85d8-a4dc9e7157a7</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;repeated&amp;nbsp;fds write&amp;nbsp;using sdk 17.0.2, and same hardfault, pc(r15)=0x0002635e.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281661?ContentTypeID=1</link><pubDate>Tue, 24 Nov 2020 17:57:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:70fd111e-3a0d-4738-b56f-3ee0195258b5</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;and in DEBUG, this is what the HardFault_Handler() is showing:&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/calendar_2D00_1.PNG" /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281659?ContentTypeID=1</link><pubDate>Tue, 24 Nov 2020 17:28:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8955e8f4-d27f-4f83-8f5d-0104d120ed62</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I had been testing fds_init() to see if that was the issue.&lt;br /&gt;The base CTS example does not have fds_evt_handler(),&lt;br /&gt;but because CTS has to bond, FDS is being used used successfully.&lt;br /&gt;When fds_evt_handler() is added, FDS_EVT_INIT returns FDS_SUCCESS,&lt;br /&gt;and FDS_EVT_WRITE also returns FDS_SUCCESS.&lt;/p&gt;
&lt;p&gt;If you comment current_time_print(p_evt), line 814,&lt;br /&gt;and uncomment line 817, fds_write_1(),&lt;br /&gt;then after connecting, and CTS is read,&lt;br /&gt;each subsequent press of button 1 on the DK,&lt;br /&gt;will successfully write the record by FDS.&lt;/p&gt;
&lt;p&gt;At the top of the debug log, visible when opening the ticket,&lt;br /&gt;you&amp;#39;ll see the lines,&lt;br /&gt;00&amp;gt; rec_id sample1 sample2 sample3 sample4&lt;br /&gt;00&amp;gt; C &amp;nbsp;1 &amp;nbsp;2 &amp;nbsp;3 &amp;nbsp;4 &lt;br /&gt;which indicates that the FDS has been properly initialized,&lt;br /&gt;and record written by FDS.&lt;/p&gt;
&lt;p&gt;I had also added a delay after the callback(), &lt;br /&gt;and tried to initialize FDS once again after callback(),&lt;br /&gt;all with the same unsuccessful result.&lt;/p&gt;
&lt;p&gt;It still seems like that the nrf_cal_set_callback() function is&lt;br /&gt;causing fds_record_write() to halt FDS.&lt;/p&gt;
&lt;p&gt;thank-you,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281504?ContentTypeID=1</link><pubDate>Tue, 24 Nov 2020 10:55:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6a119d98-8770-47f2-ab75-3f74d73a6743</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Simon,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It seems you forgot to initial the fds in the uploaded project. Please see&amp;nbsp;&lt;a title="Software Development Kit" href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.3.0/lib_fds_usage.html?resultof=%22%66%64%73%5f%72%65%63%6f%72%64%5f%77%72%69%74%65%22%20"&gt;nRF5 SDK v15.3.0: Usage&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.3.0/fds_example.html"&gt;Flash Data Storage Example&lt;/a&gt;&amp;nbsp;on how to initiate the FDS.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281374?ContentTypeID=1</link><pubDate>Mon, 23 Nov 2020 15:21:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b065fc5e-1b84-41d8-8ca5-26811a4f39a1</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;also, if fds_record_write() is commented, the calendar cycles properly as intended.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/281025?ContentTypeID=1</link><pubDate>Fri, 20 Nov 2020 05:57:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a069e530-a0be-4981-80cc-93db9b1dc10d</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I had been using WRITE_SIZE 1024 from another suggestion on devzone, but still the same issue.&lt;br /&gt;The other bit of code merged was the Calendar example,&lt;br /&gt;and it seems the function nrf_cal_set_callback() is what seems to be causing the Assert.&lt;br /&gt;Without the callback(), the fds_record_write() is working ok.&lt;br /&gt;I checked the suggestion by Torbj&amp;oslash;rn (ovrebekk), to make sure RTC2 is being used, and it is.&lt;/p&gt;
&lt;p&gt;I merged sdk 15.3 CTS with Calendar and added the FDS write() to test on DK832 and reproduce the issue.&lt;br /&gt;The&amp;nbsp;fault happens in fds_write_1() during fds_record_write(), line 248 on SES.&lt;br /&gt;(After connecting on nRF Connect, press button 1 on the DK).&lt;/p&gt;
&lt;p&gt;thank-you,&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/ble_5F00_app_5F00_cts_5F00_c_5F00_calendar_2D00_1_5F00_debug_5F00_log_2D00_1.txt"&gt;devzone.nordicsemi.com/.../ble_5F00_app_5F00_cts_5F00_c_5F00_calendar_2D00_1_5F00_debug_5F00_log_2D00_1.txt&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/3107.main.c"&gt;devzone.nordicsemi.com/.../3107.main.c&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/ble_5F00_app_5F00_cts_5F00_c_5F00_calendar_2D00_1.zip"&gt;devzone.nordicsemi.com/.../ble_5F00_app_5F00_cts_5F00_c_5F00_calendar_2D00_1.zip&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/280757?ContentTypeID=1</link><pubDate>Thu, 19 Nov 2020 07:17:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:09448b88-b953-463b-bb31-7f3a7c9063e7</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Simon,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Sorry for the delay.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Could you try with a lower NRF_FSTORAGE_SD_MAX_WRITE_SIZE setting, 1024 for instance?&lt;/p&gt;
&lt;p&gt;Is it possible to provide the debug log?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SOFTDEVICE ASSERTION 0x0002715e</title><link>https://devzone.nordicsemi.com/thread/280731?ContentTypeID=1</link><pubDate>Thu, 19 Nov 2020 01:32:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8fc68b01-264a-4abc-9b4e-a795a7f17e32</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Update: tested with executing fds_record_write() just after connecting without CTS, and no Assert.&lt;br /&gt;Tested with plain sdk CTS with DK832 and no Assert just after connecting, and no Assert after receiving CTS.&lt;br /&gt;NUS was also merged, maybe missed something there, re-testing NUS with CTS.&lt;/p&gt;
&lt;p&gt;thank-you,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>