<?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>Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/9127/custom-uart-ble-read-fails</link><description>Hello,
I have a custom program based on the uart example. I can write to the device, but sending to the master fails.
I call the SendString code, but p_nus-&amp;gt;is_notification_enabled is always false. Looking through the code, the only place this flag</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 10 Sep 2015 09:10:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/9127/custom-uart-ble-read-fails" /><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33643?ContentTypeID=1</link><pubDate>Thu, 10 Sep 2015 09:10:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e8d5600a-0244-428c-8ab4-670d2b0d0e39</guid><dc:creator>Lodge</dc:creator><description>&lt;p&gt;Hi Alex,
I am not sure how that worked, but I have added the notification and it works now. I am using Visual C++, not cs and there is a good example of how to do it here in case anyone is interested
&lt;a href="https://social.msdn.microsoft.com/Forums/en-US/bad452cb-4fc2-4a86-9b60-070b43577cc9/is-there-a-simple-example-desktop-programming-c-for-bluetooth-low-energy-devices?forum=wdk"&gt;link text&lt;/a&gt;
It works great now, thanks so much&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33642?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 11:01:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:33040e3d-f739-48d9-8d46-1319a075a54a</guid><dc:creator>Alex</dc:creator><description>&lt;p&gt;I understand that your PC is master/client and nRF51 is slave/server. In that case client can read data from server but server can&amp;#39;t send data directly, only using notification/indication. I don&amp;#39;t understand how your lost nrf code could initiate sending data without notification enabled.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33641?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 10:37:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:180a29c4-9403-49f4-a8b6-972e288f62ab</guid><dc:creator>Lodge</dc:creator><description>&lt;p&gt;Hi Alex,
Thanks again for all the information and I am sorry for all the questions.
Is this the only way to send data to the application? The reason I ask is I had the communication working perfectly, but lost the nrf project code when my PC crashed. I have the original windows App code and I didn&amp;#39;t have to enable notifications. I have re-written the nrf51 code, but am getting the above error. Is there a way to send data to the server without notifications? I only need to read about 100 bytes of configuration data on connection from the app, and I don&amp;#39;t need to notify when it gets changed.
Again, thanks for all the help.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33640?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 09:11:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3e377f1e-fd86-4c7d-8fce-6e5fb799795b</guid><dc:creator>Alex</dc:creator><description>&lt;p&gt;Short and nice explanation is &lt;a href="https://devzone.nordicsemi.com/question/310/notificationindication-difference/"&gt;here&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33639?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 09:06:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:92925ee5-8f08-46c0-866b-2b8f263dcf65</guid><dc:creator>Lodge</dc:creator><description>&lt;p&gt;Hi Alex,
Thanks again. I will try that. Out of interest, you mention you can send data to master either by notification or indication. Could you explain how indication works?
Much appreciated.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33638?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 08:57:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:615ddbfc-589d-4240-bf12-4d9129b5e9b0</guid><dc:creator>Alex</dc:creator><description>&lt;p&gt;In W8 you can enable notification by:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;gatt_characteristic.WriteClientCharacteristicConfigurationDescriptorAsync(
                                            CHARACTERISTIC_NOTIFICATION_TYPE);
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;where&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;gatt_characteristic = service.GetCharacteristics(UUIDofcharacteristic)[0];
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;and &lt;code&gt;service = await GattDeviceService.FromIdAsync(deviceId);&lt;/code&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33637?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 07:49:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d246906e-be84-4685-adb4-bec7f1c2f6a0</guid><dc:creator>Alex</dc:creator><description>&lt;p&gt;Why don&amp;#39;t you enable notification in Windows 8 application?  This is how data send from device to master, either by notification or indication. Give me some time, I&amp;#39;ll find the command which enables notification in our W8 code&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33636?ContentTypeID=1</link><pubDate>Wed, 09 Sep 2015 07:38:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:29c8dc89-d26a-463c-8fab-372596e9e582</guid><dc:creator>Lodge</dc:creator><description>&lt;p&gt;Hi Alex,
Thanks for the reply. Does this mean that I have to enable notifications from the master side before I can send data to it? What I am doing at the moment is sending data to the device from a custom windows 8 application with a read command. I then want to send about 5 packets of data back to the master. This is failing when I call the SendString command for the above reason. Is there a way to do this without enabling notifications?
Thanks very much,
Lodge.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom UART BLE Read fails</title><link>https://devzone.nordicsemi.com/thread/33635?ContentTypeID=1</link><pubDate>Tue, 08 Sep 2015 15:53:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2be41534-c41e-45a9-b704-6faa7fbb7d72</guid><dc:creator>Alex</dc:creator><description>&lt;p&gt;That part of the code called when you enable notification from master. For example in Master Control Panel in Android connect to your device, choose service and then on right hand side of characteristic you will see three down arrows. Press on them and notification will be enabled. If you are using your own application then you need to enable notification in your application before the first SendString used in the device&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>