<?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>Auto run on power up</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/86246/auto-run-on-power-up</link><description>I&amp;#39;m having some (minor) trouble with a board based on an NRF52840 that I want to start running as soon as power is applied... 
 This is built using a RAK5010 board, but using custom firmware, the firmware uses an S340 softdevice. 
 Reading these forums</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 30 Mar 2022 19:57:39 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/86246/auto-run-on-power-up" /><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360897?ContentTypeID=1</link><pubDate>Wed, 30 Mar 2022 19:57:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:79c40ef3-d5ed-4fbd-910f-23d6823fe567</guid><dc:creator>Ivor Hewitt</dc:creator><description>&lt;p&gt;Perfect! thanks for the tip/documentation link. I used that to follow and check the power lines and check the RAK schematic, the VDD1 line wasn&amp;#39;t&amp;nbsp;receiving 1.8v until the BG96 powered up, but oddly I saw they had a&amp;nbsp;non-installed jumper to&amp;nbsp;supply this on their schematic.&amp;nbsp;If I add a jumper here (it&amp;#39;s a&amp;nbsp;0ohm) then the behaviour is as expected and the&amp;nbsp;nRF powers up on battery connection.&lt;br /&gt;&lt;img height="204" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1648670202689v1.png" width="467" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360705?ContentTypeID=1</link><pubDate>Wed, 30 Mar 2022 09:30:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:037bcaeb-094e-44d8-a455-5c01fabf9cea</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I am not aware of anything, so monitoring power lines I think is a good idea. There is some requirements to the rise up time on VDD that you can check at the same time:&lt;br /&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/recommended_op_conditions.html"&gt;https://infocenter.nordicsemi.com/topic/ps_nrf52840/recommended_op_conditions.html&lt;/a&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360592?ContentTypeID=1</link><pubDate>Tue, 29 Mar 2022 14:50:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8cf6ddf3-191a-4613-ab58-87971d431bb7</guid><dc:creator>Ivor Hewitt</dc:creator><description>&lt;p&gt;Thanks&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/mrono"&gt;mrono&lt;/a&gt;and Kenneth&amp;nbsp;going to&amp;nbsp;give up for a bit! I just can&amp;#39;t see it.&lt;/p&gt;
