<?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: timing of call back function: notification acknowledged</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/128455/ble-timing-of-call-back-function-notification-acknowledged</link><description>Hi 
 In nordic connect sdk (2.6.0) a notfication on a peripheral device is send by bt_gatt_notify_cb. The second parameter of this function (bt_gatt_notify_params) is a struct which may be used. It contains a callback funtion which is called after the</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 16 Jun 2026 11:49:12 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/128455/ble-timing-of-call-back-function-notification-acknowledged" /><item><title>RE: BLE: timing of call back function: notification acknowledged</title><link>https://devzone.nordicsemi.com/thread/567980?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2026 11:49:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:092b51ac-56f6-431e-b107-8f1ce55e94b4</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Klaus,&amp;nbsp;&lt;br /&gt;As I mentioned all BLE packet when in connection are ACKed at the link layer.&amp;nbsp;Link layer is very low in the BLE stack&amp;nbsp;right above the PHY layer:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1781609086519v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;A new LL packet only sent if the previous is ACKed.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;But on the ATT layer there is no acknowledgment for notification, this mean the sender has no way to know if the receive has received the notification packet at the ATT layer on the destination (the link layer can ack but the ATT may not receive/process the packet for some reason). The sender may send next notification even though the first notification has not been processed. This is different from indication that the new indication can only be sent if the pervious indication has been ACKed on the ATT layer at the peer device.&amp;nbsp;&lt;/p&gt;
[quote user="klaus1234"]&lt;p&gt;Is the call back function called after the message being acked by the link layer?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;The callback is called when the buffer on the Host has sent the notification to the controller (LL ) not when it&amp;#39;s ACKed on the Link layer. See here:&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/host/Kconfig.gatt#L41"&gt;https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/host/Kconfig.gatt#L41&lt;/a&gt;&lt;/p&gt;
[quote user="klaus1234"]In case of a retransmission, is the function called multiple times?[/quote]
&lt;p&gt;No,&amp;nbsp;retransmission is&amp;nbsp;handled by Link Layer and it&amp;#39;s transparent to the layers above.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote user="klaus1234"]&lt;p&gt;Where in the documentation is all this described? I am having trouble to find the right spots in the documentation.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;I would suggest to follow our devacademy here:&amp;nbsp;&lt;br /&gt;&lt;a href="https://academy.nordicsemi.com/courses/bluetooth-low-energy-fundamentals/"&gt;https://academy.nordicsemi.com/courses/bluetooth-low-energy-fundamentals/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;But for the deeper knowledge on Bluetooth Low Energy, I would suggest to find a book. For example this:&amp;nbsp;&lt;a href="https://www.oreilly.com/library/view/getting-started-with/9781491900550/"&gt;https://www.oreilly.com/library/view/getting-started-with/9781491900550/&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE: timing of call back function: notification acknowledged</title><link>https://devzone.nordicsemi.com/thread/567965?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2026 08:08:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7030d9ee-f613-49a3-aab4-3fb7979e7ae0</guid><dc:creator>klaus1234</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;would you please clairify this:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Question 1:&amp;nbsp;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;You write;&lt;/p&gt;
&lt;p&gt;&amp;gt;&amp;gt;When sending a notification there will be no&amp;nbsp;acknowledgement from the central.&lt;/p&gt;
&lt;p&gt;Further below you write there will be an ACK on the Link layer. This means central received the packet correctly.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;So what is true?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Second question:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Is the call back function called after the message being acked by the link layer?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3rd question:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;In case of a retransmission, is the function called multiple times?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4th question:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Where in the documentation is all this described? I am having trouble to find the right spots in the documentation.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE: timing of call back function: notification acknowledged</title><link>https://devzone.nordicsemi.com/thread/567960?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2026 07:47:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:94f363fe-d317-47cf-9e55-d51058939b24</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Klaus,&amp;nbsp;&lt;br /&gt;&lt;br /&gt;When sending a notification there will be no&amp;nbsp;acknowledgement from the central. It&amp;#39;s is different from &amp;quot;indication&amp;quot;. When you send an indication the peer device is expected to send an ACK for confirmation.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The callback you receive is when the server (peripheral in your case) finish sending the notification. Answer C is closest to when the function is called. But you can have multiple notification sending in one connection event so the call back may cover multiple notification.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Note that at ATT layer you don&amp;#39;t have ACK for notification, but at Link layer, all packets are acknowledged with the SN and NESN bit for flow control. Packet will be retransmitted if it doesn&amp;#39;t get acknowledgment from the peer device.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>