<?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>I can not re-program the nrf51822. Why?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/583/i-can-not-re-program-the-nrf51822-why</link><description>I have uploaded the following code, but I can not re-program the next. 
 

#define AREF0 0
#define AIN3 2
#define AIN4 3


int main(void)
	{
// Start 16 MHz crystal oscillator 
 NRF_CLOCK-&amp;gt;EVENTS_HFCLKSTARTED = 0;
 NRF_CLOCK-&amp;gt;TASKS_HFCLKSTART</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 03 Oct 2013 10:23:21 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/583/i-can-not-re-program-the-nrf51822-why" /><item><title>RE: I can not re-program the nrf51822. Why?</title><link>https://devzone.nordicsemi.com/thread/3027?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2013 10:23:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8e089030-40cb-4361-be8f-82a9dbd65a6d</guid><dc:creator>Peter</dc:creator><description>&lt;p&gt;Thank you very much! :D
It works. :D&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: I can not re-program the nrf51822. Why?</title><link>https://devzone.nordicsemi.com/thread/3026?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2013 10:14:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2700b262-ce06-4532-aa8e-8d276c1fa52c</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Peter,&lt;/p&gt;
&lt;p&gt;You need to wake the chip up before you can program it. The programmer can not wake it up when it entered System off mode.&lt;/p&gt;
&lt;p&gt;What you can do is to use nRGo Studio to recover the chip, you should be able to program it again after that.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>