<?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>Application won&amp;#39;t run, unable debug</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/7617/application-won-t-run-unable-debug</link><description>Hi,
I&amp;#39;m unable to run any application on nrf51 DK (Keil used). When I start debug (no matter what application I load), program always cycles between 2 instructions: 
 0x000006CC BF20 WFE 
0x000006CE E7FD B 0x000006CC 
 This happens even when blinky</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 10 Jul 2015 07:46:55 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/7617/application-won-t-run-unable-debug" /><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27186?ContentTypeID=1</link><pubDate>Fri, 10 Jul 2015 07:46:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0f37db5c-7562-44e7-9432-b5097bf6b2e9</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;lets not make this thread any longer, create another thread and I will pick it up immediately. Is this ok?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27185?ContentTypeID=1</link><pubDate>Fri, 10 Jul 2015 07:41:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:05f80712-7d8f-4bff-904b-787cb8864eaf</guid><dc:creator>Victor Nascimento</dc:creator><description>&lt;p&gt;Shouldn&amp;#39;t fail indeed. I had a ARM7 board and could debug it just fine with Keil 4. I flashed with Keil and also tried to debug with Keil, no success.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27184?ContentTypeID=1</link><pubDate>Fri, 10 Jul 2015 07:07:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6a2b94c3-8b50-47be-b36e-a892aa0e1b57</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Halting your application should be OK, the problem occurs only if you are trying to step over sd_xx funtions. You are sure that your application runs ok? have you flashed the application with keil or nrfjprog? flash the application with Keil and try again. This is the basic functionality that should not fail with keil&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27183?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 17:04:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f978662-2056-4cc3-8a99-daa5b1bee631</guid><dc:creator>Victor Nascimento</dc:creator><description>&lt;p&gt;But I don&amp;#39;t even want to debug. Halting in a particular line would be great just to watch some variables. But my code never halts on any BP.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27182?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 16:59:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:83540e7c-618a-4bac-9151-88dee6943a18</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;It is not possible to debug softdevice applications. Rather use printf.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27181?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 16:57:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b52d2cc3-1dd4-4717-839d-123f2b9472f5</guid><dc:creator>Victor Nascimento</dc:creator><description>&lt;p&gt;My code just works fine. But when I try to debug, it&amp;#39;s stuck on WFE + Branch.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27180?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 16:56:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e123a46b-86fc-4e7b-b2b2-8183b76a4451</guid><dc:creator>Victor Nascimento</dc:creator><description>&lt;p&gt;A breakpoint on main&amp;#39;s first line wont hit. If I click pause, it stands on WFE.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27179?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 12:05:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f3821c6f-3757-4eee-b898-5b6e1277db60</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Please read all the comments here, I described what I did in order to make nr51 working again.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27178?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 12:04:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2e8a92b0-e54b-4985-88df-ae552b5506f6</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Victor, can you give me more details of your problem, is this WFE in your main.c? can you put a breakpoint at the first line in main and see if it gets a hit?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27177?ContentTypeID=1</link><pubDate>Thu, 09 Jul 2015 11:58:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ede7890-a954-495d-b3fc-e599c64c0d9c</guid><dc:creator>Victor Nascimento</dc:creator><description>&lt;p&gt;I have the same problem. Did you figure out a solution to the WFE+branch in debug session?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27176?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 20:23:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8a82d22f-55c2-4786-8620-7c01ccb8ad32</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;I don&amp;#39;t know, probably something was corrupted while flashing in keil, I can&amp;#39;t explain it with full confidence as I have not seen it myself. But now that it works and this thread has a solution you can close this case.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27175?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 20:01:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cee49220-8b0a-4399-b90d-31933cc67817</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Thanks. That explains that erase error when flashing non softdevice projects. But the main problem was unability to run softdevice+application (stuck on WFE instruction) until I downloaded it using nrfgo studio. Why that?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27174?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 19:54:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb35dbeb-d169-4bef-8db0-f4fd902fd3a0</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;The problem is that once you have softdevice+application working, you have to erase full flash either using nrfgostudio or &amp;quot;nrfjprog -e&amp;quot;.
