<?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>Can&amp;#39;t send two separate BLE indications</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/124384/can-t-send-two-separate-ble-indications</link><description>Starting with the lbs example from lesson l4e2 of BT fundamentals course, I&amp;#39;d like to send an indication similar to the button (and keep the button). I basically created duplicates of everything related to the button and pointed it to different data.</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 16 Sep 2025 18:42:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/124384/can-t-send-two-separate-ble-indications" /><item><title>RE: Can't send two separate BLE indications</title><link>https://devzone.nordicsemi.com/thread/548939?ContentTypeID=1</link><pubDate>Tue, 16 Sep 2025 18:42:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4449a051-a15a-4c16-b3f5-c1b55316463e</guid><dc:creator>kruenheck</dc:creator><description>&lt;p&gt;Thank you, that helps a lot.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Can't send two separate BLE indications</title><link>https://devzone.nordicsemi.com/thread/548915?ContentTypeID=1</link><pubDate>Tue, 16 Sep 2025 14:41:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ffe5cfc-dd86-4c33-83c0-f64bdf3cbf40</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;You were on the right track. The problem, as you pointed out, is that ind_params.attr must point to the correct attribute handle (the one matching the characteristic you are trying to send the indication from). &amp;amp;my_lbs_svc.attrs[2] points to the value handle for your BT_UUID_LBS_BUTTON characteristic, which is correct for&amp;nbsp;&lt;span&gt;my_lbs_send_button_state_indicate(), but this index needs to be updated in&amp;nbsp;my_lbs_send_kdr_state_indicate().&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;amp;my_lbs_svc.attrs[4] or&amp;nbsp;&amp;amp;my_lbs_svc.attrs[5] should work for&amp;nbsp;&amp;nbsp;my_lbs_send_kdr_state_indicate().&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;int my_lbs_send_kdr_state_indicate(bool kdr_state)
{
    if (!indicate_enabled)              
    {
        return -EACCES;
    }
    ind_params.attr = &amp;amp;my_lbs_svc.attrs[5];
    ind_params.func = indicate_cb;
    ind_params.destroy = NULL;
    ind_params.data = &amp;amp;kdr_state;
    ind_params.len = sizeof(kdr_state);
    return bt_gatt_indicate(NULL, &amp;amp;ind_params);
}&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;How you can find this index is explained in section 5.2 of the&amp;nbsp;exercise your are working with.&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;Vidar&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>