<?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>Unable to connect debugger after nrfjprog --recover due to default REGOUT0</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73118/unable-to-connect-debugger-after-nrfjprog---recover-due-to-default-regout0</link><description>I have a custom board with an nRF52840 that uses high-voltage mode (5V on VDDH) and the chips internal voltage regulators. This requires setting REGOUT0 to 3.3V. My firmware sets this correctly (along with both DC/DC enables) and the board works great</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 23 Mar 2021 13:58:44 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73118/unable-to-connect-debugger-after-nrfjprog---recover-due-to-default-regout0" /><item><title>RE: Unable to connect debugger after nrfjprog --recover due to default REGOUT0</title><link>https://devzone.nordicsemi.com/thread/301458?ContentTypeID=1</link><pubDate>Tue, 23 Mar 2021 13:58:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2889711f-0d91-4a73-bf91-b8e1adbe9d43</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;As Dimitry said, the default REGOUT0 setting should not get applied if you can avoid resetting the device before the --memwr command. &lt;/p&gt;
&lt;p&gt;Could you try using --erase instead of --recover, or is --recover needed to disable APPROTECT in your case?&lt;/p&gt;
&lt;p&gt;e.g.&lt;/p&gt;
&lt;p style="padding-left:30px;"&gt;nrfjprog --erase&lt;/p&gt;
&lt;p style="padding-left:30px;"&gt;nrfjprog --memwr UICR.REGOUT0 --val &amp;lt;3V3 setting&amp;gt;&lt;/p&gt;
&lt;p style="padding-left:30px;"&gt;nrfjprog --reset&lt;/p&gt;
&lt;p&gt;Also, I&amp;#39;m not sure why programming becomes more stable with the external supply. Standalone debuggers usually come with built-in level shifters so the IO voltage should not have been a problem. Is the VREF pin connected to Vdd on your target board?&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1616508251137v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Unable to connect debugger after nrfjprog --recover due to default REGOUT0</title><link>https://devzone.nordicsemi.com/thread/301341?ContentTypeID=1</link><pubDate>Tue, 23 Mar 2021 08:44:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3d0d758b-b7e0-4ae2-beff-d9112265965e</guid><dc:creator>Dmitry</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;you can try to erase chip and then write UICR without device reset directly with jlink script, as explained &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/33911/what-are-the-raw-jlink-exe-commands-sent-by-nrfjprog-exe"&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>