<?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>change advertising every time (event ?)</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/9137/change-advertising-every-time-event</link><description>Hello, 
 I have to change custom advertising every time to create an anti replay system. 
 Is there any event fired after each advertising sent ?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 10 Sep 2015 11:22:03 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/9137/change-advertising-every-time-event" /><item><title>RE: change advertising every time (event ?)</title><link>https://devzone.nordicsemi.com/thread/33674?ContentTypeID=1</link><pubDate>Thu, 10 Sep 2015 11:22:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:757e9698-b2e8-4fe4-90c1-b764895cbfea</guid><dc:creator>Fabien Comte</dc:creator><description>&lt;p&gt;perfect, thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: change advertising every time (event ?)</title><link>https://devzone.nordicsemi.com/thread/33673?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 09:33:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:958bd1dc-f7cf-4cf7-b1d5-059bcdc69a09</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;You need to enable radio notification.
You can enable it for nACTIVE signal, which will make SD to send the application an event after every advertising event ended. Then you can configure your packet for next packet in that event.&lt;/p&gt;
&lt;p&gt;Here is an example&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;void ble_on_radio_active_evt(bool radio_active)
{
     // change adv packet here
}

static void radio_notification_init(void)
{
    uint32_t err_code;

    err_code = ble_radio_notification_init(NRF_APP_PRIORITY_LOW,
                                           NRF_RADIO_NOTIFICATION_DISTANCE_800US,
                                           ble_on_radio_active_evt);
    err_code = sd_radio_notification_cfg_set(NRF_RADIO_NOTIFICATION_TYPE_INT_ON_INACTIVE,
                                             NRF_RADIO_NOTIFICATION_DISTANCE_800US);
    APP_ERROR_CHECK(err_code);
}


int main(void)
{
...
    radio_notification_init();
...
}
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>