<?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>BLE GATT Notification Limit - I request 1000 IDs and receive about 408.</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/119215/ble-gatt-notification-limit---i-request-1000-ids-and-receive-about-408</link><description>I&amp;#39;m developing based on the Nordic Academy example here, but I noticed that when transmitting a large amount of data, something is limiting the amount sent by the NRF52832. I couldn&amp;#39;t figure out what is causing this limitation. ( https://github.com/NordicDeveloperAcademy</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 28 Feb 2025 09:11:17 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/119215/ble-gatt-notification-limit---i-request-1000-ids-and-receive-about-408" /><item><title>RE: BLE GATT Notification Limit - I request 1000 IDs and receive about 408.</title><link>https://devzone.nordicsemi.com/thread/525218?ContentTypeID=1</link><pubDate>Fri, 28 Feb 2025 09:11:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a0aaddaa-1fa2-41ac-881f-731f1918f078</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
[quote user="Guimodena"]When I request a large number of IDs the program sends several data packets each with around 250 bytes, but there comes a point when it simply stops sending the packets. [/quote]
&lt;p&gt;As far as I remember it&amp;#39;s blocking function when you try to queue BLE packet to be sent. Meaning if the buffer is full, it will be blocked at the function and wait for the data to be sent. Try avoid staying in an event handler for too long. It can cause issue. You should send BLE commands from a thread context.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE GATT Notification Limit - I request 1000 IDs and receive about 408.</title><link>https://devzone.nordicsemi.com/thread/525136?ContentTypeID=1</link><pubDate>Thu, 27 Feb 2025 17:00:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:08646a0b-f287-4659-9000-5a630d5c04b0</guid><dc:creator>Guimodena</dc:creator><description>&lt;p&gt;Hi Hung, yes, I tried using logs and prints to understand better. &lt;br /&gt;&lt;br /&gt;I still haven&amp;#39;t been able to understand who is limiting this total amount of data transmitted. &lt;br /&gt;&lt;br /&gt;When I request a large number of IDs the program sends several data packets each with around 250 bytes, but there comes a point when it simply stops sending the packets. Why does there come a time when it stops sending even though there is still data left to be sent? I haven&amp;#39;t figured it out yet, I don&amp;#39;t know if this is an internal layer in bluetooth and I still don&amp;#39;t know how to deal with it.&lt;br /&gt;&lt;br /&gt;My next step will be to try to migrate to a thread like your suggestion.&lt;br /&gt;&lt;br /&gt;Thank you very much&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE GATT Notification Limit - I request 1000 IDs and receive about 408.</title><link>https://devzone.nordicsemi.com/thread/524382?ContentTypeID=1</link><pubDate>Mon, 24 Feb 2025 14:34:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:81c0e256-1205-47df-a308-f68317e88506</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Guilherme,&amp;nbsp;&lt;br /&gt;Have you tried to use some log to check why only 400IDs is received. I don&amp;#39;t see the reason why&amp;nbsp;BLE couldn&amp;#39;t transfer more than that.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not so familiar with the code in the video tutorial but i would suggest to add some log inside&amp;nbsp;send_tail() to tell where the issue is. You can show in the log if the id has been buffered to send to BLE or not.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;My understanding is the send_tail() function is executed in an interrupt context. Maybe it&amp;#39;s not the best practice if you are starting to send thousand of notification. Could you try to do the task in a thread/work instead?&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>