<?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 to applocation switching issue</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/56239/bootloader-to-applocation-switching-issue</link><description>Hi , 
 I am working on NRF DFU firmware update. for that i am using secure bootloader code . 
 I tried with the of way of flasing bootloader code on my custom board and sent my application code through app(NRF CONNECT) .when want to change the bootloader</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 27 Jan 2020 08:25:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/56239/bootloader-to-applocation-switching-issue" /><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/231027?ContentTypeID=1</link><pubDate>Mon, 27 Jan 2020 08:25:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f67ce1d-07e4-481b-8218-7d62c2fcba67</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Have you checked the DFU master code? I haven&amp;#39;t tested it myself, but it probably contains the slip libraries, and how to transfer the files already. You should be able to use some files from there in your esp project.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/230848?ContentTypeID=1</link><pubDate>Fri, 24 Jan 2020 12:36:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c8f62e03-7b08-4a5c-861b-a08f292037c7</guid><dc:creator>mayuri</dc:creator><description>&lt;p&gt;Thank for supporting&amp;nbsp; &amp;nbsp;,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;trying to work on this .... before that&amp;nbsp;&lt;/p&gt;
&lt;p&gt;to transfer the firmware file into several objects u refered to see the slip library ..&lt;/p&gt;
&lt;p&gt;i saw the slip library in that ,end of bytes as mentioned 300 , when i searched in my firmware file its showing lot of end byts ...i have no idea on transferring the object files ...if u have any idea on slip library and how to seperate the objects can you please tell me ??&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/230782?ContentTypeID=1</link><pubDate>Fri, 24 Jan 2020 07:55:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0078309a-c245-46a9-a728-c1c672dc6185</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Unfortunately, we do not have any source code for esp32. We only have the protocol, so you would have to implement this yourself.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;For inspiration, you can look at the &lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-blogs-components-weblogfiles/00-00-00-00-04/DFUMaster_5F00_UART.zip" rel="noopener noreferrer" target="_blank"&gt;DFU Master&lt;/a&gt; (written for nRF52832). Perhaps you can use some of the files from that projects, but you need to use the UART drivers for esp32.&lt;/p&gt;
&lt;p&gt;The DFU master firmware is linked to in the &lt;a href="https://devzone.nordicsemi.com/nordic/nordic-blog/b/blog/posts/getting-started-with-nordics-secure-dfu-bootloader#h44sjziaea6x739chl3s2bk6zz9163" rel="noopener noreferrer" target="_blank"&gt;DFU getting started guide&lt;/a&gt;, close to the bottom of the page.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/230763?ContentTypeID=1</link><pubDate>Fri, 24 Jan 2020 05:06:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:75df2e91-4dd7-47a3-aade-6128ce3e48d5</guid><dc:creator>mayuri</dc:creator><description>&lt;p&gt;hai ,&lt;/p&gt;
&lt;p&gt;Thanks trying to transfer the objects&amp;nbsp; through ble ..i am strucking in this place to send my firmware file.&lt;/p&gt;
&lt;p&gt;is it possible to update nrf through uart from esp32 . can you any source related on this ..??&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/228736?ContentTypeID=1</link><pubDate>Mon, 13 Jan 2020 09:04:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c402a9ca-bb7b-455c-8c5a-594be3a37a58</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t have much more to point to other than the documentation.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I suggest that you check the documentation for the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v16.0.0%2Flib_dfu_transport.html&amp;amp;cp=7_1_3_5_2" rel="noopener noreferrer" target="_blank"&gt;DFU Protocol&lt;/a&gt;, the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v16.0.0%2Flib_dfu_transport_serial.html&amp;amp;cp=7_1_3_5_2_3" rel="noopener noreferrer" target="_blank"&gt;Serial protocol&lt;/a&gt;, the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v16.0.0%2Flib_dfu_transport_serial.html&amp;amp;cp=7_1_3_5_2_3_1&amp;amp;anchor=lib_dfu_transport_serial_msc" rel="noopener noreferrer" target="_blank"&gt;Message Sequence Chart&lt;/a&gt;&amp;nbsp;and the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v16.0.0%2Flib_slip.html" rel="noopener noreferrer" target="_blank"&gt;SLIP library&lt;/a&gt;&amp;nbsp;to see how to transfer the objects.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;We have an unofficial example that acts as a DFU master. I have not tested it, but perhaps you can look at this for inspiration.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/228657?ContentTypeID=1</link><pubDate>Sat, 11 Jan 2020 05:13:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c24804fa-c262-4e36-94bc-dbf0d44fe0e1</guid><dc:creator>mayuri</dc:creator><description>&lt;p&gt;thanks , now its working fine ...&lt;/p&gt;
&lt;p&gt;now i am tryingto update nrf52840 from my third party (esp32)&lt;/p&gt;
&lt;p&gt;i am able send to init packet&amp;nbsp; and receiving response as per the dfu protocol .&lt;/p&gt;
&lt;p&gt;i am strucking in sending my bin file ... my question is how to send the bin file as 12 objects from my third party ??&lt;/p&gt;
&lt;p&gt;In&amp;nbsp; nrf connect application when send as zip file ,gets parsing first its sending init packet which is dat file and then parsing the bin file as 12 objects&amp;nbsp; &amp;nbsp;..and for each objects&amp;nbsp; calculating crc and its updating&amp;nbsp; ...&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;can you please tell me ??&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/228086?ContentTypeID=1</link><pubDate>Wed, 08 Jan 2020 10:16:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9a153de5-db72-47bc-874d-1d0d58640815</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;If you call:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;NRF_POWER-&amp;gt;GPREGRET = BOOTLOADER_DFU_START;
NVIC_SystemReset();&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;right after one another, it may not actually get time to write to the register before the reset. Try to add a small delay between the two (you can use nrf_delay_ms(10); ). Does that work?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/228060?ContentTypeID=1</link><pubDate>Wed, 08 Jan 2020 09:18:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c56deee0-812f-4741-9c2a-81c6923df328</guid><dc:creator>mayuri</dc:creator><description>&lt;p&gt;Hai ,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;thanks for ur reply , tried as u said now its working fine ....but sometimes from apllication , its not jumpimg to bootloader mode ..&lt;/p&gt;
&lt;p&gt;i am using the follwing command in my application part&amp;nbsp; to switch into bootloader mode&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;#DEFINE&amp;nbsp;&amp;nbsp;BOOTLOADER_DFU_START&amp;nbsp;0xB1&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;NRF_POWER-&amp;gt;GPREGRET = BOOTLOADER_DFU_START;&lt;/p&gt;
&lt;p&gt;NVIC_SystemReset();&lt;/p&gt;
&lt;p&gt;&amp;nbsp;by this way i am using this as buttonless to swtich over&amp;nbsp; ... sometimes i am having this issue ...&lt;/p&gt;
&lt;p&gt;can you please tell me ??????&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks ,&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bootloader to applocation switching issue</title><link>https://devzone.nordicsemi.com/thread/227825?ContentTypeID=1</link><pubDate>Tue, 07 Jan 2020 09:22:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b012d6f3-3cac-4b2c-b9be-0addcb6c5be3</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;The behavior that you see is expected because the bootloader can see that there is an application in flash, but since the application is flashed directly and not via DFU (nRF Connect), the bootloader never verified that the application is signed with the correct private key. This is a safety mechanism.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Usually, when you generate a DFU image, you need to enter the private key as one of the parameters:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;nrfutil pkg generate --application app.hex --application-version 1 --hw-version 52 --sd-req 0xAF --key-file private.key&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;This will create an image including the application, and a signature verifying that the person who generated this packet has access to the private key. When the bootloader receives this image, it will store the CRC of the application and the signature in something called bootloader settings. This means if someone changes the application in this image, the CRC will no longer match, and the singature is no longer valid.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Luckily, there is a way to work around this. If you have access to the private key, you can generate the bootloader settings manually using your private key and merge it together with your application+bootloader, and flash it manually. Now, when this happens, the bootloader will see that the bootloader settings accepts the flashed application, and start the application as if you transferred the application via DFU.&lt;/p&gt;
&lt;p&gt;To generate bootloader settings (bl_settings) you can use the following command:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;nrfutil settings generate --family NRF52840 --application app.hex --application-version 1 --bootloader-version 1 --bl-settings-version 1 --key-file private.key bl_settings.hex&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;(use &amp;quot;nrfutil settings generate --help&amp;quot; for more information)&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;now merge your hex file:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;mergehex.exe -m final.hex bl_settings.hex -o final_with_bl_settings.hex&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;and program it using&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;nrfjprog --program final_with_bl_settings.hex --verify &amp;amp;&amp;amp; nrfjprog --reset&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;And it should start the application.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>