<?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>nrf51822 radio interrupt ???</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/12299/nrf51822-radio-interrupt</link><description>I have two device , one is Tx-Device the other is Rx-Device. 
 Tx-Device : Auto continued Send 4 bytes data to Rx-Device by Radio. 
 Rx-Device : Using Radio Interrupt receive data from Tx-Device Radio,if receive data then Led is action , And main loop</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 07 Mar 2016 09:18:37 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/12299/nrf51822-radio-interrupt" /><item><title>RE: nrf51822 radio interrupt ???</title><link>https://devzone.nordicsemi.com/thread/46509?ContentTypeID=1</link><pubDate>Mon, 07 Mar 2016 09:18:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1ec5521a-c7f0-4a09-ab13-f1d234b04e5a</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;I have updated my answer, hopefully it answers your question. I would again recommend you to take a look at micro ESB.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf51822 radio interrupt ???</title><link>https://devzone.nordicsemi.com/thread/46508?ContentTypeID=1</link><pubDate>Fri, 04 Mar 2016 09:46:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:62b32b6a-ac2e-4d25-9933-53fb2e05d56e</guid><dc:creator>BenBenBen</dc:creator><description>&lt;p&gt;Thanks Kirdtin .&lt;/p&gt;
&lt;p&gt;How to modify in RADIO_IRQHandler to sloved ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf51822 radio interrupt ???</title><link>https://devzone.nordicsemi.com/thread/46507?ContentTypeID=1</link><pubDate>Thu, 03 Mar 2016 13:50:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e7e9d912-fb6f-4d44-91f2-ab2c35253922</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;The reason why &amp;quot;Start&amp;quot; is only printed once is most likely due to the implementation of RADIO_IRQHandler:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;In Radio_init() INSTENSET is set to trigger on the events READY and ADDRESS. However, in the interrupt handler there is no check for those events and they are never cleared. Since those events are never cleared, it will create a forever loop that calls the interrupt handler.&lt;/li&gt;
&lt;li&gt;Inside RADIO_IRQHandler, there is a loop over EVENTS_END, and  the interrupt handler will hang there until it receives a packet. Since the READY and ADDRESS events never are being cleared, RADIO_IRQHandler can/will be triggered without receiving a packet. In that case the EVENTS_END loop will be a forever loop.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I would recommend you to take a look at the radio examples in the SDK ( ..examples\peripheral\radio ) and the &lt;a href="https://github.com/NordicSemiconductor/nrf51-micro-esb"&gt;micro ESB library&lt;/a&gt; on github.&lt;/p&gt;
&lt;p&gt;Clearing of events in RADIO_IRQHandler(..) can be done the following way:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;void RADIO_IRQHandler()
{
    if(NRF_RADIO-&amp;gt;EVENTS_READY &amp;amp;&amp;amp; (NRF_RADIO-&amp;gt;INTENSET &amp;amp; RADIO_INTENSET_READY_Msk))
    {
        NRF_RADIO-&amp;gt;EVENTS_READY = 0;
}

if(NRF_RADIO-&amp;gt;EVENTS_END &amp;amp;&amp;amp; (NRF_RADIO-&amp;gt;INTENSET &amp;amp; RADIO_INTENSET_END_Msk))
{
    NRF_RADIO-&amp;gt;EVENTS_END = 0;
    }
}

if(NRF_RADIO-&amp;gt;EVENTS_ADDRESS &amp;amp;&amp;amp; (NRF_RADIO-&amp;gt;INTENSET &amp;amp; RADIO_INTENSET_ADDRESS_Msk))
{
    NRF_RADIO-&amp;gt;EVENTS_ADDRESS= 0;
}
 ... some code 
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;In addition, I you can consider to set up the EVENTS_END event to trigger interrupt:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  NRF_RADIO-&amp;gt;INTENSET    =  RADIO_INTENSET_END_Msk;
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>