<?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>Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/5625/device-manager-event-handler</link><description>Hi all,
Please can anyone explain when the device_manager_event_handler() is triggred ?
And also, what difference between on_ble_evt() and on_sys_evt() and when they are executed ?
Thanks.</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 20 Feb 2015 10:18:19 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/5625/device-manager-event-handler" /><item><title>RE: Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/thread/19705?ContentTypeID=1</link><pubDate>Fri, 20 Feb 2015 10:18:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:66a9f6e1-1685-4853-883a-c8e43e9e9096</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;@mohBOSS: You are correct. device_manager_event_handler is called on every BLE event, however, we only interested in connection establishing, security procedure , etc.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/thread/19704?ContentTypeID=1</link><pubDate>Thu, 19 Feb 2015 16:03:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b625bf7f-2eab-467f-902a-1d5a160a584d</guid><dc:creator>mohBOSS</dc:creator><description>&lt;p&gt;I think that I got the answer. The  device_manager_event_handler() is executed in these cases: link with the peer is established or torn down, Security procedure, link was re-established , etc&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/thread/19702?ContentTypeID=1</link><pubDate>Thu, 19 Feb 2015 15:53:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c86906d1-dccc-48b5-989c-a07ba6c2da5f</guid><dc:creator>mohBOSS</dc:creator><description>&lt;p&gt;Ok, when a ble event is ready ( exple: BLE_GAP_EVT_ADV_REPORT event ), does the device_manager_event_handler() executed, or simply the on_ble_evt() is executed ( throw ble_evt_dispatch()). In fact, this is what I am looking for dear Hung.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/thread/19703?ContentTypeID=1</link><pubDate>Thu, 19 Feb 2015 15:39:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3d5610b1-e003-440a-8651-9b2e6c2f7749</guid><dc:creator>mohBOSS</dc:creator><description>&lt;p&gt;Yes I have already seen it. Thanks.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Manager Event Handler</title><link>https://devzone.nordicsemi.com/thread/19701?ContentTypeID=1</link><pubDate>Thu, 19 Feb 2015 15:32:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9d073fa9-6b55-47ba-8336-063067d236e2</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi mohBOSS,&lt;/p&gt;
&lt;p&gt;device_manager_event_handler() is assigned to by param.evt_handler  in device_manager_init. Then evt_handler is assigned to m_application_table[0].ntf_cb and it will be called in app_evt_notify() when dm_pstorage_cb_handler() and/or dm_ble_evt_handler() executed.&lt;/p&gt;
&lt;p&gt;Regarding on_ble_evt() and on_sys_evt(), I think I gave an answer &lt;a href="https://devzone.nordicsemi.com/question/29908/how-does-ble-interrupts-work/"&gt;here&lt;/a&gt;. Please continue on that case.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>