<?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>nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/76785/nrf-5340-dk-high-idle-current</link><description>As the title states, my program (and a simple idle/hello world program for that matter) pull approximately 600-800 uA at idle. Same exact program, driver, and config on my nRF 52833 DK pulls about 8 uA at idle. I cannot figure out why this is. I suspect</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 02 Sep 2021 14:49:35 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/76785/nrf-5340-dk-high-idle-current" /><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/327840?ContentTypeID=1</link><pubDate>Thu, 02 Sep 2021 14:49:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:64b88761-fed2-49d2-b395-4c16fa3107a9</guid><dc:creator>jansens</dc:creator><description>&lt;p&gt;I just got around to testing this on NCS 1.6.0 and it appears to be fixed using&amp;nbsp;&lt;span&gt;CONFIG_GPIO_NRF_INT_EDGE_USING_SENSE=y like suggested.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thank you!&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/322961?ContentTypeID=1</link><pubDate>Mon, 02 Aug 2021 19:09:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:19be350d-dc88-41a0-bb81-31b288d75fce</guid><dc:creator>Stian R&amp;#248;ed Hafskjold</dc:creator><description>&lt;p&gt;Hi, sorry for the late response. You say that you have configured a wakeup pin. Can you make sure that the pin configuration is&amp;nbsp;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span&gt;GPIO_INT_LEVEL_ACTIVE&lt;/span&gt;&lt;/code&gt; and not&amp;nbsp;&lt;span&gt;&lt;/span&gt;&lt;code&gt;&lt;span&gt;GPIO_INT_EDGE_TO_ACTIVE&lt;/span&gt;&lt;/code&gt; ? The latter one will use the GPIOTE IN event. I did some measurements now and it seems like the GPIOTE IN event consumes about 80 uA of current. So this might be what you are seeing.&lt;/p&gt;
&lt;p&gt;EDIT: I see now that this LEVEL vs EDGE behavior has changed in the NCS v1.6.0. So now it should be enough to add CONFIG_GPIO_NRF_INT_EDGE_USING_SENSE=y to the prj.conf file, and the current should go down. By enabling this option, the interrupt will be triggered by the GPIO SENSE event, and not using the GPIOTE IN event.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/318691?ContentTypeID=1</link><pubDate>Mon, 05 Jul 2021 18:21:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ede4132-a0cc-434c-9a38-5d14396459e9</guid><dc:creator>jansens</dc:creator><description>&lt;p&gt;Got it, I understand how the 5340 is using multiple images now after your post and some more digging on my end. So yeah I went ahead and made those config changes and made sure it was booting using the samples/boilerplate you mentioned with the config changes you mentioned.&lt;br /&gt;&lt;br /&gt;Despite those changes I made to the config, I still have an idle current of ~70uA on the 5340 compared to ~7uA on my 52833&lt;br /&gt;&lt;br /&gt;I also added functionality to my application which causes it to enter deep sleep/system off with sense on a pin to wake/reset. In system off mode (pm_power_state_force(POWER_STATE_DEEP_SLEEP_1)) it draws about 14uA which is higher than I expected as well. I haven&amp;#39;t tested this code on my 52833 yet but I feel like this is might be related to my high idle current as well.&lt;/p&gt;
&lt;p&gt;Where do I look next/how can I debug/what resources do I have at my disposal to figure out what is causing this?&lt;/p&gt;
&lt;p&gt;Is there anyway I can see what the PMU is doing via debugging?&lt;br /&gt;&lt;br /&gt;Edit:&lt;br /&gt;Also, I did try the hex for the blinky application you posted and I too get about ~5uA idle.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/318240?ContentTypeID=1</link><pubDate>Thu, 01 Jul 2021 13:10:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e25c1b6e-80d9-4ee8-92fc-026a119b1b1b</guid><dc:creator>Stian R&amp;#248;ed Hafskjold</dc:creator><description>&lt;p&gt;Hi Sam,&lt;/p&gt;
&lt;p&gt;You will have to disable UART in the SPM project as well. Add CONFIG_SERIAL=n to the prj.conf file in the nrf/samples/spm/ folder.&lt;/p&gt;
&lt;p&gt;If you are using both the application core and the network core you will have to disable UART in both. Usually for BLE applications, the zephyr/samples/bluetooth/hci_rpmsg application is loaded onto the network core, so you will have to add this CONFIG_SERIAL=n here as well (and remove CONFIG_LOG=y).&lt;/p&gt;
&lt;p&gt;Instead of using the CONFIG_SERIAL=n config you can enable and disable the UARTs in the application by using the code which Amanda linked to, but then the SERIAL has to be enabled or else the power management calls will fail.&lt;/p&gt;
&lt;p&gt;Here is a hex file from the zephyr/samples/basic/blinky application. I just added CONFIG_SERIAL=n to the prj.conf in both the application and the SPM folder. You can try it out and see if the current goes down to the expected level:&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/2318.merged.hex"&gt;devzone.nordicsemi.com/.../2318.merged.hex&lt;/a&gt;&amp;nbsp;I just checked here, and I get 4 uA in idle on a nRF5340 DK.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/318001?ContentTypeID=1</link><pubDate>Wed, 30 Jun 2021 13:31:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2f730653-5ab9-45d4-9ab0-4a333278a082</guid><dc:creator>jansens</dc:creator><description>&lt;p&gt;Yes, in the initial prf.conf I posted I have&lt;br /&gt;CONFIG_DEVICE_POWER_MANAGEMENT=y&lt;br /&gt;CONFIG_PM=y&lt;/p&gt;
&lt;p&gt;set.&lt;br /&gt;&lt;br /&gt;Also if I set&amp;nbsp;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_LOG=n
CONFIG_SERIAL=n
CONFIG_STDOUT_CONSOLE=n&lt;/pre&gt; and also try to run&amp;nbsp;&lt;pre class="ui-code" data-mode="c_cpp"&gt;const struct device *console, *uart1;

