<?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>nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/75928/nrf52840-power-questions-dc-dc-converter-and-powering-down-the-system</link><description>I&amp;#39;ve got a couple of puzzles relating to a 52840 design that evolved from an 52832 design, belonging to a customer. 
 1) following the suggestions at https://devzone.nordicsemi.com/nordic/nordic-blog/b/blog/posts/optimizing-power-on-nrf52-designs #1,</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 18 Jun 2021 08:13:32 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/75928/nrf52840-power-questions-dc-dc-converter-and-powering-down-the-system" /><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/316022?ContentTypeID=1</link><pubDate>Fri, 18 Jun 2021 08:13:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:89105efd-a0c9-4e34-9a59-86f3457fbfd6</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;But you are using the SoftDevice, right? It shouldn&amp;#39;t give in due to any of these calls as far as I know. And the SoftDevice should have higher priority than other peripherals/libraries and is controlling the radio, so there must be a call to stop the radio and go to sleep by the SoftDevice somewhere. Is it possible to upload&amp;nbsp;the full main file here, or a version of the project that works on a Development kit so we could get a better look/overview of the entire project? If you&amp;#39;d like I can set this case to private mode so that it will only be visible to yourself and Nordic engineers, and we&amp;#39;ll treat it confidentially.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/315963?ContentTypeID=1</link><pubDate>Thu, 17 Jun 2021 17:51:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cff94212-c8c9-4c6d-a968-716bbc545682</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;Hi Simon,&lt;/p&gt;
