<?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>Simple central.</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/33527/simple-central</link><description>Hi! I want to implement at BLE switch(PTM215B) to a nRF52 DK, The switch sends advertise messages with switch status data. So i want to create a simple central that scans for the switch. I just copied the ble_blinky central from the SDK V.15 exampels</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 24 Apr 2018 05:48:07 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/33527/simple-central" /><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/129439?ContentTypeID=1</link><pubDate>Tue, 24 Apr 2018 05:48:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2d19aac6-6eaa-457d-9704-a4b769d0ebce</guid><dc:creator>WilliamJangren</dc:creator><description>&lt;p&gt;thanks! i use m_scan_buffer_data[8] to acess data since i only need the 8th byte.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/129377?ContentTypeID=1</link><pubDate>Mon, 23 Apr 2018 14:13:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8927cf60-11a3-411f-8885-ba863ce4ec29</guid><dc:creator>Mttrinh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The BLE address and data is part of the advertising packet, and you can access it when you get the event&amp;nbsp;&lt;code&gt;BLE_GAP_EVT_ADV_REPORT&lt;/code&gt;. You can print out the BLE address like below after you get the event. Take a look at the function &lt;em&gt;ble_evt_handler&lt;/em&gt; in the ble_app_uart_c example.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;NRF_LOG_INFO(&amp;quot;Connecting to target %02x%02x%02x%02x%02x%02x&amp;quot;,
                     p_adv_report-&amp;gt;peer_addr.addr[0],
                     p_adv_report-&amp;gt;peer_addr.addr[1],
                     p_adv_report-&amp;gt;peer_addr.addr[2],
                     p_adv_report-&amp;gt;peer_addr.addr[3],
                     p_adv_report-&amp;gt;peer_addr.addr[4],
                     p_adv_report-&amp;gt;peer_addr.addr[5]
                     );&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;You can store the data and address after getting the BLE_GAP_ADV_REPORT event. Do you want to store it in flash?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/128957?ContentTypeID=1</link><pubDate>Thu, 19 Apr 2018 11:42:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:97bbcbb1-0048-4a2b-9de2-9921dff0d777</guid><dc:creator>WilliamJangren</dc:creator><description>&lt;p&gt;I guess the most important part is the scan_start function and the&amp;nbsp;BLE_GAP_EVT_ADV_REPORT case in the&amp;nbsp;&amp;nbsp;ble_evt_handler function. can i in the BLE_GAP_ADV_REPORT case store data and adress to the advertise device easy?&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Im not even sure that i get the advertise messages from the switch. is there any way to print in the terminal the adress to all nearby advertising devices.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/128819?ContentTypeID=1</link><pubDate>Wed, 18 Apr 2018 13:24:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:616292ab-010a-4bfd-a388-74188cd57404</guid><dc:creator>WilliamJangren</dc:creator><description>&lt;p&gt;Hi thanks for answering!&lt;/p&gt;
&lt;p&gt;I have read that tutorial but still dont get how i store the advertise data in a variable. But i guess i have to go through it again. &amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/128811?ContentTypeID=1</link><pubDate>Wed, 18 Apr 2018 13:09:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0bf726e3-e326-4171-a5cb-b44df4800a01</guid><dc:creator>Mttrinh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I suggest you to go through this &lt;a href="https://devzone.nordicsemi.com/tutorials/b/bluetooth-low-energy/posts/ble-central-tutorial" target="_blank" rel="noopener noreferrer"&gt;tutorial&lt;/a&gt;. In this tutorial you will set up a NUS server, but I think it will help you to understand how you can set up a simple central that will do what you mentioned above.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Simple central.</title><link>https://devzone.nordicsemi.com/thread/128756?ContentTypeID=1</link><pubDate>Wed, 18 Apr 2018 09:20:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:09142ad7-12fc-494d-8dbd-33086f7e2620</guid><dc:creator>WilliamJangren</dc:creator><description>&lt;p&gt;To clarify what i want to do:&lt;br /&gt;&lt;br /&gt;I want to scan for the switch(PTM215B) and read the advertise report and store the data in a variable. i dont want to connect to the switch. is there a tutorial or something like that for this? In the blinky example there are many functions do i need all if no which funktions do i need?&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>