<?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>How to change a UICR register value when APPROTECT is enabled on the nRF52?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/66907/how-to-change-a-uicr-register-value-when-approtect-is-enabled-on-the-nrf52</link><description>Background: 
 First, let me state that this is a huge amount of contradictory information on this forum due to the UICR registers behaving differently for each generation of nRF. Please only comment if you know how the nRF52840 works. 
 Also, in general</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 09 Oct 2020 16:20:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/66907/how-to-change-a-uicr-register-value-when-approtect-is-enabled-on-the-nrf52" /><item><title>RE: How to change a UICR register value when APPROTECT is enabled on the nRF52?</title><link>https://devzone.nordicsemi.com/thread/274103?ContentTypeID=1</link><pubDate>Fri, 09 Oct 2020 16:20:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b3c19767-3a9e-4ba6-9f12-78425ff89505</guid><dc:creator>DaveElam</dc:creator><description>&lt;p&gt;Hi Jared,&lt;/p&gt;
&lt;p&gt;I&amp;#39;m attempting to program the UICR &amp;quot;registers&amp;quot; from inside the firmware, using nrf_nvmc_page_erase()&amp;nbsp;followed by&amp;nbsp;nrf_nvmc_write_word().&amp;nbsp; I&amp;#39;m able to do this successfully when APPROTECT is not enabled.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The APPROTECT feature can be enabled by setting UICR&amp;nbsp;register 0x10001208 to 0x00.&amp;nbsp; Once this register is cleared, it cannot be set again unless the whole device is erased, as stated in the OPS.&amp;nbsp; But, I don&amp;#39;t see anything in the OPS about other UICR registers being affected when&amp;nbsp;APPROTECT is enabled.&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Dave&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to change a UICR register value when APPROTECT is enabled on the nRF52?</title><link>https://devzone.nordicsemi.com/thread/273944?ContentTypeID=1</link><pubDate>Fri, 09 Oct 2020 08:10:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a2a1bd9-8daf-4162-ba0f-90fb883b5c6f</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi Dave,&lt;/p&gt;
[quote userid="87637" url="~/f/nordic-q-a/66907/how-to-change-a-uicr-register-value-when-approtect-is-enabled-on-the-nrf52"]&lt;p&gt;Also, in general, in order of ease of changing values, the industry standard language is to use: RAM &amp;gt; Registers &amp;gt; Flash &amp;gt; OTP.&amp;nbsp; I sincerely hope that UICR&amp;nbsp;REGISTERS are not&amp;nbsp;one time programmable (OTP) as it seems. If so, Nordic need to change the name of these to OTP!!!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;The user information configuration registers are non-volatile registers that can be re-written to but has to be erased after &lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/nvmc.html#unique_2120716477"&gt;n_write&lt;/a&gt;&amp;nbsp;times before you can write to it again.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
[quote userid="87637" url="~/f/nordic-q-a/66907/how-to-change-a-uicr-register-value-when-approtect-is-enabled-on-the-nrf52"]I&amp;#39;m able to change the UICR registers using the NVMC when APPROTECT is disabled, but not when APPROTECT is enable.&amp;nbsp; Is this the intended behavior?&amp;nbsp; Is there any way to work around this?[/quote]
&lt;p&gt;Are you writing to the UICR from your application or trying to write to it externally with a debugger? In short, the &lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/dif.html?cp=4_0_0_3_7_1#concept_udr_mns_1s"&gt;APPROTECT &lt;/a&gt;feature disables the debugger interface which disables the option for an external user to read-out, erase or write to the memory. If you&amp;#39;re writing from the application then the issue is probably that you&amp;#39;re trying to write to it more than n_write times.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Lastly, if you see any information that you mean is contradicting on this forum than I strongly suggest that you read the product specification to get the correct information.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/nvmc.html?cp=4_0_0_3_2"&gt;Relevant section in the Product specification.&amp;nbsp;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;regards&lt;/p&gt;
&lt;p&gt;Jared&amp;nbsp; &amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>