<?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>Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue</link><description>I use 3.10 mesh sd and 2 dk boards. 
 DFU example works fine, but when I try to implement dfu mode in ls example I can&amp;#39;t achieve goal. DFU doesn&amp;#39;t work. I follow the instruction of the dfu example, but Istead of the dfu hex file I use hex file from the</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 06 Jan 2020 14:11:13 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue" /><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/227707?ContentTypeID=1</link><pubDate>Mon, 06 Jan 2020 14:11:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:10d40d4e-b3f9-46c3-9fac-9e3ddc5e49c3</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Have you called&amp;nbsp;nrf_mesh_dfu_init()? nrf_mesh_dfu_enable() will return NRF_ERROR_NOT_SUPPORTED if&amp;nbsp;m_cmd_handler == NULL. Is that the case?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226689?ContentTypeID=1</link><pubDate>Sun, 22 Dec 2019 20:08:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d412b8dc-5348-49fe-a543-2663866bf347</guid><dc:creator>UdjinPr</dc:creator><description>&lt;p&gt;and&amp;nbsp;&lt;span&gt;nrf_mesh_dfu_enable() return&amp;nbsp;NRF_ERROR_NOT_SUPPORTED&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226677?ContentTypeID=1</link><pubDate>Sat, 21 Dec 2019 20:42:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:79434d26-a5b8-4c0e-9db1-a21b751226e6</guid><dc:creator>UdjinPr</dc:creator><description>&lt;p&gt;I have tried to do it with mesh 4.0. Result the same - no events.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/226296"][/quote]&lt;/p&gt;
