<?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>Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/87201/implementing-dfu-trigger-library</link><description>Board: nRF52833 
 SoftDevice: s140 
 SDK version: 17.0.2 
 I am trying to implement OTA buttonless DFU feature in my custom device (USB Device) which is a central device. So I integrated the buttonless DFU feature into my application and tested it in</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 26 Apr 2022 10:47:49 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/87201/implementing-dfu-trigger-library" /><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364911?ContentTypeID=1</link><pubDate>Tue, 26 Apr 2022 10:47:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:288ad83c-7451-4447-90d1-c67b9aa47313</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Nabeel,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Please try testing with the ble_app_uart example.&amp;nbsp;&lt;br /&gt;Please check the log first to see if there is any assert. From the log of the bootloader you provided it doesn&amp;#39;t seem that it stopped at&amp;nbsp;&lt;strong&gt;sd_softdevice_enable()&lt;/strong&gt; instead it printed &amp;quot;&amp;nbsp;Advertising...&amp;quot;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You may want to compile the application without any optimization, and add DEBUG into the preprocessor&amp;#39;s symbols in project setting.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364909?ContentTypeID=1</link><pubDate>Tue, 26 Apr 2022 10:46:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a3893091-2d0d-4aea-a19f-33f274ace29b</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I&amp;#39;ve changed the configuration that you said in the bootloader. The OTA DFU works fine now.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thanks for the support. It&amp;#39;s a great help.&amp;nbsp;&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: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364857?ContentTypeID=1</link><pubDate>Tue, 26 Apr 2022 08:18:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:af09ad42-57e6-48e1-9ca0-aee2986ed920</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I&amp;#39;ve flashed the&amp;nbsp;&lt;span&gt;usbd_ble_uart example and tried to debug. My debug terminal didn&amp;#39;t work but still, I was able to step into the code. My debugging stopped in the&amp;nbsp;&lt;strong&gt;ble_stack_init();&lt;/strong&gt; function, most particularly in&amp;nbsp;&lt;strong&gt;SVCALL(SD_SOFTDEVICE_ENABLE, uint32_t, sd_softdevice_enable(nrf_clock_lf_cfg_t const * p_clock_lf_cfg, nrf_fault_handler_t fault_handler));&lt;/strong&gt;&amp;nbsp;function def in nrf_sdm.h file. Though I can&amp;#39;t able to access the debug terminal, I&amp;#39;m unable to check what error/assert msg I&amp;#39;m getting.&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364828?ContentTypeID=1</link><pubDate>Tue, 26 Apr 2022 07:21:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:de42883a-d6ca-460d-a3fd-8c7d22eff8b9</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Please try to debug and check if you get any error/assert.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364801?ContentTypeID=1</link><pubDate>Tue, 26 Apr 2022 05:15:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:54995f27-b361-4d66-b782-0a093eee826b</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364716#364716"]Have you tested any BLE example in the SDK ?&amp;nbsp; Did it work ?&amp;nbsp;[/quote]
