<?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>sd_ble_gatts_hvx - Blocking or Non Blocking function</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/49656/sd_ble_gatts_hvx---blocking-or-non-blocking-function</link><description>I am trying to use sd_ble_gatts_hvx function to send custom data through BLE. I found out that for the data I am sending the function takes a lot of time to send data which results in a FIFO error on the UART module. 
 For this reason, I wanted to know</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 15 Jul 2019 13:49:15 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/49656/sd_ble_gatts_hvx---blocking-or-non-blocking-function" /><item><title>RE: sd_ble_gatts_hvx - Blocking or Non Blocking function</title><link>https://devzone.nordicsemi.com/thread/198505?ContentTypeID=1</link><pubDate>Mon, 15 Jul 2019 13:49:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:25903382-1018-4606-a215-86f100a8c933</guid><dc:creator>Prithvi</dc:creator><description>&lt;p&gt;Thanks a lot! It works.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: sd_ble_gatts_hvx - Blocking or Non Blocking function</title><link>https://devzone.nordicsemi.com/thread/198175?ContentTypeID=1</link><pubDate>Fri, 12 Jul 2019 12:55:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eeba0433-7179-4673-a9aa-e454c4237c73</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It might be that you are doing &amp;quot;just too much&amp;quot; in your interrupt function. Try to shorten your interrupt handler (ie: the uart_evt_handler()) and instead set boolean flags which you handle in your main function for instance.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: sd_ble_gatts_hvx - Blocking or Non Blocking function</title><link>https://devzone.nordicsemi.com/thread/198018?ContentTypeID=1</link><pubDate>Fri, 12 Jul 2019 07:39:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:37d70dcc-69af-4aa5-b2cd-f57e27def8bb</guid><dc:creator>Prithvi</dc:creator><description>&lt;p&gt;Thank you for this information!&lt;/p&gt;
&lt;p&gt;In my use case have continuous values coming onto the UART lines at 57600 baud rate.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m reading these values using app_uart_get() and storing them in an array in the uart_event_handle function. I&amp;#39;m performing parsing on the incoming packets on the UART lines and storing the result of parsing in a data buffer of 20 bytes. I send the values on this buffer through BLE using the&amp;nbsp;sd_ble_gatts_hvx() function.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;When I run the code on the board, I get a FIFO ERROR with an error code of 1 or an error code of 4.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;When I comment out the&amp;nbsp;sd_ble_gatts_hvx() part of the code in the&amp;nbsp;&lt;span&gt;uart_event_handle function the code runs smoothly and there is no FIFO ERROR.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Could you please let me know if there is a way to avoid this FIFO error while using the&amp;nbsp;sd_ble_gatts_hvx() function?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I cannot afford to drop data.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: sd_ble_gatts_hvx - Blocking or Non Blocking function</title><link>https://devzone.nordicsemi.com/thread/197994?ContentTypeID=1</link><pubDate>Fri, 12 Jul 2019 06:56:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b1a39209-bf5b-4c91-9bd4-25fd000aec12</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It&amp;#39;s non-blocking. It returns the status in a event after the connection interval has finished. For more detailed info, please see this message sequence chart:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v6.1.1/group___b_l_e___g_a_t_t_s___h_v_n___m_s_c.html"&gt;https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v6.1.1/group___b_l_e___g_a_t_t_s___h_v_n___m_s_c.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>