&lt;p&gt;what we&amp;#39;re doing is:&lt;/p&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;&lt;span style="color:#1f542e;font-weight:bold;"&gt;NRF_UART0&lt;/span&gt;-&amp;gt;&lt;span style="color:#660e7a;"&gt;ENABLE &lt;/span&gt;= &lt;span style="color:#0000ff;"&gt;0&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;AudioPDM_Disable();&lt;/pre&gt;
&lt;p&gt;where:&lt;/p&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;&lt;span style="color:#000080;font-weight:bold;"&gt;void  &lt;/span&gt;AudioPDM_Disable( &lt;span style="color:#000080;font-weight:bold;"&gt;void &lt;/span&gt;)&lt;br /&gt;{&lt;br /&gt;&lt;span style="color:#371f80;"&gt;ret_code_t &lt;/span&gt;status;&lt;br /&gt;&lt;br /&gt;    &lt;span style="color:#000080;font-weight:bold;"&gt;if&lt;/span&gt;(m_audio_enabled == &lt;span style="color:#1f542e;font-weight:bold;"&gt;false&lt;/span&gt;)&lt;br /&gt;    {&lt;br /&gt;        &lt;span style="color:#000080;font-weight:bold;"&gt;return&lt;/span&gt;;&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    status = nrf_drv_pdm_stop();&lt;br /&gt;    &lt;span style="color:#000080;font-weight:bold;"&gt;if &lt;/span&gt;(status == &lt;span style="color:#1f542e;font-weight:bold;"&gt;NRF_SUCCESS&lt;/span&gt;)&lt;br /&gt;    {&lt;br /&gt;        m_audio_enabled = &lt;span style="color:#1f542e;font-weight:bold;"&gt;false&lt;/span&gt;;&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;   nrf_gpio_pin_set(&lt;span style="color:#1f542e;font-weight:bold;"&gt;MIC_EN_PINNUMBER&lt;/span&gt;);          &lt;span style="color:#808080;font-style:italic;"&gt;// shut off microphone power&lt;br /&gt;&lt;/span&gt;&lt;span style="color:#808080;font-style:italic;"&gt;&lt;br /&gt;&lt;/span&gt;}&lt;br /&gt;I would not have expected either of these to have a major effect on power, &lt;br /&gt;but presumably there is a checklist somewhere that&amp;#39;s looking at what&amp;#39;s active, &lt;br /&gt;and perhaps our advertising isn&amp;#39;t setting something it&amp;#39;s looking for.&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/315789?ContentTypeID=1</link><pubDate>Thu, 17 Jun 2021 08:57:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ec28e99b-0b2b-4b75-8156-29381e03a43e</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;The device should definitely&amp;nbsp;&lt;strong&gt;not&amp;nbsp;&lt;/strong&gt;go to system OFF if the radio (and SoftDevice) is running, so something doesn&amp;#39;t seem right here. Can you provide a snippet of code showing how exactly you turn off UART and/or PDM? There must be something trigging the device to shut down entirely when you disable (one or both of) these peripherals, as the radio peripheral and SoftDevice should keep the application running.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/315252?ContentTypeID=1</link><pubDate>Mon, 14 Jun 2021 23:36:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b6b240dd-e3fe-4b5b-9ab7-836618cb383f</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;You were correct that app_timer_init() needed to be called before nrf_pwr_mgmt_init().&amp;nbsp; However, we&amp;#39;re wondering how the power management library makes its determination as to when to shut down. We are seeing that if we (due to application requirements) turn off UART and PDM, that triggers a pwr_mgmt shutdown, all the way down to SysOff, despite active BLE advertising.&amp;nbsp; While the power usage is lower :-) that doesn&amp;#39;t do us much good if BLE connections won&amp;#39;t work.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;We are calling nrf_pwr_mgmt_run() in the main while(1) loop, and have NRF_PWR_MGMT_CONFIG_STANDBY_TIMEOUT_ENABLED set to 0.&amp;nbsp; Do we need to do something specific to tell power management to stay alert to listen for connection requests?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/314712?ContentTypeID=1</link><pubDate>Thu, 10 Jun 2021 13:05:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:60345529-ea70-4cd8-8761-834e66801290</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi Pierre&lt;/p&gt;
&lt;p&gt;As for your first post, you should not need both these functions, as long as the SoftDevice has been initialized, &lt;strong&gt;sd_power_system_off();&lt;/strong&gt; should be sufficient.&lt;/p&gt;
&lt;p&gt;As the SoftDevice and power management libraries are used together in the power management example, they should be able to work together.&amp;nbsp;nrf_pwr_mgmt_init() may return NRF_ERROR_INVALID_STATE if you haven&amp;#39;t initialized the app_timer module first (app_timer_init();), so please make sure that this is done.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/314319?ContentTypeID=1</link><pubDate>Wed, 09 Jun 2021 04:01:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:13581981-e14c-432b-a989-469cfe6cc939</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;So it turns out things are not that simple.&amp;nbsp; Calling:&lt;/p&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;    &lt;span style="color:#371f80;"&gt;ret_code_t &lt;/span&gt;err_code = &lt;span style="color:#0000ff;"&gt;0&lt;/span&gt;;&lt;br /&gt;&lt;span style="color:#0000ff;"&gt;   &lt;/span&gt;&lt;span style="color:#38492e;font-style:italic;"&gt;err_code = nrf_pwr_mgmt_init();&lt;br /&gt;&lt;/span&gt;   &lt;span style="color:#1f542e;font-weight:bold;"&gt;APP_ERROR_CHECK&lt;/span&gt;(err_code);&lt;br /&gt;   &lt;/pre&gt;
&lt;p&gt;reliably fails and quickly reboots from the APP_ERROR_CHECK:&lt;/p&gt;
&lt;p&gt;00&amp;gt; &amp;lt;error&amp;gt; app: ERROR 8 [NRF_ERROR_INVALID_STATE] at :0&lt;br /&gt;00&amp;gt; PC at: 0x00000000&lt;/p&gt;
&lt;p&gt;The docs at &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v16.0.0/group__nrf__pwr__mgmt.html"&gt;https://infocenter.nordicsemi.com/topic/sdk_nrf5_v16.0.0/group__nrf__pwr__mgmt.html&lt;/a&gt; suggest: &amp;quot;&lt;/p&gt;
&lt;dl class="section warning"&gt;
&lt;dt&gt;Warning&lt;/dt&gt;
&lt;dd&gt;Depending on configuration, this function sets SEVONPEND in System Control Block (SCB). This operation is unsafe with the SoftDevice from interrupt priority higher than SVC.&amp;quot;&lt;/dd&gt;
&lt;/dl&gt;
&lt;p&gt;without giving much of a hint how to deal with the issue.&amp;nbsp; So the question remains: can power management library be used with S140 device, and if so, what do we need to do to allow that?&amp;nbsp; For a bit of background, we did migrate this project from what was originally SDK12.2, so the various interrupt priority levels are set to 7, while in the example&amp;#39;s config.sdk, many (most?) appear to have been raised to 6.&amp;nbsp; The docs unfortunately don&amp;#39;t give enough info to know which priority level might be the problem.&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: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/314318?ContentTypeID=1</link><pubDate>Wed, 09 Jun 2021 03:54:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:760e2852-b4c8-4822-9071-13ff62782be0</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;We are doing basic advertising and not much else at that stage.&amp;nbsp; However, due to your suggestion, I started looking at the power profiling example, and it is clear that none of the nrf_pwr_mgmt&amp;nbsp; functions are currently in the project, so I&amp;#39;m going to start experimenting with them.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Can I ask you to please explain which of the following would be more correct (or do we not need both?):&lt;/p&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;nrf_pwr_mgmt_shutdown(&lt;span style="color:#660e7a;font-style:italic;font-weight:bold;"&gt;NRF_PWR_MGMT_SHUTDOWN_GOTO_SYSOFF&lt;/span&gt;);&lt;br /&gt;sd_power_system_off();&lt;/pre&gt;
&lt;p&gt;or:&lt;/p&gt;
&lt;pre style="background-color:#ffffff;color:#000000;font-family:&amp;#39;JetBrains Mono&amp;#39;,monospace;font-size:9.8pt;"&gt;sd_power_system_off();&lt;br /&gt;nrf_pwr_mgmt_shutdown(&lt;span style="color:#660e7a;font-style:italic;font-weight:bold;"&gt;NRF_PWR_MGMT_SHUTDOWN_GOTO_SYSOFF&lt;/span&gt;);&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;
&lt;p&gt;Thanks!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/314187?ContentTypeID=1</link><pubDate>Tue, 08 Jun 2021 11:40:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e32e4256-4b23-4de0-bfc1-e0a5b73f8a0c</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;Thank you for your feedback. There are indeed some SoftDevice specific functions like &lt;strong&gt;sd_power_dcdc_mode_set&lt;/strong&gt;() and&amp;nbsp;&lt;strong&gt;sd_power_system_off()&amp;nbsp;&lt;/strong&gt;for instance. The DCDC behavior you&amp;#39;re explaining seems very strange to me, as it definitely shouldn&amp;#39;t be higher with the DCDC enabled. What kind of radio activity is your application doing, BLE advertising?&lt;/p&gt;
&lt;p&gt;2. Can you provide a snippet of code showing how exactly you disable your peripherals and put your device to sleep? I would suggest using the &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_pwr_mgmt.html"&gt;Power Profiling application example in our SDK&lt;/a&gt; for reference on how to put your application into system OFF mode.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/314008?ContentTypeID=1</link><pubDate>Mon, 07 Jun 2021 16:34:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:86b2fe55-7fbb-4a26-a00c-a5464838ef51</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;Hi Simon,&lt;/p&gt;
&lt;p&gt;I tried the sd_power_dcdc_mode_set() instead &amp;ndash; thank you for pointing to that, since the documentation is sorely lacking an indication that the sdk_config settings should NOT be used if an SD is present.&amp;nbsp; Enabling that routine does seem to raise the power drain very slightly (it has some new peaks at 1.6mA for about 15 seconds but settles around 1.2mA which is similar to before) though my understanding was that enabling the DC/DC converter should have shown some noticeable reduction in power.&amp;nbsp; I checked, and L2 and L3 are installed, with the correct values.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;ol start="2"&gt;
&lt;li&gt;the test in &amp;ldquo;off mode&amp;rdquo; was done with the production (non-debug) build with the J-Link board disconnected, which is why I remain puzzled as to why consumption is still around 1mA&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;
&lt;p&gt;Pierre&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/313406?ContentTypeID=1</link><pubDate>Thu, 03 Jun 2021 12:18:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fee393cc-016f-4042-a880-af82b9b804c0</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;1. What exactly is it that causes the current consumption to increase from 1.2mA to 1.9mA? Please note that the current consumption is a little higher during BLE advertising in the nRF52840 than the nRF52832 in general. This is reflected in the product specification as well as the &lt;a href="https://devzone.nordicsemi.com/nordic/power/w/opp/2/online-power-profiler-for-ble"&gt;Online Power Profiler for BLE.&lt;/a&gt;&amp;nbsp;Or do you mean that enabling DCDC in your application is what is increasing the current consumption? Can you confirm that the two inductors L2 and L3 are added to your design (which are required for the DCDC regulator to operate as intended?&lt;/p&gt;
&lt;p&gt;When you&amp;#39;re using a SoftDevice, you should use the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.s132.api.v7.2.0%2Fgroup___n_r_f___s_o_c___f_u_n_c_t_i_o_n_s.html&amp;amp;anchor=ga84bd6a0e8f55a7aa85a5ec608edd61fe"&gt;sd_power_dcdc_mode_set() &lt;/a&gt;function to enable the DCDC regulator.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;2. When you&amp;#39;re still seeing ~1mA of power after calling sd_power_system_off() points to the device being in DEBUG mode. You can disable DEBUG mode to make sure that DEBUG is not set in your project&amp;#39;s preprocessor definitions, and make sure that you power cycle your device after programming it. If it&amp;#39;s a custom board, also make sure that the debugger is disconnected from your device.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 power questions: DC/DC converter and powering down the system</title><link>https://devzone.nordicsemi.com/thread/313212?ContentTypeID=1</link><pubDate>Wed, 02 Jun 2021 19:25:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dbb26838-3bbf-4e7d-aebb-07cecd70afd1</guid><dc:creator>Pierre Landau</dc:creator><description>&lt;p&gt;Need to amend the above.&amp;nbsp; By &amp;quot;quiescent&amp;quot; i actually mean it&amp;#39;s not doing much but it is advertising, so there is some BLE activity, though the questions about power configuration remain the same&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>