<?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>Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/124875/retained-ram-holds-value-after-dev-board-unplugged</link><description>I am puzzled by what I have observed using retained ram on NRF54L15. I have this overlay (see below). Essentially created 16 KB SRAM at address 0x2002C000. I have a struct, sched_retain_t which i initialise at this address: 
 
 
 sched_retain_t * p_sched_retain</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 15 Oct 2025 21:49:13 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/124875/retained-ram-holds-value-after-dev-board-unplugged" /><item><title>RE: Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/thread/551641?ContentTypeID=1</link><pubDate>Wed, 15 Oct 2025 21:49:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bbf868d3-e6cb-4aee-9eac-566f54ccef24</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t have access to a nRF54L15 rev 1.0.0 at the moment, but I will try to find one in the coming days.&lt;/p&gt;
&lt;p&gt;Do you mind also sharing your project? I tried to setup something similar with my rev 0.9.2 DK, starting from just hello_world, but can&amp;#39;t get a similar result.&lt;/p&gt;
&lt;p&gt;Here is my main.c for reference:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;#include &amp;lt;stdio.h&amp;gt;
#include &amp;lt;zephyr/drivers/gpio.h&amp;gt;
#include &amp;lt;zephyr/drivers/hwinfo.h&amp;gt;
#include &amp;lt;zephyr/sys/poweroff.h&amp;gt;

uint32_t* p_test_var = (uint32_t*) 0x2002C000;
static const struct gpio_dt_spec sw0 = GPIO_DT_SPEC_GET(DT_ALIAS(sw0), gpios);

void print_reset_cause(uint32_t reset_cause)
{
	if (reset_cause &amp;amp; RESET_DEBUG) {
		printf(&amp;quot;Reset by debugger.\n&amp;quot;);
	} else if (reset_cause &amp;amp; RESET_CLOCK) {
		printf(&amp;quot;Wakeup from System OFF by GRTC.\n&amp;quot;);
	} else if (reset_cause &amp;amp; RESET_LOW_POWER_WAKE) {
		printf(&amp;quot;Wakeup from System OFF by GPIO.\n&amp;quot;);
	} else  {
		printf(&amp;quot;Other wake up cause 0x%08X.\n&amp;quot;, reset_cause);
	}
}


int main(void)
{
	int rc;
	uint32_t reset_cause;
	printf(&amp;quot;Hello World! %s %u\n&amp;quot;, CONFIG_BOARD_TARGET, *p_test_var);

	*p_test_var = *p_test_var + 1;
	if (*p_test_var &amp;gt; 1000) {
		*p_test_var = 0;
	}
	
	hwinfo_get_reset_cause(&amp;amp;reset_cause);
	print_reset_cause(reset_cause);

		rc = gpio_pin_configure_dt(&amp;amp;sw0, GPIO_INPUT);
	if (rc &amp;lt; 0) {
		printf(&amp;quot;Could not configure sw0 GPIO (%d)\n&amp;quot;, rc);
		return 0;
	}

	rc = gpio_pin_interrupt_configure_dt(&amp;amp;sw0, GPIO_INT_LEVEL_ACTIVE);
	if (rc &amp;lt; 0) {
		printf(&amp;quot;Could not configure sw0 GPIO interrupt (%d)\n&amp;quot;, rc);
		return 0;
	}

	hwinfo_clear_reset_cause();
	sys_poweroff();

	return 0;
}
&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/thread/551225?ContentTypeID=1</link><pubDate>Mon, 13 Oct 2025 08:02:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:24e2a759-afe0-46e1-bf42-152cf88f4cc9</guid><dc:creator>Nikollao</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thanks for getting back to me. I have come across the sample you shared before, I am not using the zephyr helpers to store load from retained ram, instead I defined in device tree my retained ram region and&amp;nbsp;initialised a struct&amp;nbsp;at that address. It seems&amp;nbsp;to be working fine. White label info: PCA10156 1.0.0 2025.30. If I simply disconnect the usb cable, retained ram is not lost, if I remove the P6 jumper, retained ram is lost.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/thread/551111?ContentTypeID=1</link><pubDate>Fri, 10 Oct 2025 11:36:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8e9074e4-dcf2-4668-b1c1-9c6dd9011050</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;Hi Nikollao,&lt;/p&gt;
&lt;p&gt;Right, that makes some more sense, as maybe some capacitors were able to hold enough charge to keep the device&amp;nbsp;powered for a bit longer, especially when it is in System OFF mode, which consumes so little power.&lt;/p&gt;
&lt;p&gt;The problem is that I can&amp;#39;t reproduce your observation with my kit. I tested with &lt;a href="https://github.com/nrfconnect/sdk-zephyr/tree/ncs-v3.1.1/samples/boards/nordic/system_off"&gt;the System OFF sample&lt;/a&gt;, which is very similar to your setup.&lt;/p&gt;
&lt;p&gt;Could you please send me information about your kit? The data in the little white label on the front, except for the serial number.&lt;/p&gt;
&lt;p&gt;Please also tell me how long you wait between unplugging and plugging back in the cable. For reference,&amp;nbsp;I went as low as just 1 second but still can&amp;#39;t reproduce the issue.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/thread/551100?ContentTypeID=1</link><pubDate>Fri, 10 Oct 2025 10:50:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8c28a30a-e306-4695-ac44-c598815aea88</guid><dc:creator>Nikollao</dc:creator><description>&lt;p&gt;OK so apparently to cut power to this dk unplugging the USB cable is not enough as the PMIC somehow still provides some power to the nrf54l15 which leads to ram being retained. To get a power on reset, I disconnected the jumper on P6, and when I reconnected the jumper, the reset reason was 0 (power-on reset) and ram was not retained. I am not sure what this PMIC on this chip does and how it still supplies power when the usb cable is disconnected. If you can shed some light on what this PMIC is doing that would be appreciated. Thanks.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Retained RAM holds value after dev board unplugged</title><link>https://devzone.nordicsemi.com/thread/550990?ContentTypeID=1</link><pubDate>Thu, 09 Oct 2025 10:00:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:aac499f5-95b9-4b7e-aabd-6c1d21ffa462</guid><dc:creator>Nikollao</dc:creator><description>&lt;p&gt;To expand on this question, my main problem is that I use grtc to wake me up from&amp;nbsp;sys_poweroff (deep sleep). When I wake up from grtc I read resetreas GRTC. The problem is if I unplug and replug the usb cable, I also read wake up from GRTC. So I need to know if there was a power cut during system off. I thought I use a retained variable, but that survives a power cut. Suggestions?&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>