If you do not erase the softdevice before trying blank project from Keil, if wont erase softdevice because of the Nordic flash algorithm for Keil. Try &amp;quot;nrfjprog -e&amp;quot; from command line and try your blank blinky project, i am sure that it will work. There is nothing wrong with your DK&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27173?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 19:27:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c66a2b2d-ebd9-4fee-b652-838e7af06ce3</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Can you please exaplin why this happened? Was some chip security accidentaly enabled so I was not able to run application? Flashing alghorithms obviously differs in nrfgo studio and Keil, as nrfgo studio is able to bring nrf51 chip back to life.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27187?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 19:26:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a5010882-08ef-4bf4-8133-2b3ea81984f5</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Wow. I used nrfgo studio with default settings to download softdevice and then to download application to nrf51 DK. It worked! Now I&amp;#39;m again able to download and debug all aplications from Keil. All applications except applications not using softdevice (e.g. blank blinky example). For non softdevice applications I get Erase error in Keil. To be able to download and debug non softdevice applications when there is softdevice application present in nrf51, I have to do Erase all from nrf go studio. Flash -&amp;gt; Erase option in Keil doesn&amp;#39;t enable downloading, still getting Erase all error after that.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27172?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 17:49:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3c23fdfb-8f17-44f8-a7b5-c7d67fc1e8ff</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Is the nrf51 DK bad? What should I do? I was able to develop my applications for 5 days, now I spent two days stuck with this problem unable to make any progress in my project. Please advise as soon as possible.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27171?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 17:47:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f5e49d71-859e-4039-bdde-a2296886c656</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;I made fresh installation of Keil and nordic packages on another computer. Same symptoms.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27170?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 17:04:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2a804e2b-73c5-480a-a983-b0ba23a06deb</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Also, downloading bsp_pca10028 project into nrf51 ends ith Erase flash error in Keil. In CrossStudio downloading this project worksworks. Generally it seems that I&amp;#39;m unable to download all non softdevice example projects in Keil. The same projects can be downloaded in CrossStudio and work.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27169?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:39:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:598db074-9cfa-493a-ab2d-ea7c28ca4b1e</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Blinky blank project for PCA10028&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Compiled in Keil.&lt;/li&gt;
&lt;li&gt;Tried to download it to nrf51 in Keil. Unable due to Erase flash error. Tried several times.&lt;/li&gt;
&lt;li&gt;Downloaded the same hex via CrossStudio - success. Verified.&lt;/li&gt;
&lt;li&gt;The blinky app works.&lt;/li&gt;
&lt;li&gt;Did full chip erase in Keil. Done. However the application is still in nrf51, after reset, LEDs blink.&lt;/li&gt;
&lt;/ol&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27168?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:11:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0b2fe793-d646-4252-8f40-1ac105f4d2e2</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;IROM1 and IRAM1 addresses are exactly the same 0x18000, 0x28000, 0x20002000, 0x6000, so correct. But as I have mentioned already - I use example projects with no changes. They must be correct.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27167?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:08:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eddc6daa-2a35-4e2c-a9d6-8d0197a3d14a</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;I also uninstalled and installed again Keil uVision, all nordic semi packages in Keil, deleted all example projects I already created. With no luck. There must be something bad with the nrf51 chip.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27166?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:07:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ff19c20a-d4c6-4f4e-9fda-330bcee6baf4</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;In CrossStudio for ARM debugging of blank project works.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27165?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:07:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:96d1e595-b927-47c8-990f-394098095fc2</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Maybe the application is flashed to the wrong the address. Check if your blinky project is flashed with correct IRAM and IROM settings
&lt;a href="https://devzone.nordicsemi.com/question/31703/nrf51822-iram-and-irom-settings-for-s110-sd/"&gt;devzone.nordicsemi.com/.../&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27164?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 16:06:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ec813486-7abc-44c2-8fb1-e56e6ab495c6</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;The disassembly immediately after debugging is started shows:&lt;/p&gt;
&lt;p&gt;0x000006D0 4916      LDR      r1,[pc,#88]  ; @0x0000072C&lt;/p&gt;
&lt;p&gt;in all projects.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Application won't run, unable debug</title><link>https://devzone.nordicsemi.com/thread/27163?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2015 15:14:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a6f87e2-a77e-4296-93be-c0ea49093c67</guid><dc:creator>gaminn</dc:creator><description>&lt;p&gt;Another remark - It seems that both softdevice and application are downloaded to the nrf51 (through another IDE - CrossStudio for ARM - I verified that both hex are there). However something prevents application from running, the application stucks at the addresses I mentioned above.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>