<?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>Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/54363/increase-characteristic-value-max-length</link><description>Sorry ,I have the problem with increasing the max data length(more then 20 bytes) in the characteristic , I change the att_mtu size like the value in the picture, but after I changed it, I can&amp;#39;t even detect my device name , is there any else I have to</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 21 Nov 2019 07:11:33 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/54363/increase-characteristic-value-max-length" /><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/221207?ContentTypeID=1</link><pubDate>Thu, 21 Nov 2019 07:11:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:232a360d-8050-4470-ad46-0e47f0ae6ac1</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;Thank you!!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/221042?ContentTypeID=1</link><pubDate>Wed, 20 Nov 2019 11:37:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:20307f58-65de-4ff4-94f3-7105a39a92b2</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;When you get the&amp;nbsp;&lt;span&gt;NRF_ERROR_RESOURCES&amp;nbsp;return code from&amp;nbsp;sd_ble_gatts_hvx , then the notfication/indication will not be queued and you need to call&amp;nbsp;sd_ble_gatts_hvx() again with the same parameters when you get the&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group___b_l_e___g_a_t_t_s___e_n_u_m_e_r_a_t_i_o_n_s.html#ggae537647902af1b05c1e32f12d6b401c7afab96bfa9918017082235f7664919f9d"&gt;BLE_GATTS_EVT_HVN_TX_COMPLETE&lt;/a&gt;&amp;nbsp;event.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;As stated previously the connection event will be closed if there aren&amp;#39;t any more packets in the queue. So if there are only one or two packets in the queue, then those will be sent and the connection event will be closed. It will only remain &amp;quot;open&amp;quot; as long as there are packets to send. So it should not affect the current consumption that much, but this will depend on how many packets you send.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Best regards&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Bjørn&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220964?ContentTypeID=1</link><pubDate>Wed, 20 Nov 2019 04:36:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:759fbf5a-84be-4824-88ea-69b9ea5d59af</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;Thank you very much ! Can I ask the last question is that if&amp;nbsp;&lt;span&gt;NRF_ERROR_RESOURCES happens ,the data will be loose or send in next notify, if my NRF_SDH_BLE_GAP_EVENT_LENGTH&amp;nbsp;is same as my connection interval the power&amp;nbsp;consumption will increase?&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220614?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 14:12:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0addd860-5611-4820-9bb1-48b80425a4e2</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Ok. Please check if the&amp;nbsp;sd_ble_cfg_set call that passes the &lt;span&gt;NRF_SDH_BLE_GAP_EVENT_LENGTH&amp;nbsp;&amp;nbsp;to the SD in&lt;/span&gt;&amp;nbsp;nrf_sdh_ble_default_cfg_set() does not return an error code. Also check if you end up in the&amp;nbsp;app_error_handler_bare() error handler.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Regarding your previous comment. If you get the&amp;nbsp;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group__nrf__error.html#gac94383171545e604e8347a044e8be13f"&gt;NRF_ERROR_RESOURCES&lt;/a&gt;&amp;nbsp;return code from&amp;nbsp;&lt;span&gt;sd_ble_gatts_hvx&amp;nbsp;, then you need to increase the&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/structble__gatts__conn__cfg__t.html#ae2a1156d8b06a6ccc70696f2372226cc"&gt;ble_gatts_conn_cfg_t::hvn_tx_queue_size&lt;/a&gt;&amp;nbsp;as stated in the API doc.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Best regards&lt;/p&gt;
&lt;p&gt;Bjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220562?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 12:33:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3835e2d5-d718-4ec0-9f13-3e9ef3b6087f</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;So if I can put the package&amp;nbsp; into queue if I use&amp;nbsp;sd_ble_gatts_hvx&lt;strong&gt;&lt;span&gt; ,&lt;/span&gt;&lt;/strong&gt;&amp;nbsp;and send the data to client&amp;nbsp; every connection interval or &lt;span&gt;NRF_SDH_BLE_GAP_EVENT_LENGTH&lt;/span&gt;? if&amp;nbsp; it happened&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group__nrf__error.html#gac94383171545e604e8347a044e8be13f"&gt;NRF_ERROR_RESOURCES&lt;/a&gt;&lt;span&gt;.&amp;nbsp; it will loose the data , I have tested that&amp;nbsp; if my &amp;nbsp;sd_ble_gatts_hvx event is shorter longer than connection interval&amp;nbsp;,but it will almost always happen when I set the &amp;nbsp;sd_ble_gatts_hvx event to 1ms?&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;In addition ,how can this problem happen?&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/same_5F00_time.JPG" /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220550?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 12:05:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8c8d5fd-3164-4112-910c-faa9ac5742d6</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;&lt;span&gt;Im not sure if you will be able to get out two packets if&amp;nbsp;sd_ble_gatts_hvx is called every 3ms. It could be that the SD will end the connection event if there are no data in the queue. So if you update the data and call&amp;nbsp;sd_ble_gatts_hvx right before the start of the connection event and then call&amp;nbsp;sd_ble_gatts_hvx again after 3ms, then the connection event may already be closed. However then you should be see two packets going out on the next connection event if&amp;nbsp;sd_ble_gatts_hvx was called twice before the start of the event. If you are getting NRF_ERROR_RESOURCES when calling&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group___b_l_e___g_a_t_t_s___f_u_n_c_t_i_o_n_s.html#ga313fe43c2e93267da668572e885945db"&gt;sd_ble_gatts_hvx&lt;/a&gt;&amp;nbsp;then please see the API doc, quoted below.&amp;nbsp;&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The number of Handle Value Notifications that can be queued is configured by&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/structble__gatts__conn__cfg__t.html#ae2a1156d8b06a6ccc70696f2372226cc"&gt;ble_gatts_conn_cfg_t::hvn_tx_queue_size&lt;/a&gt;&amp;nbsp;When the queue is full, the function call will return&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group__nrf__error.html#gac94383171545e604e8347a044e8be13f"&gt;NRF_ERROR_RESOURCES&lt;/a&gt;. A&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group___b_l_e___g_a_t_t_s___e_n_u_m_e_r_a_t_i_o_n_s.html#ggae537647902af1b05c1e32f12d6b401c7afab96bfa9918017082235f7664919f9d"&gt;BLE_GATTS_EVT_HVN_TX_COMPLETE&lt;/a&gt;&amp;nbsp;event will be issued as soon as the transmission of the notification is complete.The application can keep track of the available queue element count for notifications by following the procedure below:&lt;/span&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Store initial queue element count in a variable.&lt;/li&gt;
&lt;li&gt;Decrement the variable, which stores the currently available queue element count, by one when a call to this function returns&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group__nrf__error.html#ga7e6367efeaac363d8cf024940b4ec123"&gt;NRF_SUCCESS&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Increment the variable, which stores the current available queue element count, by the count variable in&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.0.1/group___b_l_e___g_a_t_t_s___e_n_u_m_e_r_a_t_i_o_n_s.html#ggae537647902af1b05c1e32f12d6b401c7afab96bfa9918017082235f7664919f9d"&gt;BLE_GATTS_EVT_HVN_TX_COMPLETE&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;event.&lt;/li&gt;
&lt;/ul&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220536?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 11:26:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5b3c4679-efff-4889-9d92-49f96827e572</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;I change the&amp;nbsp;&lt;span&gt;NRF_SDH_BLE_GAP_EVENT_LENGTH&amp;nbsp; to 7.5 but my dongle cannot detect my device again&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220530?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 10:53:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cc05e07d-a77e-43e9-a8fc-0ceb371eaa54</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;If my data is upgraded&amp;nbsp; every 3 ms(by &lt;span&gt; &lt;/span&gt;sd_ble_gatts_hvx) and connection interval is 7.5ms ,will it send two packages in one connection interval ? I&amp;nbsp; have test the error code of&amp;nbsp;&amp;nbsp;&lt;strong&gt;&lt;span&gt; &lt;/span&gt;sd_ble_gatts_hvx and it will have chance to return 19(error resources ) if my&amp;nbsp;&lt;span&gt;sd_ble_gatts_hvx time is shorter than&amp;nbsp;connection interval&amp;nbsp; In addition, if I use the dongle to get the data, is it possible to get more than one package in one connection interval?&amp;nbsp;&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220515?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 10:01:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d1392a40-b35b-4f26-a12c-4622cefbd7f8</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Hi Geass77,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;you can send packets as long as there is room to schedule it before the next connection event.&amp;nbsp; You can extend the length of the connection event by setting the&amp;nbsp;NRF_SDH_BLE_GAP_EVENT_LENGTH in the sdk_config.h file. If you want to send data until the next connection event, then set the&amp;nbsp;NRF_SDH_BLE_GAP_EVENT_LENGTH equal to the connection interval.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220458?ContentTypeID=1</link><pubDate>Mon, 18 Nov 2019 03:59:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7ba4dcbe-a052-499b-a6ad-5151e471389b</guid><dc:creator>Geass77</dc:creator><description>&lt;p&gt;Yes,but I fix the problem when I change the register start address, can I ask how to how to calculate the throughput , if my&amp;nbsp;&lt;/p&gt;
&lt;p&gt;time interval is 7.5 ms, and my att_mtu size is 247 byte, my throughput is like 247 /7.5ms ,however, I don&amp;#39;t know how many package can I send in one connection interval ,and the number of characteristic is related to throughput&amp;nbsp;or not.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Increase characteristic value max length</title><link>https://devzone.nordicsemi.com/thread/220298?ContentTypeID=1</link><pubDate>Fri, 15 Nov 2019 12:30:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b2953907-8d63-422f-bad4-074a1b64b91f</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Hi Geass77,&lt;/p&gt;
[quote user=""] I change the att_mtu size like the value in the picture, but after I changed it, I&amp;nbsp; can&amp;#39;t even detect my device name ,[/quote]
&lt;p&gt;DO you mean that the nRF is not advertising after you change the&amp;nbsp; GATT max MTU size?&lt;/p&gt;
&lt;p&gt;Best regards&lt;/p&gt;
&lt;p&gt;Bjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>