<?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>Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/13378/pairing-and-key-exhange-with-ancs</link><description>Hi. 
 I&amp;#39;ve started to check if I can get ANCS compatible content provider to run in Android. The nrf52 is running out-of-box version of the nordic ancs example. 
 I can find it, see that it solicitates the ANCS service in the advertisement and I can</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 25 Apr 2016 12:10:05 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/13378/pairing-and-key-exhange-with-ancs" /><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51041?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2016 12:10:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f08d9bf2-bc93-4147-8db6-2a0bff3e981c</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Now also the notifications go trough. Thanks for the support!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51045?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2016 07:43:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:712a04e6-2b84-4c7f-ae53-f642b997b88a</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Matts,&lt;/p&gt;
&lt;p&gt;Correct, you would need an extra board to sniff the connection. I can&amp;#39;t think of anything else other than the issue with Android since the proximity app should work. I assume that you did a full erase of the chip when testing it, just to make sure the old bond information is erased.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51044?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2016 07:30:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5d56be89-56e3-4cf1-859e-0ffdd40cc211</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Ok, now the connection is not dropping anymore. I think this issue is solved.&lt;/p&gt;
&lt;p&gt;However just for future use, could you answer the sniffer question?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51043?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2016 07:15:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7b337428-9b99-4ef2-a04b-9c4a51b8a9d1</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Ok, the pairing succeeded atlast! Bluetooth off + shutdown + battery off repeated 3 times did the trick! The connection is still dropped in 5 seconds, but some progress!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51042?ContentTypeID=1</link><pubDate>Mon, 25 Apr 2016 06:47:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:30f2bbfd-69f3-40fb-bc26-4cd3aff6dff8</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Hi.&lt;/p&gt;
&lt;p&gt;No asserts with the nrf board. the board version is PCA10040 V1.1.0 2016.9
SDK is nRF5_SDK_11.0.0_89a8197.&lt;/p&gt;
&lt;p&gt;I&amp;#39;ll try to get another phone HW. I was involved with another project related to bluetooth year a go. We run into situation in android end that something in non-volatile data corrupted (some setting or something) and it didn&amp;#39;t recover without several reboots and removal of battery. This might be similar case.&lt;/p&gt;
&lt;p&gt;Regarding sniffer: How should I sniff the connection? I mean I have only one nrf board. Can I connect to sniffer with the android and use the siffer to analyze the connection? The setup in the instructions seems to be that two separate devices communicate and sniffer just sniffs in the side.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51040?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 13:56:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c9321098-b3f0-496d-94ea-254857e72b6e</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;I suspect there could be something wrong with the phone. Could you try to test with other phone ? Also a reset on the current phone is worth to try.&lt;/p&gt;
&lt;p&gt;Could you check if there is any assert on the nRF52 ? Did it reset when the bonding failed ?&lt;/p&gt;
&lt;p&gt;Also please let me know the chip revision and the SDK, softdevice version you are testing .&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51039?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 12:31:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:212c411c-df46-4645-8c0f-ea92f87a2642</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;And just to clarify:&lt;/p&gt;
&lt;p&gt;Just trying to connect with nRF MCP app with the nrf52 + ANCS example app fails similarily as my app.&lt;/p&gt;
&lt;p&gt;I also tested the proximity example, and I couldn&amp;#39;t pair it, nor connect to it with nRF control panel. I get error 129 (0x81) GATT INTERNAL ERROR and Error 8 (0x08): GATT CONN TIMEOUT.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51038?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 12:23:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:36be2ce1-073e-42f8-bd34-87692b35a585</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Matts,&lt;/p&gt;
&lt;p&gt;Please capture the &lt;a href="https://www.nordicsemi.com/eng/Products/Bluetooth-Smart-Bluetooth-low-energy/nRF-Sniffer/(language)/eng-GB"&gt;sniffer trace&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;And please test bonding with any example such as the proximity example. From the nRF MCP log, it&amp;#39;s showing that the device disconnect in the pairing process. Have you made sure you don&amp;#39;t exceed the maximum number of bonded central ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51037?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 12:18:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0f3aa066-8c4c-4072-a67a-b4d3e7465f9c</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Ok, I have that installed. I also found some logging from the nRF MCP and it&amp;#39;s attached to question above. Also I&amp;#39;ve got HCL logs open in wireshark. Anything specific I could check from those?&lt;/p&gt;
&lt;p&gt;And yes, the nRF52 with example works just fine with iPhone. And what I&amp;#39;m trying to do here, is to get similar communication protocol for android app so that we do not have to have both ANS and ANCS supports in the nRF board.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51035?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 11:22:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6bf08c95-f9e2-48a9-9e86-f7f0a55a0dcb</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Matts,&lt;/p&gt;
&lt;p&gt;I was talking about the nRF Master Control Panel on Android (or iOS). We also have an app for the mobile platforms.&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t think we have any further than the documentation from Apple about ANCS &lt;a href="https://developer.apple.com/library/ios/documentation/CoreBluetooth/Reference/AppleNotificationCenterServiceSpecification/Specification/Specification.html#//apple_ref/doc/uid/TP40013460-CH1-SW8"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Could you clarify that you have tested and everything worked fine when you test with iOS device instead of Android ?&lt;/p&gt;
&lt;p&gt;The concept should be the same, on Android and iOS. The only difference is on Android you need to make the server yourself, and handle the notification provider on your own.&lt;/p&gt;
&lt;p&gt;The flow of communication is described in the diagram in the documentation from Apple above.
You connect and bond from the phone (the ANCS server) after that the client should start to discover the service and subscribe to the characteristic(s).&lt;/p&gt;
&lt;p&gt;Seems that you has problem with bonding, please try to test bonding with other example, such as proximity example.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51034?ContentTypeID=1</link><pubDate>Fri, 22 Apr 2016 08:50:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bb04f595-a171-4b8f-aa02-547ab6cad3c8</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Also regarding the communication initialization:&lt;/p&gt;
&lt;p&gt;Does the Content Provider connect the Consumer directly? I get connection to GattServer just by making the bond call. If the CP should connect directly, should that be via GattServer.connect or via gatt client (bluetoothdevice.connectGatt)?&lt;/p&gt;
&lt;p&gt;Also should the Content provider read/write something to Content Consumer (nrf board)?&lt;/p&gt;
&lt;p&gt;Hopefully I can get the jlink ultra connected to this today and get more info what happens in the nrf board. Also trying to get HCL logs from the android side.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51032?ContentTypeID=1</link><pubDate>Thu, 21 Apr 2016 13:40:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dc58c929-c33d-448c-a7f9-eeeee27e87bd</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;I&amp;#39;ve seen the apple document for content consumer developers. But is there any flow how the initial communication should go? I mean in the apple document there wasn&amp;#39;t even mention about the CCCD:s in the characterics.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51036?ContentTypeID=1</link><pubDate>Thu, 21 Apr 2016 13:38:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb5a6a73-f8c5-421e-bb3d-d25516dd14ec</guid><dc:creator>Matts</dc:creator><description>&lt;p&gt;Hi Hung Bui!&lt;/p&gt;
&lt;p&gt;I cannot use the nRF MCP as I do not have windows machine. I have however iPhone 5 for testing purposes and it connects OK with the nRF52.&lt;/p&gt;
&lt;p&gt;Regarding that connection dropping. I have GattServer with that new service running in the android phone. I&amp;#39;ve tried connecting with the device both via regular gatt connection and server connection. Not sure which is the correct way, but result is the same.&lt;/p&gt;
&lt;p&gt;In onConnected callback I&amp;#39;ll try to do the bonding (bluetoothdevice.createBond() -call). It gives me first BluetoothDevice.ACTION_BOND_STATE_CHANGED to BluetoothDevice.BOND_BONDING. However right after that (300ms later) I get onConnectionStateChange -callback with disconnected state and callback to BluetoothDevice.ACTION_BOND_STATE_CHANGED with value BOND_NONE.&lt;/p&gt;
&lt;p&gt;What most bothers me, that I get error status (on connection drop) that no read rights or value 62.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Pairing and key exhange with ANCS</title><link>https://devzone.nordicsemi.com/thread/51033?ContentTypeID=1</link><pubDate>Thu, 21 Apr 2016 12:10:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1f9493a3-038f-430d-98f3-14669746b603</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Matts,&lt;/p&gt;
&lt;p&gt;You should have BOND_BONDED if it&amp;#39;s successfully bonded. I suspect there could be an issue here. You may want to capture a sniffer trace to see what was wrong.
If you use nRF Master Control Panel to connect and bond, do you have any problem ?
Note that the key exchange process is handled by Android and the app doesn&amp;#39;t need to do anything (except for triggering the bonding process)&lt;/p&gt;
&lt;p&gt;Could you explain &amp;quot;but it drops it right away&amp;quot; ? Does that mean the connection was dropped ? Again, a sniffer trace would reveal more info.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>