&lt;p&gt;&lt;span&gt;nrfutil --verbose dfu serial -pkg dfu_test.zip -p &amp;lt;COM port&amp;gt; -b 115200 -fc --mesh&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Please copy all the text from your cmd window after using this command&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;E:\Nordic\nrf5SDKforMeshv310src&amp;gt;nrfutil --verbose dfu serial -pkg dtest.zip -p COM3 -b 115200 -fc --mesh&lt;br /&gt;Upgrading target on COM3 with DFU package E:\Nordic\nrf5SDKforMeshv310src\dtest.zip. Flow control is enabled.&lt;br /&gt;Flushing com-port...&lt;br /&gt;Opened com-port&lt;br /&gt;Starting DFU upgrade of type 4, SoftDevice size: 0, bootloader size: 0, application size: 2468&lt;br /&gt;Sending DFU start packet, afterwards we wait for the flash on target to be initialized before continuing.&lt;br /&gt;PC -&amp;gt; target: 0502aabbccdd&lt;br /&gt;target -&amp;gt; PC: 0582aabbccdd&lt;br /&gt;Got echo response&lt;br /&gt;Sending DFU init packet&lt;br /&gt;PC -&amp;gt; target: 1378fdff040fb0d4b7c859000000010002000000&lt;br /&gt;target -&amp;gt; PC: 16a6045900000001000200000059000000010001000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1378fdff040fb0d4b7c859000000010002000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1478fcff0000b0d4b7c8ffffffff6902000040000c&lt;br /&gt;target -&amp;gt; PC: 0da2010459000000010002000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;Sending firmware file&lt;br /&gt; [------------------------------------] 1% 00:11:50PC -&amp;gt; target: 1978fcff0100b0d4b7c800fd0020456802006d6802006f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0200b0d4b7c871680200736802007568020000000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [------------------------------------] 2% 00:11:41PC -&amp;gt; target: 1978fcff0300b0d4b7c800000000000000000000000077680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0400b0d4b7c879680200000000007b6802007d680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [#-----------------------------------] 3% 00:07:45PC -&amp;gt; target: 1978fcff0500b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0600b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [#-----------------------------------] 4% 00:06:11PC -&amp;gt; target: 1978fcff0700b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0800b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [##----------------------------------] 6% 00:05:16PC -&amp;gt; target: 1978fcff0900b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0a00b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [##----------------------------------] 7% 00:04:39PC -&amp;gt; target: 1978fcff0b00b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0c00b0d4b7c87f6802007f6802000000000000000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [###---------------------------------] 8% 00:04:12PC -&amp;gt; target: 1978fcff0d00b0d4b7c87f6802007f6802007f6802007f680200&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt;PC -&amp;gt; target: 1978fcff0e00b0d4b7c87f6802007f6802007f68020000000000&lt;br /&gt;target -&amp;gt; PC: 03847800&lt;br /&gt; [###---------------------------------] 9% 00:03:51PC -&amp;gt; target: 1978fcff0f00b0d4b7c800000000000000000000000000000000&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226296?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2019 08:44:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c709efa0-ec5a-4fe4-b73b-1bdc6af07475</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Are you using nrfutil with this device directly, since you have&amp;nbsp;&lt;span&gt;NRF_MESH_SERIAL_ENABLE = 1? If not, can you please try?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;What is the output from your nrfutil command? Can you please try to use the command with more verbose output:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;nrfutil --verbose dfu serial -pkg dfu_test.zip -p &amp;lt;COM port&amp;gt; -b 115200 -fc --mesh&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Please copy all the text from your cmd window after using this command&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226168?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 13:51:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:02a2d4f4-6891-4fe3-99d5-1748a271cce2</guid><dc:creator>UdjinPr</dc:creator><description>[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/226108"]But then you basically have the same project as the DFU, except that you don&amp;#39;t have the same project settings as in the DFU project. Is your plan to add the light switch client afterwards?[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I did it because&amp;nbsp; i couldn&amp;#39;t adjust light switch example to work in DFU mode and at the very last just had replaced main.c.&lt;/p&gt;
[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/226108"]Have you tried to do any debugging? Did you receive any of the DFU events?[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I am debugging via&amp;nbsp;RTT and yes there are no events.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226108?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 10:49:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:34a83111-9911-4fd2-9ea4-15f42e1ce44a</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;But then you basically have the same project as the DFU, except that you don&amp;#39;t have the same project settings as in the DFU project. Is your plan to add the light switch client afterwards?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Have you tried to do some debugging? Can you explain what you mean by &amp;quot;DFU doesn&amp;#39;t work&amp;quot;?&lt;/p&gt;
&lt;p&gt;Have you tried to do any debugging? Did you receive any of the DFU events?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226062?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 09:30:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dc5c1b51-c7fb-4b98-a24a-af7d8a5ec103</guid><dc:creator>UdjinPr</dc:creator><description>&lt;p&gt;Yes I have,&amp;nbsp; I thought in this case it must work.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/226034?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 08:20:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a4615d07-3964-4bf3-ab96-c5d8ceb170d8</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Have you just replaced the main.c in the light_switch\client example with the main.c file from the dfu example?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/225985?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2019 21:17:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7c619165-2f1d-4585-873e-79314ae71d2f</guid><dc:creator>UdjinPr</dc:creator><description>&lt;p&gt;Hello, Thank you for your reply. As i sad before I copied main.c from dfu exampel and replaced it main.c in ls example.&amp;nbsp;&lt;/p&gt;
[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/225969"]Also, I suggest that to get thing up and running, you should use the default DFU example with&amp;nbsp;NRF_MESH_SERIAL_ENABLE = 1 to broadcast the DFU images.[/quote]
&lt;p&gt;Yes, It is enaeble.&lt;/p&gt;
[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/225969"]So in your light switch clients, you need the bootloader, that you use when you test the default DFU examples, which you can find in:[/quote]
&lt;p&gt;I use bootloader and a device page as in the dfu example.&lt;/p&gt;
&lt;p&gt;[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/225969"][/quote]&lt;/p&gt;
&lt;p&gt;hen, you make sure that inside main() -&amp;gt; initialize() -&amp;gt;&amp;nbsp;mesh_init() -&amp;gt;&amp;nbsp;nrf_mesh_evt_handler_add(&amp;amp;m_evt_handler);&lt;/p&gt;
&lt;p&gt;with m_evt_handler.mesh_evt_handler;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I have&amp;nbsp;&lt;span&gt;nrf_mesh_evt_handler_add() in main.c becouse of i use main.c from dfu example.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;[quote userid="26071" url="~/f/nordic-q-a/55722/lifght-switch-client-example-with-dfu-issue/225969"][/quote]&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Also, make sure that&amp;nbsp;nrf_mesh_dfu_enable() is called, like it is in the dfu example:&lt;/p&gt;
&lt;p&gt;main() -&amp;gt; start() -&amp;gt;&amp;nbsp;mesh_stack_start() -&amp;gt;&amp;nbsp;nrf_mesh_enable() -&amp;gt;&amp;nbsp;nrf_mesh_dfu_enable()&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I double checked, it is called.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;and about HOST. I suppose it is difined, but i couldn&amp;#39;t finde place where.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/225969?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2019 17:29:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d256e42d-da88-4086-ac2c-227de57d8679</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Did you add the mesh event callback for the DFU events in your light switch clients?&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static void mesh_evt_handler(const nrf_mesh_evt_t* p_evt)
{
    switch (p_evt-&amp;gt;type)
    {
        case NRF_MESH_EVT_DFU_FIRMWARE_OUTDATED:
        case NRF_MESH_EVT_DFU_FIRMWARE_OUTDATED_NO_AUTH:
            if (fw_updated_event_is_for_me(&amp;amp;p_evt-&amp;gt;params.dfu))
            {
                ERROR_CHECK(nrf_mesh_dfu_request(p_evt-&amp;gt;params.dfu.fw_outdated.transfer.dfu_type,
                                                 &amp;amp;p_evt-&amp;gt;params.dfu.fw_outdated.transfer.id,
                                                 (uint32_t*) bank_addr));
                hal_led_mask_set(LEDS_MASK, false); /* Turn off all LEDs */
            }
            else
            {
                ERROR_CHECK(nrf_mesh_dfu_relay(p_evt-&amp;gt;params.dfu.fw_outdated.transfer.dfu_type,
                                               &amp;amp;p_evt-&amp;gt;params.dfu.fw_outdated.transfer.id));
            }
            break;

        case NRF_MESH_EVT_DFU_START:
            hal_led_mask_set(BSP_LED_0_MASK | BSP_LED_2_MASK, true);
            break;

        case NRF_MESH_EVT_DFU_END:
            hal_led_mask_set(LEDS_MASK, false); /* Turn off all LEDs */
            hal_led_mask_set(BSP_LED_0_MASK | BSP_LED_1_MASK, true); /* Yellow */
            break;

        case NRF_MESH_EVT_DFU_BANK_AVAILABLE:
            hal_led_mask_set(LEDS_MASK, false); /* Turn off all LEDs */
            ERROR_CHECK(nrf_mesh_dfu_bank_flash(p_evt-&amp;gt;params.dfu.bank.transfer.dfu_type));
            break;

        default:
            break;

    }
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Also, I suggest that to get thing up and running, you should use the default DFU example with&amp;nbsp;NRF_MESH_SERIAL_ENABLE = 1 to broadcast the DFU images.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So in your light switch clients, you need the bootloader, that you use when you test the default DFU examples, which you can find in:&lt;/p&gt;
&lt;p&gt;SDK\bin\bootloader\gccarmemb\mesh_bootloader_gccarmemb_nrf52832_xxAA.hex&lt;/p&gt;
&lt;p&gt;Then, you make sure that inside main() -&amp;gt; initialize() -&amp;gt;&amp;nbsp;mesh_init() -&amp;gt;&amp;nbsp;nrf_mesh_evt_handler_add(&amp;amp;m_evt_handler);&lt;/p&gt;
&lt;p&gt;with m_evt_handler.mesh_evt_handler;&lt;/p&gt;
&lt;p&gt;and mesh_evt_handler() is the one that I pasted in the snippet above.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Also, make sure that&amp;nbsp;nrf_mesh_dfu_enable() is called, like it is in the dfu example:&lt;/p&gt;
&lt;p&gt;main() -&amp;gt; start() -&amp;gt;&amp;nbsp;mesh_stack_start() -&amp;gt;&amp;nbsp;nrf_mesh_enable() -&amp;gt;&amp;nbsp;nrf_mesh_dfu_enable()&lt;/p&gt;
&lt;p&gt;Is &amp;quot;HOST&amp;quot; Defined in your light_switch client project?&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: Lifght switch client example with DFU issue</title><link>https://devzone.nordicsemi.com/thread/225836?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2019 09:47:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f6f59e54-2d3c-4530-a322-8ea0b5a9f4e3</guid><dc:creator>UdjinPr</dc:creator><description>&lt;p&gt;and some important details: on master node(board which is used for transmission) is used original dfu example, and on the slave board I off serial driver, becouse it clashes with saadc.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>