void main(void)
{
        // Turn off logging (which is using UART0):
        console = device_get_binding(DT_LABEL(DT_CHOSEN(zephyr_console)));
        if (console == NULL) {
		printf(&amp;quot;Could not get %s device\n&amp;quot;, DT_LABEL(DT_CHOSEN(zephyr_console)));
		return;
	}
        device_set_power_state(console, DEVICE_PM_OFF_STATE, NULL, NULL);
        
        // Turn off UART1:
        uart1 = device_get_binding(DT_LABEL(DT_NODELABEL(uart1)));
        if (uart1 == NULL) {
		printf(&amp;quot;Could not get %s device\n&amp;quot;, DT_LABEL(DT_NODELABEL(uart1)));
		return;
	}
        device_set_power_state(uart1, DEVICE_PM_OFF_STATE, NULL, NULL);
        
}&lt;/pre&gt;&lt;br /&gt;then I get a fatal runtime error which causes a reset loop on the device.&lt;br /&gt;&lt;br /&gt;Also you say to disable on BOTH CORES, how do I specify this in the config? Does the prj.conf only apply to the app core? Or both?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/317912?ContentTypeID=1</link><pubDate>Wed, 30 Jun 2021 09:22:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c146677-50b2-4e47-a84d-7e056aa3ee68</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Sam,&lt;/p&gt;
&lt;p&gt;Do you enable&amp;nbsp;&lt;code&gt;CONFIG_DEVICE_POWER_MANAGEMENT=y&lt;/code&gt; in&lt;span&gt;&amp;nbsp;prj.conf as the thread suggested?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Disabling logging and serial in both cores should get the best result.&amp;nbsp;&lt;/p&gt;
&lt;div&gt;&lt;code&gt;CONFIG_LOG=n&lt;/code&gt;&lt;/div&gt;
&lt;div&gt;&lt;code&gt;CONFIG_SERIAL=n&lt;/code&gt;&lt;/div&gt;
&lt;div&gt;&lt;code&gt;CONFIG_STDOUT_CONSOLE=n&lt;/code&gt;&lt;/div&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/317512?ContentTypeID=1</link><pubDate>Mon, 28 Jun 2021 14:10:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:39cb09c9-5b14-4a46-ad01-be5490686986</guid><dc:creator>jansens</dc:creator><description>&lt;p&gt;Hi Amanda,&lt;br /&gt;&lt;br /&gt;I followed that solution and while it helped quite a bit it did not entirely fix the issue, see below:&lt;br /&gt;So to get this solution to work I had to enable the following the prj.conf:&amp;nbsp;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_LOG=y
CONFIG_SERIAL=y
CONFIG_STDOUT_CONSOLE=y&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;And then added the following code per your suggestion to my main program thread:&amp;nbsp;&lt;pre class="ui-code" data-mode="c_cpp"&gt;const struct device *console, *uart1;

void main(void)
{
        // Turn off logging (which is using UART0):
        console = device_get_binding(DT_LABEL(DT_CHOSEN(zephyr_console)));
        if (console == NULL) {
		printf(&amp;quot;Could not get %s device\n&amp;quot;, DT_LABEL(DT_CHOSEN(zephyr_console)));
		return;
	}
        device_set_power_state(console, DEVICE_PM_OFF_STATE, NULL, NULL);
        
        // Turn off UART1:
        uart1 = device_get_binding(DT_LABEL(DT_NODELABEL(uart1)));
        if (uart1 == NULL) {
		printf(&amp;quot;Could not get %s device\n&amp;quot;, DT_LABEL(DT_NODELABEL(uart1)));
		return;
	}
        device_set_power_state(uart1, DEVICE_PM_OFF_STATE, NULL, NULL);
        
}&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;After doing this I get an idle current of about 67 uA which is still a lot higher than the 8uA what I was seeing on the nRF52833 and expected on the nRF5340:&lt;br /&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1624889344433v1.png" alt=" " /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Where else should I look to improve this? I have spent a ton of time digging through configs, documentation, etc. and am pretty stumped. Is there a good documentation pages I could dig into that maybe I missed?&lt;br /&gt;&lt;br /&gt;I also did some more testing with the simple hello world program and was able to get it down to 5uA idle current only IF I built the program using &amp;quot;&lt;span&gt;nrf5340dk_nrf5340_cpuapp&amp;quot; instead of &amp;quot;nrf5340dk_nrf5340_cpuappns&amp;quot;.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/317486?ContentTypeID=1</link><pubDate>Mon, 28 Jun 2021 12:38:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b369e694-33ac-414b-b57e-eca23b400223</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi Sam,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Check out&amp;nbsp;my colleague&amp;#39;s answer in this &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/71793/why-is-my-psm-floor-current-600-a-asset-tracker-thingy-91/298819#298819"&gt;post&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Amanda&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF 5340 DK High Idle Current</title><link>https://devzone.nordicsemi.com/thread/317327?ContentTypeID=1</link><pubDate>Fri, 25 Jun 2021 20:13:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:365525e9-b8af-4cd1-a361-df8ceae48ce8</guid><dc:creator>jansens</dc:creator><description>&lt;p&gt;Also, this is how I have my Power Profiler 2 wired/setup:&lt;br /&gt;&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/pastedimage1624641695676v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>