<?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>Firmware app doesn&amp;#39;t start after OTA DFU</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73793/firmware-app-doesn-t-start-after-ota-dfu</link><description>Hi Team, I am prototyping a product that includes OTA DFU using nRF52832. As a first experiment, I am simply downloading the bootloader to my device and sending my firmware app as a .zip package to it with DFU from nRF Connect. It seems that DFU itself</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 12 Apr 2021 08:50:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73793/firmware-app-doesn-t-start-after-ota-dfu" /><item><title>RE: Firmware app doesn't start after OTA DFU</title><link>https://devzone.nordicsemi.com/thread/304203?ContentTypeID=1</link><pubDate>Mon, 12 Apr 2021 08:50:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a11cd0e1-0cd4-46b6-98d2-b397a0ded969</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Tibor,&amp;nbsp;&lt;br /&gt;The log showed a normal DFU update, the last line showed that it jumped to the softdevice (then the softdevice will jump to the application).&amp;nbsp;&lt;br /&gt;I would suggest to try debugging in the application.&amp;nbsp;&lt;br /&gt;Have you verified that you can DFU update a very simple application that toggle the GPIO ?&amp;nbsp;&lt;br /&gt;After that you can edit your BLE application to do the same task (GPIO toggling) at the beginning of your application. You can put a while(1); to block any further feature, only keep blinking LED. Just so that you can verify your application setting is OK and you can run to your application and debug it after DFU. After that you can continue to remove the while(1); , do DFU update and debug your actual BLE application.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Firmware app doesn't start after OTA DFU</title><link>https://devzone.nordicsemi.com/thread/304092?ContentTypeID=1</link><pubDate>Fri, 09 Apr 2021 18:49:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f91df778-9957-491b-a4f2-8503fb0dcac9</guid><dc:creator>Tibor Kakonyi</dc:creator><description>&lt;p&gt;&lt;span&gt;Hi Hung,&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span&gt;Thank you very much for your reply.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span&gt;I have tried the first part of your advice: I have sent over SDK example apps as zip files, and they start up and work correctly after DFU is done. My custom app also works correctly if I simply download it to the device with a programming cable. The strange thing is that it doesn&amp;#39;t start up only if it&amp;#39;s sent to the device with OTA DFU, while other apps do. I know it&amp;#39;s hard to tell anything without knowing the code, but is there any logical reason for this behaviour?&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span&gt;I have run DFU also with the debug version of the bootloader. I have pasted below the output it prints after DFU is finished. Can you please help me find a starting point in it?&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span&gt;Thanks a lot,&lt;/span&gt;&lt;br /&gt;&lt;span&gt;Tibor&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_req_handler: All flash operations have completed. DFU completed.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Shutting down transports (found: 1)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_ble: Shutting down BLE transport.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_ble: Disconnecting.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_ble: BLE transport shut down.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Resetting bootloader.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; nrf_dfu_settings: Backi&amp;lt;info&amp;gt; app: Inside main&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: In nrf_bootloader_init&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Calling nrf_dfu_settings_init()...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Using settings page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Copying forbidden parts from backup page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; nrf_dfu_settings: Backing up settings page to address 0x7E000.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Enter nrf_bootloader_fw_activate&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Valid App&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Enter nrf_dfu_app_continue&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: No copy needed&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Setting app as valid&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Writing settings...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Erasing old settings at: 0x0007F000&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_flash: nrf_fstorage_erase(addr=0x0x0007F000, len=1 pages), queue usage: 0&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_flash: Flash erase success: addr=0x0007F000, pen&amp;lt;info&amp;gt; app: Inside main&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: In nrf_bootloader_init&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Calling nrf_dfu_settings_init()...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Using settings page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Copying forbidden parts from backup page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; nrf_dfu_settings: Backing up settings page to address 0x7E000.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Enter nrf_bootloader_fw_activate&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; app: No firmware to activate.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: App is valid&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings_svci: Erasing setting&amp;lt;info&amp;gt; app: Inside main&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: In nrf_bootloader_init&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Calling nrf_dfu_settings_init()...&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Using settings page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Copying forbidden parts from backup page.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; nrf_dfu_settings: Backing up settings page to address 0x7E000.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Enter nrf_bootloader_fw_activate&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; app: No firmware to activate.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: App is valid&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;info&amp;gt; nrf_dfu_settings: Backing up settings page to address 0x7E000.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Running nrf_bootloader_app_start with address: 0x00001000&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;lt;debug&amp;gt; app: Disabling interrupts. NVIC-&amp;gt;ICER[0]: 0x0&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Firmware app doesn't start after OTA DFU</title><link>https://devzone.nordicsemi.com/thread/304040?ContentTypeID=1</link><pubDate>Fri, 09 Apr 2021 13:36:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d20c97a4-c58f-4413-91ca-f88225a6b5e8</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Tibor,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I would suggest to get familiar to how to debug an application after DFU update.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;You would need to check if the application actually get executed (the PC run into main() in the application ) or it stuck some where in the bootloader.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Please try to do a DFU update of a very simple program that blink an LED for example. Make sure that program works fine when you flash just the softdevice and the program.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Then you can create DFU package .zip and do DFU update it. Please test if you can debug the application after the DFU update.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;After that you can test with your custom firmware and check if you can debug it as well and check why it doesn&amp;#39;t advertise.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;It&amp;#39;s also possible to debug the bootloader, you just need to compile and flash the debug version of the bootloader (remove any code optimization in the bootloader).&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>