<?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>Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/81402/coexistence-of-2-stacks-nrf-sdk-and-wirepas-sdk</link><description>Hi all. The current devices we are developing are made with NRF52832 based on the NRF SDK v16. We also plan to use the Wirepas stack. Initially, we want to implement support for OTA DFU upgrades from the NRF SDK stack to the Wirepas stack. In this regard</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 02 Dec 2021 14:14:57 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/81402/coexistence-of-2-stacks-nrf-sdk-and-wirepas-sdk" /><item><title>RE: Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/thread/341722?ContentTypeID=1</link><pubDate>Thu, 02 Dec 2021 14:14:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:91e287bc-5103-4c1a-b056-6b5efc9edcf5</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The bootloader protects itself, the MBR, and the Softdevice with BPROT before booting the application. You can &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/81954/how-to-disable-the-bprot-function"&gt;disable (not enable) BPROT&lt;/a&gt;, then&amp;nbsp;it might work.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-Amanda&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/thread/341595?ContentTypeID=1</link><pubDate>Wed, 01 Dec 2021 21:02:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:384c023f-b701-4bbb-ba9f-f26adc11a30b</guid><dc:creator>Evgeniy L</dc:creator><description>&lt;p&gt;Hi, sorry for the long reply and thank you for your help with this issue.&lt;/p&gt;
&lt;p&gt;The problem is that the Wirepas bootloader also needs to be at 0 address in memory as well as the MBR.&lt;/p&gt;
&lt;p&gt;Is there any way to overwrite MBR+Softdevice not in the OTA DFU stage, but from a custom application? I.e. first we get an image of the Wirepas stack via OTA DFU and write it to the flash, and then after a device reboot, we overwrite the MBR+Softdevice with the Wirepas stack?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/thread/337768?ContentTypeID=1</link><pubDate>Fri, 05 Nov 2021 21:15:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a6f0a145-fb81-4c0c-b1d1-d9e3929429ef</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;It&amp;#39;s not possible to safely update the MBR through DFU, so you should ideally relocate the wirepas bootloader to where we have the nRF5 bootloader.&amp;nbsp;&amp;nbsp;Then, you could update wirepas bootloader and the&amp;nbsp;wirepas application image in one go by calling it a Softdevice+bootloader (&lt;a title="SoftDevice and bootloader" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_bootloader_dfu_banks.html?cp=7_1_3_5_1_2_0_0#lib_bootloader_dfu_dual_banks_sd"&gt;SoftDevice and bootloader&lt;/a&gt;) update. So, this is able to overwrite the softdevice with the wirepas app. However, it did require some minor modifications to the existing bootloader to make it accept the&amp;nbsp;wirepas application as a Softdevice image as the following&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;nrf_bootloader_fw_activation.c,&amp;nbsp;in function&amp;nbsp;sd_activate():&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;if (SD_MAGIC_NUMBER_GET(src_addr) != SD_MAGIC_NUMBER)
{
    NRF_LOG_ERROR(&amp;quot;Source address does not contain a valid SoftDevice.&amp;quot;)
    //return NRF_ERROR_INTERNAL;     &amp;lt;&amp;lt; commented out this line
}&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;nrf_dfu_validation.c, in function softdevice_info_ok():&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static bool softdevice_info_ok(uint32_t sd_start_addr, uint32_t sd_size)
{
    bool result = true;

    if (SD_MAGIC_NUMBER_GET(sd_start_addr) != SD_MAGIC_NUMBER)
    {
        NRF_LOG_ERROR(&amp;quot;The SoftDevice does not contain the magic number identifying it as a SoftDevice.&amp;quot;);
        //result = false; //hack to accept zephyr images
    }&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Here is the SDK&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/nRF5_5F00_SDK_5F00_16.0.0_5F00_98a08e2_5F00_accept_5F00_application_5F00_as_5F00_Softdevice.zip"&gt;devzone.nordicsemi.com/.../nRF5_5F00_SDK_5F00_16.0.0_5F00_98a08e2_5F00_accept_5F00_application_5F00_as_5F00_Softdevice.zip&lt;/a&gt; with the above modifications.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The package generate command might look like this:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;nrfutil pkg generate --hw-version 52 --app-boot-validation VALIDATE_GENERATED_CRC ^
--bootloader-version 3 ^
--sd-req 0x0000 ^
--softdevice wirepas_app_update.hex ^
--bootloader wirepas_bootloader.hex ^
--key-file private.pem wirepas_bt_app.zip&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-Amanda&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/thread/337647?ContentTypeID=1</link><pubDate>Fri, 05 Nov 2021 10:14:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:778c87f5-e195-480d-b67f-0597953335b1</guid><dc:creator>Evgeniy L</dc:creator><description>&lt;p&gt;Hi, Amanda. Thank you for your reply.&lt;/p&gt;
&lt;p&gt;1. During OTA-DFU process, the Softdevice of course cannot be removed until the Wirepas stack image is loaded into Flash memory.&amp;nbsp;After rebooting the device, the Softdevice can be removed.&lt;/p&gt;
&lt;p&gt;2. The Wirepas stack bootloader also assumes a location at address 0. However, it allows user functions to be executed during the early boot phase.&lt;br /&gt;&lt;br /&gt;&lt;span&gt;Regards,&lt;/span&gt;&lt;br /&gt;Djaison&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Coexistence of 2 stacks: NRF SDK and Wirepas SDK</title><link>https://devzone.nordicsemi.com/thread/337641?ContentTypeID=1</link><pubDate>Fri, 05 Nov 2021 09:50:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a05959a-d83b-4ee3-ad4e-ed9e742755ef</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;We at Nordic are not developing the Wirepas stack ant not familiar with it. Could you kindly provide more detail for us?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;1. Will the updated image replace softdevice?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;2.&amp;nbsp;Is it not possible to keep the mbr at address 0?&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Regards,&lt;br /&gt;Amanda&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>