<?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>Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73049/is-it-possible-to-program-an-application-on-nrf52832-using-ses-if-i-have-buttonless-dfu-implemented</link><description>Hello! 
 I am working on a project where we want over the air updates for the finished product. To make that possible I implemented the buttonless DFU and it is working great! 
 My current issue is that now that a bootloader has been added to the device</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 24 Mar 2021 08:54:09 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73049/is-it-possible-to-program-an-application-on-nrf52832-using-ses-if-i-have-buttonless-dfu-implemented" /><item><title>RE: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301600?ContentTypeID=1</link><pubDate>Wed, 24 Mar 2021 08:54:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ad433df2-e43f-428f-b48d-d3c76f84cce3</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Happy to know the issue is fixed.&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: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301566?ContentTypeID=1</link><pubDate>Wed, 24 Mar 2021 02:36:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b913af31-8f0e-4477-b225-ef5ba5571373</guid><dc:creator>mort809</dc:creator><description>&lt;p&gt;Thank you for your response, The CRC check was what I was looking for and it fixed my issue.&lt;/p&gt;
&lt;p&gt;For added information, I looked at the articles you linked and verified that my project already had those implemented. The first link talked about&amp;nbsp;NRF_BL_APP_CRC_CHECK_SKIPPED_ON_GPREGRET2 and&amp;nbsp;NRF_BL_APP_CRC_CHECK_SKIPPED_ON_SYSTEMOFF_RESET being set in the sdk_config.h file of the bootloader project. Both were already set to 1, so that wasn&amp;#39;t the issue.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The second link mentioned a function&amp;nbsp;&lt;span&gt;nrf_dfu_app_is_valid() which doesn&amp;#39;t show in either my bootloader project or the application project I&amp;#39;m basing my work off of. I am assuming that this function has been replaced somewhere, but because the link is from 3 years ago I&amp;#39;m not sure what it would have been changed to.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;My solution to the problem ended up being a setting when creating the bootloader settings file. In addition to the command I posted originally I added the command&amp;nbsp;&lt;strong&gt;--app-boot-validation NO_VALIDATION&amp;nbsp;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;This seems to indicate to the bootloader that it doesn&amp;#39;t need to perform the CRC check and that it can boot into the application. I have tested the new settings and everything is working smoothly now.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thank you for your time. It would be helpful to have a tutorial or an updated explanation of the &amp;quot;nrfutil settings generate&amp;quot; command somewhere, the documentation is lacking and the --help message gives possible options, but I wasn&amp;#39;t able to find a good resource to explain those options.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;My final command was in the following form:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;nrfutil settings generate --app-boot-validation NO_VALIDATION --softdevice s132_nrf52_7.2.0_softdevice.hex --key-file PRIVATE KEY LOCATION --family NRF52 --application APPLICATION HEX --application-version-string &amp;quot;VERSION NUMBER&amp;quot; --bl-settings-version 2 --bootloader-version 0 OUTPUT HEX FILE&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301357?ContentTypeID=1</link><pubDate>Tue, 23 Mar 2021 09:50:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c12f0716-1bf3-4fc5-90ad-4f1e291bc090</guid><dc:creator>Amanda Hsieh</dc:creator><description>[quote user="mort809"]Now that I have the bootloader and the DFU service implemented, is it no longer possible to simply program the application via Segger embedded studio?[/quote]
&lt;p&gt;Programming the softdevice, bootloader and&amp;nbsp;&lt;span&gt;bootloader settings before you load the app via segger.&amp;nbsp;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mort809"]How can we get the bootloader to not assert itself when the application changes, but the rest of the firmware (bootloader, softdevice, bl_settings) dont?[/quote]
&lt;p&gt;&lt;span&gt;You can skip the integrity check. N&lt;/span&gt;&lt;span&gt;ote that SDK 17&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v17.0.2%2Flib_bootloader.html&amp;amp;anchor=lib_bootloader_settings_page"&gt;added optional skipping of application CRC check&lt;/a&gt;&lt;span&gt;. CRC check can be skipped on wakeup from System Off or on special value written to GPREGRET2 register (when bit 1 (0-indexed) is set in the GPREGRET2 register).&lt;/span&gt;&lt;/p&gt;
[quote user="mort809"]Do I have to create a new bootloader settings file each time I want to program the device?[/quote]
&lt;p&gt;&lt;span&gt;No, if you skip the&amp;nbsp;integrity check, you don&amp;#39;t need to do this.&amp;nbsp;&lt;/span&gt;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/32493/how-to-debug-application-code-after-add-other-service-to-bottonless-dfu/125413#125413"&gt;See this post&lt;/a&gt;&lt;span&gt;.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-Amanda H.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301304?ContentTypeID=1</link><pubDate>Mon, 22 Mar 2021 22:41:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:271010a7-6c61-40c6-887d-f3e67714c75e</guid><dc:creator>mort809</dc:creator><description>&lt;p&gt;I performed the steps as you have them outlined here. The device programmed correctly, just as I was able to do previously, but is still showing the same behavior as before when I try to program a slightly altered version of the application firmware without reprogramming the entire device.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;This goes back to my original question: Now that I have the bootloader and the DFU service implemented, is it no longer possible to simply program the application via Segger embedded studio? How can we get the bootloader to not assert itself when the application changes, but the rest of the firmware (bootloader, softdevice, bl_settings) dont?&lt;/p&gt;
&lt;p&gt;Do I have to create a new bootloader settings file each time I want to program the device?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301244?ContentTypeID=1</link><pubDate>Mon, 22 Mar 2021 14:23:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ae292024-2797-4df3-bdb2-42f1d9554702</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Try the command to generate the bootloader setting:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;nrfutil settings generate --family NRF52 --application app.hex --application-version &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt; --bootloader-version &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt; --bl-settings-version &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt; settings.hex&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;merge Softdevice and bootloader:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;mergehex -m softdevice.hex bootloader.hex&amp;nbsp;-o merged_SD_bootloader.hex&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;nrfjprog --program merged_SD_bootloader.hex --chiperase&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;merge&amp;nbsp;bootloader setting with app image:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;mergehex -m app.hex settings.hex -o merged.hex&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;nrfjprog --program merged.hex --sectorerase&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&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: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301223?ContentTypeID=1</link><pubDate>Mon, 22 Mar 2021 13:40:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3a5b9494-5e7f-4827-a0ba-951f191bdd96</guid><dc:creator>mort809</dc:creator><description>&lt;p&gt;Thanks for your response Amanda,&lt;/p&gt;
&lt;p&gt;I have previously generated a bootloader settings page, but the problem persists. I&amp;#39;ll upload that settings hex along with the command that I used to generate it to see if you can find the setting I missed.&amp;nbsp;&lt;pre class="ui-code" data-mode="text"&gt;:020000040007F3
:10E00000AF7BBD8E0200000058020000000000003F
:10E010000000000000000000A4830100DA38366729
:10E0200001000000000000000000000000000000EF
:10E03000000000006C490200000000000000000029
:10E0400000000000000000000000000000000000D0
:10E0500000000000000000000000000000000000C0
:10E0600000000000000000000000000000000000B0
:10E0700000000000000000000000000000000000A0
:10E080000000000000000000000000000000000090
:10E090000000000000000000000000000000000080
:10E0A0000000000000000000000000000000000070
:10E0B0000000000000000000000000000000000060
:10E0C0000000000000000000000000000000000050
:10E0D0000000000000000000000000000000000040
:10E0E0000000000000000000000000000000000030
:10E0F0000000000000000000000000000000000020
:10E10000000000000000000000000000000000000F
:10E1100000000000000000000000000000000000FF
:10E1200000000000000000000000000000000000EF
:10E1300000000000000000000000000000000000DF
:10E1400000000000000000000000000000000000CF
:10E1500000000000000000000000000000000000BF
:10E1600000000000000000000000000000000000AF
:10E17000000000000000000000000000000000009F
:10E18000000000000000000000000000000000008F
:10E19000000000000000000000000000000000007F
:10E1A000000000000000000000000000000000006F
:10E1B000000000000000000000000000000000005F
:10E1C000000000000000000000000000000000004F
:10E1D000000000000000000000000000000000003F
:10E1E000000000000000000000000000000000002F
:10E1F000000000000000000000000000000000001F
:10E20000000000000000000000000000000000000E
:10E2100000000000000000000000000000000000FE
:10E2200000000000000000000000000000000000EE
:10E2300000000000000000000000000000000000DE
:10E2400000000000000000000000000000000000CE
:10E25000000000000000000000000000EB401AA6D3
:10E2600001432AE3D5000000000000000000000088
:10E27000000000000000000000000000000000009E
:10E28000000000000000000000000000000000008E
:10E29000000000000000000000000000000000007E
:10E2A0000001DA38366700000000000000000000BE
:10E2B000000000000000000000000000000000005E
:10E2C000000000000000000000000000000000004E
:10E2D000000000000000000000000000000000003E
:10E2E000000000000000000000000000000000002E
:10E2F000000000000000000000000000000000001E
:10E30000000000000000000000000000000000000D
:10E3100000000000000000000000000000000000FD
:03E32000000000FA
:10F00000AF7BBD8E0200000058020000000000002F
:10F010000000000000000000A4830100DA38366719
:10F0200001000000000000000000000000000000DF
:10F03000000000006C490200000000000000000019
:10F0400000000000000000000000000000000000C0
:10F0500000000000000000000000000000000000B0
:10F0600000000000000000000000000000000000A0
:10F070000000000000000000000000000000000090
:10F080000000000000000000000000000000000080
:10F090000000000000000000000000000000000070
:10F0A0000000000000000000000000000000000060
:10F0B0000000000000000000000000000000000050
:10F0C0000000000000000000000000000000000040
:10F0D0000000000000000000000000000000000030
:10F0E0000000000000000000000000000000000020
:10F0F0000000000000000000000000000000000010
:10F1000000000000000000000000000000000000FF
:10F1100000000000000000000000000000000000EF
:10F1200000000000000000000000000000000000DF
:10F1300000000000000000000000000000000000CF
:10F1400000000000000000000000000000000000BF
:10F1500000000000000000000000000000000000AF
:10F16000000000000000000000000000000000009F
:10F17000000000000000000000000000000000008F
:10F18000000000000000000000000000000000007F
:10F19000000000000000000000000000000000006F
:10F1A000000000000000000000000000000000005F
:10F1B000000000000000000000000000000000004F
:10F1C000000000000000000000000000000000003F
:10F1D000000000000000000000000000000000002F
:10F1E000000000000000000000000000000000001F
:10F1F000000000000000000000000000000000000F
:10F2000000000000000000000000000000000000FE
:10F2100000000000000000000000000000000000EE
:10F2200000000000000000000000000000000000DE
:10F2300000000000000000000000000000000000CE
:10F2400000000000000000000000000000000000BE
:10F25000000000000000000000000000EB401AA6C3
:10F2600001432AE3D5000000000000000000000078
:10F27000000000000000000000000000000000008E
:10F28000000000000000000000000000000000007E
:10F29000000000000000000000000000000000006E
:10F2A0000001DA38366700000000000000000000AE
:10F2B000000000000000000000000000000000004E
:10F2C000000000000000000000000000000000003E
:10F2D000000000000000000000000000000000002E
:10F2E000000000000000000000000000000000001E
:10F2F000000000000000000000000000000000000E
:10F3000000000000000000000000000000000000FD
:10F3100000000000000000000000000000000000ED
:03F32000000000EA
:00000001FF
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Command:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span&gt;nrfutil settings generate --softdevice s132_nrf52_7.2.0_softdevice.&lt;/span&gt;&lt;span&gt;hex --key-file PRIVATE KEY LOCATION --family NRF52 --application APPLICATION HEX --application-version-string &amp;quot;VERSION NUMBER&amp;quot; --bl-settings-version 2 --bootloader-version 0 OUTPUT HEX FILE&amp;nbsp;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;span&gt;Using mergehex I then merged that file with the bootloader and the softdevice, and in turn merged those files with the application to generate the file that I program. I&amp;#39;ll detail the steps I followed below.&lt;/span&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span&gt;mergehex --merge BOOTLOADER SETTINGS HEX secure_bootloader_ble_s132_pca10040.hex s132_nrf52_7.2.0_softdevice.hex --output OUTPUT HEX FILE&amp;nbsp;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;mergehex --merge (OUTPUT FROM LAST STEP) ( APPLICATION HEX) --output (OUTPUT FILE NAME)&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Again the issue I&amp;#39;m having is that I cannot use SES to load new application versions once the I&amp;#39;ve programmed this file. This makes debugging very time consuming as for each change I need to follow all of these steps to create a new version instead of simply pressing build and run from SES.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;What setting did I miss?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?</title><link>https://devzone.nordicsemi.com/thread/301200?ContentTypeID=1</link><pubDate>Mon, 22 Mar 2021 12:45:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6e77bed1-3555-49f1-8c70-24db10db3518</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
[quote user=""]Is there a way to program the device using SES while the bootloader is present? For example a setting that I could set up while creating the bootloader settings file that tells it to ignore changes made in the application?[/quote]
&lt;p&gt;You need to generate a HEX file that contains the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_bootloader.html#lib_bootloader_settings_page"&gt;Bootloader Settings page&lt;/a&gt;. See the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ug_nrfutil/UG/nrfutil/nrfutil_intro.html"&gt;nrfutil documentation&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;for instructions. To program a bootloader settings HEX file, use&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ug_nrf5x_cltools/UG/cltools/nrf5x_mergehex.html"&gt;mergehex&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;(part of the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ug_nrf5x_cltools/UG/cltools/nrf5x_command_line_tools_lpage.html"&gt;nRF5x Command Line Tools&lt;/a&gt;) to merge the bootloader HEX file and the bootloader settings HEX file.&lt;/p&gt;
&lt;p&gt;-Amanda H.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>