&lt;p&gt;I used mass_erase to start from a clean slate so I don&amp;#39;t think that&amp;#39;s related to old code, dumping the flash all appears&amp;nbsp;to be gone when I start off.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m pretty sure the reset pin is being set correctly, I tried with, firstly, reset disabled (i.e. 0xFFs in 0x10001200 and 0x1001204) then I tried&amp;nbsp;a few other values (e.g. 31, 18 etc).&lt;/p&gt;
&lt;p&gt;This board has a reset button attached to pin 18, so if I don&amp;#39;t set it or I set it to some other value then that button&amp;nbsp;no longer&amp;nbsp;resets the nRF, if I set it to 18 then the reset behaviour is as expected. So. I think it&amp;#39;s being set and unset correctly and is being handled correctly.&lt;/p&gt;
&lt;p&gt;If I have it set to 18, then when the board is &amp;quot;off&amp;quot; (i.e. board has battery power but before the BG96 is started up) then pressing that reset button does nothing so I think this is a deeper issue. Once the BG96 is powered up, the nRF app boots up and the reset button behaves as expected.&lt;/p&gt;
&lt;p&gt;Hence my first questions if there was anything else that controls this or could be causing this since I couldn&amp;#39;t see anything in the documentation and it sounds from your answers like that isn&amp;#39;t the case.&lt;/p&gt;
&lt;p&gt;All very odd and I can&amp;#39;t figure it out at the moment. Not a show stopper, I can live with having to start up with the BG96 button, and unless it&amp;#39;s not&amp;nbsp;complete the RAK5010 schematic doesn&amp;#39;t show any reason why this might happen.&lt;/p&gt;
&lt;p&gt;If I can find a way to get to the power and clock lines somewhere I&amp;#39;ll have a go at monitoring those at some point.&lt;/p&gt;
&lt;p&gt;thanks again.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360491?ContentTypeID=1</link><pubDate>Tue, 29 Mar 2022 09:31:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7ee3e449-c13a-4740-8044-ef78e029f31a</guid><dc:creator>mrono</dc:creator><description>&lt;p&gt;Power, clock and (optionally) reset is all that should be needed to start up. So unless the GPS module is controlling one of those then the nRF should start.&lt;/p&gt;
&lt;p&gt;The only other option I can think of is a bootloader that is programmed to wait for input from the GPS module. You did say you wiped everything, but is it possible that there is still a piece of code left that runs before your application?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360447?ContentTypeID=1</link><pubDate>Tue, 29 Mar 2022 07:55:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8b9925f0-3e88-4110-a88a-ebf57cbca992</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;Are you sure you don&amp;#39;t have enabled pin reset by accident? There is no obvious reason why it should not start immediately.&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360396?ContentTypeID=1</link><pubDate>Mon, 28 Mar 2022 22:21:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b0428421-56e0-4679-9578-151a0ac1f4e5</guid><dc:creator>Ivor Hewitt</dc:creator><description>&lt;p&gt;OK&amp;nbsp;wiped everything completely, started with blinky which showed the same behaviour (dead until the BG96 was turned on) and I couldn&amp;#39;t see any interesting voltage changes anywhere with the oscilloscope. so. wrote a small test program, that set those BG96 outputs as pulldown with interrupt and a log event:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nrfx_gpiote_in_config_t in_config =&lt;br /&gt;NRFX_GPIOTE_CONFIG_IN_SENSE_TOGGLE(true);&lt;br /&gt;in_config.pull = NRF_GPIO_PIN_PULLDOWN;&lt;br /&gt;...&lt;/code&gt;&lt;br /&gt;&lt;code&gt;void in_pin_handler(nrfx_gpiote_pin_t pin, nrf_gpiote_polarity_t action)&lt;/code&gt;&lt;br /&gt;&lt;code&gt;{&lt;/code&gt;&lt;br /&gt;&lt;code&gt; bool set = nrfx_gpiote_in_is_set(pin);&lt;/code&gt;&lt;br /&gt;&lt;code&gt; NRF_LOG_INFO(&amp;quot;Pin %d - %d&amp;quot;, pin, set);&lt;/code&gt;&lt;br /&gt;&lt;code&gt;}&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;while already running I&amp;nbsp;turn&amp;nbsp;the BG96 off, and then back on. When it starts up, there&amp;#39;s a 4 second delay and&amp;nbsp;then the following sequence of pin events:&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 31 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 8 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 11 - 0 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 11 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 11 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 11 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 0 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 0 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 1 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 0 &lt;/code&gt;&lt;br /&gt;&lt;code&gt;&amp;lt;info&amp;gt; app: Pin 27 - 1&lt;/code&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Is there any reason why any of those might trigger the nRF to&amp;nbsp;start booting up?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360362?ContentTypeID=1</link><pubDate>Mon, 28 Mar 2022 15:35:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b9c404a0-bc08-4d2c-8177-59ecc5b40592</guid><dc:creator>Ivor Hewitt</dc:creator><description>&lt;p&gt;Thanks for the tips, I&amp;#39;ll experiment this evening.&amp;nbsp;Unfortunately it&amp;#39;s awkward to check all the pins&amp;nbsp;directly since the RAK5010 is (understandably) quite tightly integrated on their board.&lt;br /&gt;So I&amp;#39;m still trying to understand from their schematic how powering&amp;nbsp;up the BG96&amp;nbsp;would trigger the nRF52840 to boot. (the BG96 is only connected to nRF through GPIO pins using 2,3,6,7,8,11,26,27,28,29,30,31 - of those only 3,8,11,27,31 are the output lines)&lt;br /&gt;I&amp;#39;ll put an oscilloscope on the pins I can get to and see if anything&amp;#39;s going on and will try this with a clear firmware and a blinky app.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Auto run on power up</title><link>https://devzone.nordicsemi.com/thread/360245?ContentTypeID=1</link><pubDate>Mon, 28 Mar 2022 10:59:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:365b6873-cc69-405a-8f08-256d89e990b4</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;To find out if it&amp;#39;s hardware or software related, I recommend to start with a simple blinky project: a short main() with init a gpio and turn ON a LED. Make sure to erase the nRF52840 first by for instance run &amp;#39;nrfjprog --eraseall&amp;#39;. If the chip does not execute when power supply is applied, then you need to check that the schematic is followed and the voltage applied is within operating conditions (measure with an oscilloscope or multimeter). Make sure no gpio&amp;#39;s are powered while supply voltage is not turned ON.&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>