<?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>NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/116665/nrf7002-dk-system-shutdown</link><description>Hi, 
 Background: 
 
 We&amp;#39;re developing wireless application with the NRF5340-NRF7002 chipset, similar to what&amp;#39;s on the 7002DK board. 
 We&amp;#39;d like to put the system to lowest power mode when it&amp;#39;s not being used. 
 I found two samples related to this: nrf</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 22 Jul 2025 21:04:18 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/116665/nrf7002-dk-system-shutdown" /><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/543256?ContentTypeID=1</link><pubDate>Tue, 22 Jul 2025 21:04:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9970ac56-8f21-4579-a0ea-0670dd5f21cc</guid><dc:creator>Arjun-Prasad</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I have a similar requirement. I am trying to achieve lowest possible current for both host mcu(nrf5340) and wifi chip(nrf7002). I am using https client example(sdk v3.0.2) and added modification to call sys_poweroff with button wakeup after https request is sent. I notice that the wifi campanion chip draws ~1uA. But nrf5340 seem to draw ~120uA. I have disabled console as well. When I run shutdown example that implements only sys_poweroff without wifi I can achieve &amp;lt;1uA average current on nrf5340. Can you let me know what might be causing higher current when wifi is enabled?&lt;/p&gt;
&lt;p&gt;Best Regards,&lt;/p&gt;
&lt;p&gt;Arjun&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512786?ContentTypeID=1</link><pubDate>Fri, 29 Nov 2024 14:12:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:02d24ee1-6af4-4540-a279-f190556c7007</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You see 120 milliamps?&lt;/p&gt;
&lt;p&gt;That indicates that something went terribly wrong.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Have you checked that the shutdown-sample works as expected on your end?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I ran the snippet in the sta/ sample&amp;nbsp;and used the shutdown function as shown here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/v2.7.0/samples/wifi/shutdown/src/main.c#L155-L172"&gt;https://github.com/nrfconnect/sdk-nrf/blob/v2.7.0/samples/wifi/shutdown/src/main.c#L155-L172&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And measure &amp;lt; 5 uA when it is shut down.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512691?ContentTypeID=1</link><pubDate>Fri, 29 Nov 2024 08:47:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bd35023d-7f10-4ea0-a00b-428a460a8997</guid><dc:creator>rainbowkenny</dc:creator><description>&lt;p&gt;In my case, current draw&amp;nbsp;increased&amp;nbsp;from ~10mA to ~120mA when I step in this line inside net_if_down():&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;status = net_if_l2(iface)-&amp;gt;enable(iface, false);&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512426?ContentTypeID=1</link><pubDate>Wed, 27 Nov 2024 16:21:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9d0e3b88-65cc-4188-a599-9ecc7be8e8f1</guid><dc:creator>rainbowkenny</dc:creator><description>&lt;p&gt;Ok, I&amp;#39;ve added a workqueue, so&amp;nbsp;&lt;em&gt;net_if_down() &lt;/em&gt;doesn&amp;#39;t stuck any more.&lt;br /&gt;&lt;em&gt;&lt;/em&gt;However, it doesn&amp;#39;t reduce power consumption, in contrast, it increased current draw.&lt;br /&gt;Here&amp;#39;s the code:&lt;br /&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;void system_shutdown()
{
    shutdown_wifi();
	sendMsgToSTM(PacketReply_t_nrf_shutdown_tag);
	k_sleep(K_SECONDS(1));
	sys_poweroff();
}

void watchdog_work_handler(struct k_work *work)
{
    LOG_ERR(&amp;quot;Watchdog triggered: handling in work queue&amp;quot;);
    system_shutdown();
}

void timer_system_shutdown(struct k_timer *timer_id)
{
	k_work_submit_to_queue(&amp;amp;my_workq, &amp;amp;watchdog_work);
}

K_TIMER_DEFINE(watchdog_timer, timer_system_shutdown, NULL);

void setUpWatchdog()
{
	// Initialize the work queue
    k_work_queue_start(&amp;amp;my_workq, my_workq_stack, 
                       K_THREAD_STACK_SIZEOF(my_workq_stack), 
                       CONFIG_SYSTEM_WORKQUEUE_PRIORITY, NULL);

    // Initialize the work item
    k_work_init(&amp;amp;watchdog_work, watchdog_work_handler);
	LOG_ERR(&amp;quot;watchdog triggered&amp;quot;);
}