&lt;p&gt;I&amp;#39;ve tested flashing ble_app_uart and usbd_ble_uart examples. It didn&amp;#39;t advertise.&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364716#364716"]&lt;p&gt;You would need to change&amp;nbsp;NRF_SDH_CLOCK_LF_SRC configuration in sdk_config.h from 1 to 0 to select the RC instead of the crystal.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And&amp;nbsp;NRF_SDH_CLOCK_LF_ACCURACY to 0,&amp;nbsp;&lt;span&gt;NRF_SDH_CLOCK_LF_RC_CTIV&amp;nbsp; &amp;nbsp;to 16 and&amp;nbsp;NRF_SDH_CLOCK_LF_RC_TEMP_CTIV&amp;nbsp; to 2.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;[/quote]
&lt;p&gt;It&amp;#39;s already in this configuration.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364716?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2022 12:26:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:137ac532-8150-497c-9b60-19a13da70181</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Nabeel,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If you don&amp;#39;t have 32kHz crystal you would need to configure the softdevice to use the 32kHz RC instead.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Have you tested any BLE example in the SDK ?&amp;nbsp; Did it work ?&amp;nbsp;&lt;br /&gt;You would need to change&amp;nbsp;NRF_SDH_CLOCK_LF_SRC configuration in sdk_config.h from 1 to 0 to select the RC instead of the crystal.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And&amp;nbsp;NRF_SDH_CLOCK_LF_ACCURACY to 0,&amp;nbsp;&lt;span&gt;NRF_SDH_CLOCK_LF_RC_CTIV&amp;nbsp; &amp;nbsp;to 16 and&amp;nbsp;NRF_SDH_CLOCK_LF_RC_TEMP_CTIV&amp;nbsp; to 2.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364686?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2022 11:19:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a3ac5323-d6f7-4b9f-9b75-3160f9d098f6</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364604#364604"]Please check if you have 32kHz crystal on your board ?[/quote]
&lt;p&gt;We have an internal 32MHz crystal but no low-frequency 32kHz crystal connected to it. Is it important to have connected?&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364604#364604"]If you only flash the softdevice + bootloader would it advertise DFUTarg ?&amp;nbsp;[/quote]
&lt;p&gt;No, it doesn&amp;#39;t advertise as Dfutarg. When I debug I am getting the following in the log&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;&amp;lt;info&amp;gt; app: Inside main
&amp;lt;debug&amp;gt; app: In nrf_bootloader_init
&amp;lt;debug&amp;gt; nrf_dfu_settings: Calling nrf_dfu_settings_init()...
&amp;lt;debug&amp;gt; nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.
&amp;lt;debug&amp;gt; nrf_dfu_settings: Using settings page.
&amp;lt;debug&amp;gt; nrf_dfu_settings: Copying forbidden parts from backup page.
&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.
&amp;lt;info&amp;gt; nrf_dfu_settings: Backing up settings page to address 0x7E000.
&amp;lt;debug&amp;gt; nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.
&amp;lt;debug&amp;gt; app: Enter nrf_bootloader_fw_activate
&amp;lt;info&amp;gt; app: No firmware to activate.
&amp;lt;info&amp;gt; app: Boot validation failed. No valid app to boot.
&amp;lt;debug&amp;gt; app: DFU mode because app is not valid.
&amp;lt;info&amp;gt; nrf_bootloader_wdt: WDT is not enabled
&amp;lt;debug&amp;gt; app: in weak nrf_dfu_init_user
&amp;lt;debug&amp;gt; app: timer_stop (0x20002B04)
&amp;lt;debug&amp;gt; app: timer_activate (0x20002B04)
&amp;lt;info&amp;gt; app: Entering DFU mode.
&amp;lt;debug&amp;gt; app: Initializing transports (found: 1)
&amp;lt;debug&amp;gt; nrf_dfu_ble: Initializing BLE DFU transport
&amp;lt;debug&amp;gt; nrf_dfu_ble: Setting up vector table: 0x00072000
&amp;lt;debug&amp;gt; nrf_dfu_ble: Enabling SoftDevice.
&amp;lt;debug&amp;gt; nrf_dfu_ble: Configuring BLE stack.
&amp;lt;debug&amp;gt; nrf_dfu_ble: Enabling the BLE stack.
&amp;lt;debug&amp;gt; nrf_dfu_ble: No advertising name found
&amp;lt;debug&amp;gt; nrf_dfu_ble: Using default advertising name
&amp;lt;debug&amp;gt; nrf_dfu_ble: Advertising...
&amp;lt;debug&amp;gt; nrf_dfu_ble: BLE DFU transport initialized.
&amp;lt;debug&amp;gt; nrf_dfu_flash: Initializing nrf_fstorage_sd backend.
&amp;lt;debug&amp;gt; app: Enter main loop
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Appriciate your help.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364604?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2022 07:28:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c8e07aab-fa3a-477a-aebb-a81caf788157</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Nabeel,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Please check if you have 32kHz crystal on your board ?&amp;nbsp;&lt;br /&gt;If you only flash the softdevice + bootloader would it advertise DFUTarg ?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If it doesn&amp;#39;t you may want to flash the debug version of the bootloader and step into the code and check why it doesn&amp;#39;t advertise. You can debug the bootloader the same way as debugging normal application.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364552?ContentTypeID=1</link><pubDate>Sat, 23 Apr 2022 12:18:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:183d5cb3-e607-432a-bbef-ac8f07bb357e</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364501#364501"]I assume by &amp;quot;&lt;span&gt;pca10100_s140_ble bootloader&amp;quot; you mean the bootloader in &amp;quot;\examples\dfu\secure_bootloader\pca10100_s140_ble&amp;quot;&amp;nbsp; ?&amp;nbsp;&lt;/span&gt;[/quote]
&lt;p&gt;Yes.&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364501#364501"]I would suggest to get familiar with this bootloader before you move to any further step. Make sure you can do a DFU update with this bootloader before trying to implement DFU buttonless.[/quote]
&lt;p&gt;I&amp;#39;ve tried flashing bootloader, softdevice and bootloader setting page in my nRF52833 DK and my custom board. It works fine in DK where I can upload the zip packet and also application runs fine. But while flashing in my custom USB board it doesn&amp;#39;t even advertise as &amp;quot;Dfutarg&amp;quot;.&lt;/p&gt;
&lt;p&gt;why it is so?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364501?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2022 13:38:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d40e0b8f-d9aa-426b-aa37-eefa1ae0a56e</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi again Nabeel,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I assume by &amp;quot;&lt;span&gt;pca10100_s140_ble bootloader&amp;quot; you mean the bootloader in &amp;quot;\examples\dfu\secure_bootloader\pca10100_s140_ble&amp;quot;&amp;nbsp; ?&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;br /&gt;I would suggest to get familiar with this bootloader before you move to any further step. Make sure you can do a DFU update with this bootloader before trying to implement DFU buttonless.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Note that the bootloader, out of the box, works as a peripheral, not a central. You would need to modify it to make it a central with the same services and characteristics.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;The DFU trigger library&amp;nbsp;&lt;span&gt;nrf_dfu_trigger_usb.c has nothing to do with the DFU buttonless. It requires a button to be pressed to put the device to DFU mode. So it may not relevant to your application.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;What you need to do is to study the&amp;nbsp;\examples\ble_peripheral\ble_app_buttonless_dfu and implement the &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/service_dfu.html?cp=8_1_3_3_5"&gt;DFU buttonless service &lt;/a&gt;in your application.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364457?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2022 11:43:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:10d16721-c7f1-462e-81ff-73d3e2b50a02</guid><dc:creator>Nabeel Ar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364446#364446"]Could you point me to the DFU trigger library you are using ?[/quote]
&lt;p&gt;Its in&amp;nbsp;\components\libraries\bootloader\dfu\nrf_dfu_trigger_usb.c and&amp;nbsp;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;\components\libraries\&lt;/span&gt;usbd\class\nrf_dfu_trigger\app_usbd_nrf_dfu_trigger.c&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364446#364446"]Please let me know how you are planning to do DFU update ? Is the USB device advertising as a peripheral and get connected by a phone ?[/quote]
&lt;p&gt;I&amp;#39;m trying to do Buttonless DFU to my custom USB device which acts as a central. My USB device will do the scanning and I&amp;#39;ll connect it with my nrf connect mobile app (advertiser). I&amp;#39;ll initiate the dfu process by clicking the dfu icon in the top right of nrf connect app and I&amp;#39;ll select the zip file and upload it. But it shows &amp;quot;Bootloader not found&amp;quot; error message.&lt;/p&gt;
[quote userid="2121" url="~/f/nordic-q-a/87201/implementing-dfu-trigger-library/364446#364446"]Regarding&amp;nbsp;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;strong&gt;&amp;quot;Bootloader not found&amp;quot; &lt;/strong&gt;error, this means you need to flash the bootloader to be able to use the buttonless service.&amp;nbsp;[/quote]
&lt;p&gt;I&amp;#39;ve flashed&amp;nbsp;pca10100_s140_ble bootloader in it.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Implementing DFU trigger library</title><link>https://devzone.nordicsemi.com/thread/364446?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2022 11:11:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a557ca7-fcdd-45cd-ad5c-944a3952bab2</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Nabeel,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Could you point me to the DFU trigger library you are using ?&amp;nbsp;&lt;br /&gt;&lt;br /&gt;If you are trying to do Buttonless DFU you may want to have a look at this example:&amp;nbsp;\examples\ble_peripheral\ble_app_buttonless_dfu&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t think it has anything to do with the&amp;nbsp;&lt;strong&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;GP pin shortened with the RESET pin.&amp;nbsp;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Please let me know how you are planning to do DFU update ? Is the USB device advertising as a peripheral and get connected by a phone ?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Regarding&amp;nbsp;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;strong&gt;&amp;quot;Bootloader not found&amp;quot; &lt;/strong&gt;error, this means you need to flash the bootloader to be able to use the buttonless service.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I would suggest to get familiar with the bootloader before you implement the buttonless service. I have a tutorial &lt;a href="https://devzone.nordicsemi.com/guides/short-range-guides/b/software-development-kit/posts/getting-started-with-nordics-secure-dfu-bootloader"&gt;here&lt;/a&gt; that might be useful for you.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>