<?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>Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/31031/bootloader-problem-code-3</link><description>Hello, 
 I use the bootloader from the SDK SoftDevice 14.0.0. 
 I use the Laird module BL652 which have a nRF52832 component without external clock. 
 To compile the bootloader, I use the source code from : examples\dfu\bootloader_secure_ble\pca10040_debug</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 03 Apr 2018 07:29:07 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/31031/bootloader-problem-code-3" /><item><title>RE: Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/thread/126586?ContentTypeID=1</link><pubDate>Tue, 03 Apr 2018 07:29:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:831ba77e-4c5e-44e1-a782-919f08e368eb</guid><dc:creator>Bj&amp;#248;rn Kvaale</dc:creator><description>&lt;p&gt;Great! Good to hear that you figured it out! Good luck with further development.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/thread/126411?ContentTypeID=1</link><pubDate>Thu, 29 Mar 2018 17:45:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8fc5bc6c-d43b-4705-bd7c-03a010455734</guid><dc:creator>d.altmann</dc:creator><description>&lt;p&gt;Hi Bjorn,&lt;/p&gt;
&lt;p&gt;I have recompile the bootloader source code with Release part (with private/public key, etc....) and I have update my &amp;quot;nRFUtils&amp;quot;.&lt;/p&gt;
&lt;p&gt;I follows your tutorials to compile the different source code and I works good (I use the new Gcc (Version 7-2017) to compile all without error.&lt;/p&gt;
&lt;p&gt;Now, All work fine.&lt;/p&gt;
&lt;p&gt;Thank to your helps.&lt;/p&gt;
&lt;p&gt;We can close this post.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Damien&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/thread/123287?ContentTypeID=1</link><pubDate>Wed, 07 Mar 2018 15:11:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:25847e48-d5cf-4ddb-8861-e8d3c667f1d0</guid><dc:creator>Bj&amp;#248;rn Kvaale</dc:creator><description>&lt;p&gt;Hi Damien,&lt;/p&gt;
&lt;p&gt;Regarding the custom board file, it might be useful to check &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/18910/supporting-a-custom-board-with-nrf5-sdk-examples" rel="noopener noreferrer" target="_blank"&gt;this link&lt;/a&gt;&amp;nbsp;(&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/18554/custom-board-pin-mapping" rel="noopener noreferrer" target="_blank"&gt;see this case too&lt;/a&gt;). In addition, &lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v14.2.0/sdk_for_custom_boards.html?cp=4_0_0_1_5_2#custom_board_support" rel="noopener noreferrer" target="_blank"&gt;this infocenter document&lt;/a&gt; could be helpful.&lt;/p&gt;
&lt;p&gt;Regarding the RC source, the NRF_SDH_CLOCK_LF_SRC 0 is the only change you need to make. So this step is correct if you want to use the internal Low Frequency RC oscillator.&lt;/p&gt;
&lt;p&gt;When you say that the nrf52832 component does not have an external clock, you are referring to the 32 kHz low frequency clock, right? Because the Laird module has a 32 MHz high frequency external crystal oscillator according to &lt;a href="https://assets.lairdtech.com/home/brandworld/files/Datasheet%20-%20BL652%20v2_5.pdf" rel="noopener noreferrer" target="_blank"&gt;the datasheet&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Could be a good idea to update to nrfUtil v 3.5.0, although I have gotten this to work with 3.4.0 too.&lt;/p&gt;
&lt;p&gt;Like you mention, it could also be a good idea to use the release version of the bootloader project with the private key. I have a feeling this might be related to the board file maybe, as this example works fine with the nrf52dk when following the &lt;a href="https://devzone.nordicsemi.com/b/blog/posts/getting-started-with-nordics-secure-dfu-bootloader" rel="noopener noreferrer" target="_blank"&gt;secure dfu blog post&lt;/a&gt;. You can use the same nrfutil command as given in the blog post.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Hope that helps! Kind Regards,&lt;/p&gt;
&lt;p&gt;Bjørn Kvaale&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/thread/123164?ContentTypeID=1</link><pubDate>Wed, 07 Mar 2018 06:07:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3fdb1254-020e-4378-9eac-67b3ad6d1334</guid><dc:creator>d.altmann</dc:creator><description>&lt;p&gt;Hi Bjorn,&lt;/p&gt;
&lt;p&gt;In bootloader project, I have made a custom_Board file:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#define NRF_CLOCK_LFCLKSRC      {.source       = NRF_CLOCK_LF_SRC_RC,      \
                                 .rc_ctiv      = 16,                          \
                                 .rc_temp_ctiv = 2,                          \
                                 .accuracy     =  NRF_CLOCK_LF_XTAL_ACCURACY_20_PPM}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Into the sdk_config.h, I enable the RC source:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#ifndef NRF_SDH_CLOCK_LF_SRC
#define NRF_SDH_CLOCK_LF_SRC 0
#endif&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;--&amp;gt; I have to enable another part for active the RC source ??&lt;/p&gt;
&lt;p&gt;- Ok, I try to follow this blog.&lt;/p&gt;
&lt;p&gt;- The nrfUtil version is the 3.4.0.&lt;/p&gt;
&lt;p&gt;--&amp;gt; Can I shall be update it ?&lt;/p&gt;
&lt;p&gt;- I try your command but the nRFutil have a error because it missing the hw-version and the sd-req. I add this 2 parameters.&lt;/p&gt;
&lt;p&gt;My new command line is:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;nrfutil pkg generate --debug-mode --application application.hex app_dfu_package.zip --hw-version 52 --sd-req 0x9D&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I have try with this new file&amp;nbsp;app_dfu_package.zip but the result is the same. The error (code = 3) appears.&lt;/p&gt;
&lt;p&gt;Perhaps, I try to compile the bootloader project with release version (no debug version) with a private key...&lt;/p&gt;
&lt;p&gt;Thank you,&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Damien&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader problem (code = 3)</title><link>https://devzone.nordicsemi.com/thread/123004?ContentTypeID=1</link><pubDate>Tue, 06 Mar 2018 10:08:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:84538cf5-0400-4c7e-8899-016e274cb1ab</guid><dc:creator>Bj&amp;#248;rn Kvaale</dc:creator><description>&lt;p&gt;Hi Damien,&lt;/p&gt;
&lt;p&gt;Did you remember to change the clock to internal RC for both the nrf52 chip &amp;amp; the softdevice? Also, &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v14.0.0/ble_sdk_app_dfu_bootloader.html?cp=4_0_2_4_3_0" rel="noopener noreferrer" target="_blank"&gt;did you follow the testing link provided here&lt;/a&gt;? In addition, this blog post might be useful. It is based on the same testing procedure.&lt;/p&gt;
&lt;p&gt;Which version of nrfutil are you running (you can check this by running the command: nrfutil version)?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I believe if you are not using the secure private key, you might need to run this command instead:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nrfutil pkg generate --debug-mode --application application.hex app_dfu_package.zip&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This will skip version information (hardware version, softdevice firmware ID &amp;amp; application version) &amp;amp; generate an unsigned debug package (&lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.tools/dita/tools/nrfutil/nrfutil_pkg.html?cp=5_5_3" rel="noopener noreferrer" target="_blank"&gt;see link&lt;/a&gt;).&lt;/p&gt;
&lt;p&gt;I would&amp;nbsp;then perform the DFU like you have done using nrf connect for android only uploading the zip file created (i.e. app_dfu_package.zip). Hope that helps!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>