<?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 RAM Retention in System ON Mode</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/39396/nrf52840-ram-retention-in-system-on-mode</link><description>Hello, 
 I am performing current measurements on custom hardware with the nRF52840 and comparing my results with the values in the nRF52840 product specification. I noticed that the product specification for the nRF52840 Sleep Current mentions current</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 12 Oct 2018 09:03:28 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/39396/nrf52840-ram-retention-in-system-on-mode" /><item><title>RE: nRF52840 RAM Retention in System ON Mode</title><link>https://devzone.nordicsemi.com/thread/152628?ContentTypeID=1</link><pubDate>Fri, 12 Oct 2018 09:03:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:05ae6e1a-6201-44d6-844d-93c3288a6df6</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hello Mark,&lt;/p&gt;
&lt;p&gt;Unused RAM&amp;nbsp;sections can be power down in system ON mode (&lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52840.ps/power.html?cp=2_0_0_4_2_4#ram_sections"&gt;RAM power control&lt;/a&gt;). So no RAM retention in System ON means that all blocks are powered off&amp;nbsp;with retention disabled. Here is an example of you can power down all RAM blocks (replace with softdevice API if softdevice is enabled):&lt;/p&gt;
&lt;p&gt;NRF_POWER-&amp;gt;RAM[0].POWERCLR = 0x3; //See &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52840.ps/memory.html#memory"&gt;memory&lt;/a&gt; section in PS for number of RAM sections in each block.&lt;br /&gt; NRF_POWER-&amp;gt;RAM[1].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[2].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[3].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[4].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[5].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[6].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[7].POWERCLR = 0x3;&lt;br /&gt; NRF_POWER-&amp;gt;RAM[8].POWERCLR = 0x3F;&lt;br /&gt; &lt;br /&gt; for(;;)&lt;br /&gt; {&lt;br /&gt; __WFE();&lt;br /&gt; }&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Vidar&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>