void kick_watchdog()
{
	k_timer_start(&amp;amp;watchdog_timer, K_MINUTES(CONFIG_WATCHDOG_KICK_INTERVAL_MINUTES), K_MINUTES(CONFIG_WATCHDOG_KICK_INTERVAL_MINUTES));
}&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512328?ContentTypeID=1</link><pubDate>Wed, 27 Nov 2024 11:53:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5bc959cf-d461-443e-b81f-163ea33d489c</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;k_timer runs in interrupt context. You should schedule this to main / thread context, for instance using a workqueue.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512320?ContentTypeID=1</link><pubDate>Wed, 27 Nov 2024 11:45:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b419acca-4130-4704-86d2-c89a5998046b</guid><dc:creator>rainbowkenny</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;br /&gt;I&amp;#39;m calling it from a callback function of a watchdog timer. Please see below:&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;void system_shutdown()
{
	shutdown_wifi();
	k_sleep(K_SECONDS(1));
	sys_poweroff();
}

void timer_system_shutdown(struct k_timer *timer_id)
{
	LOG_ERR(&amp;quot;watchdog triggered&amp;quot;);
	system_shutdown();
}

K_TIMER_DEFINE(watchdog_timer, timer_system_shutdown, NULL);

void kick_watchdog()
{
	  k_timer_start(&amp;amp;watchdog_timer, K_MINUTES(CONFIG_WATCHDOG_KICK_INTERVAL_MINUTES), K_MINUTES(CONFIG_WATCHDOG_KICK_INTERVAL_MINUTES));
}&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512318?ContentTypeID=1</link><pubDate>Wed, 27 Nov 2024 11:39:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:72a1b42c-0e96-49ab-b7ea-3969d49c0593</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Can you share a log showing the issue?&lt;/p&gt;
&lt;p&gt;Where is the shutdown_wifi() function called from? This should not be called from a interrupt.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512222?ContentTypeID=1</link><pubDate>Tue, 26 Nov 2024 21:48:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8a11716-876a-4d83-8ab7-3d0f7878c746</guid><dc:creator>rainbowkenny</dc:creator><description>&lt;p&gt;Thank you, this is more clearer!&lt;br /&gt;So&amp;nbsp;below is my shutdown sequence for the wifi chip. &lt;br /&gt;&lt;br /&gt;It works if I&amp;nbsp;just use&amp;nbsp;&lt;em&gt;net_mgmt(NET_REQUEST_WIFI_CONNECT_STORED, iface, NULL, 0)&amp;nbsp;&lt;/em&gt;to connect to the existing wifi.&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;However, if I&amp;#39;m doing BT-provisioning (copied from the BT-wifi provisioning sample), this routine won&amp;#39;t run successfully, it will get stuck at&amp;nbsp;&lt;em&gt;net_if_down(iface).&amp;nbsp;&lt;/em&gt;I suspect this is because the wifi stack is still running.&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;So my question is how do I stop&amp;nbsp;an on-going provisioning service so that I can turn off the wifi chip completely afterwards?&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;Many thanks!&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;int shutdown_wifi()
{
	int ret;
  	struct net_if *iface = net_if_get_default();

	if (!net_if_is_admin_up(iface)) {
		return 0;
	}

	if (!net_if_is_up(iface)){
		return 0;
	}
	ret = net_if_down(iface);
	if (ret) {
		LOG_ERR(&amp;quot;net_if_down failed: %d&amp;quot;, ret);
		return ret;
	}

	LOG_INF(&amp;quot;Interface down&amp;quot;);

	return 0;
}&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/512046?ContentTypeID=1</link><pubDate>Tue, 26 Nov 2024 08:25:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c4f5b73a-a26a-45ea-9fbd-1a85799b2c50</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The nRF5340 will continue running code afterwards, and it will require specific code in order to enter SystemOn or SystemOff mode.&lt;/p&gt;
&lt;p&gt;The shutdown sample, from the nRF5340 point of view, does not do much, so there it will enter the idle thread with serial logging enabled, giving a floor current of approx. 0.5 mA.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If you disable all bus peripherals, ie. logging and such, it will be in the lower uA range. Entering systemoff will be even lower.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/511952?ContentTypeID=1</link><pubDate>Mon, 25 Nov 2024 15:04:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e50106cd-3c03-4a39-89bd-0c133dfe41d5</guid><dc:creator>rainbowkenny</dc:creator><description>&lt;p&gt;Thanks for your reply. Are you suggesting that I only need to use&amp;nbsp;&lt;strong&gt;net_if_down()&amp;nbsp;&lt;/strong&gt;if I want to turn off both host and wifi chip (regardless of the logging for now)?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF7002 DK system shutdown</title><link>https://devzone.nordicsemi.com/thread/511941?ContentTypeID=1</link><pubDate>Mon, 25 Nov 2024 14:38:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:771a365d-ce44-4b43-ac92-a57afdc4102f</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user=""]&lt;p&gt;Background:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;We&amp;#39;re developing wireless application with the NRF5340-NRF7002 chipset, similar to&amp;nbsp;what&amp;#39;s on the 7002DK board.&lt;/li&gt;
&lt;li&gt;We&amp;#39;d like to put the system to lowest power mode when it&amp;#39;s not being used.&lt;/li&gt;
&lt;li&gt;I found two samples related to this:&amp;nbsp; &lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/samples/wifi/shutdown/README.html"&gt;nrf/samples/wifi/shutdown&lt;/a&gt;&amp;nbsp;and &lt;a href="https://github.com/zephyrproject-rtos/zephyr/tree/main/samples/boards/nordic/system_off"&gt;zephyr/samples/boards/nrf/system_off&amp;nbsp;&lt;/a&gt;&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;My questions are:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Which sample shall I base my project on?&lt;/li&gt;&lt;/ol&gt;[/quote]
&lt;p&gt;To shut down the nRF700x device, please see the sequence given in samples/wifi/shutdown.&lt;/p&gt;
&lt;p&gt;This will completely turn off the power to the nRF700x.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user=""]The &lt;em&gt;wifi/shutdown&lt;/em&gt; sample page states that &amp;quot;&lt;span&gt;&lt;span&gt;This also demonstrates how to achieve the lowest possible power consumption in the &lt;strong&gt;Host SoC (nRF53&lt;/strong&gt;, nRF52 or nRF91 Series) when Wi-Fi is enabled but not being used.&amp;quot; - How is this achieved? I can only see function &lt;strong&gt;net_if_down()&amp;nbsp;&lt;/strong&gt;is used. I assume this will only turn off the nRF7002 wifi chip, but not the host?&lt;/span&gt;&lt;/span&gt;[/quote]
&lt;p&gt;This is not entirely true, as the logger is enabled. This will cause the host controller to draw approx. 0.5 mA in sleep. I will report this internally as a documentation error.&lt;/p&gt;
&lt;p&gt;To get to a lower current consumption, disabling of the serial interface is required (CONFIG_LOG=n and CONFIG_SERIAL=n).&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;This example will show how to set the nRF5-device into &amp;quot;SystemOff&amp;quot;, which should consume &amp;lt;1 uA:&lt;/p&gt;
[quote user=""] &lt;a href="https://github.com/zephyrproject-rtos/zephyr/tree/main/samples/boards/nordic/system_off"&gt;zephyr/samples/boards/nrf/system_off&amp;nbsp;&lt;/a&gt;&amp;nbsp;[/quote]
&lt;p&gt;This is the lowest power mode, and the device can only be awoken from combinatory logic (GPIO/RESET signal for instance).&lt;/p&gt;
[quote user=""]&lt;span&gt;&lt;span&gt;&lt;span&gt;The &lt;em&gt;system_off sample uses&amp;nbsp;&lt;/em&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;strong&gt;sys_poweroff&lt;i&gt;()&amp;nbsp;&lt;/i&gt;&lt;/strong&gt;&lt;i&gt;&lt;/i&gt;function, will this shut down both nRF5340 and nRF7002 chips? What happens when BT and/or Wifi are being used?[/quote]
&lt;p&gt;This will only shut down the host controller.&lt;/p&gt;
&lt;p&gt;The nRF700x must be taken down by&amp;nbsp;implementing the wifi/shutdown/main.c::shutdown_wifi() function.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>