<?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>When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/119305/when-ble-is-paired-advertising-cannot-be-restarted</link><description>Hi, 
 After updating to NCS 2.9.0, I found that if the device is already paired, advertising cannot be started. I have configured CONFIG_BT_MAX_CONN=3.</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 06 Mar 2025 02:17:18 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/119305/when-ble-is-paired-advertising-cannot-be-restarted" /><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/526083?ContentTypeID=1</link><pubDate>Thu, 06 Mar 2025 02:17:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8cf8bc81-97e1-434a-b0ac-6a45e188565b</guid><dc:creator>SunHuang</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I have already resolved the issue. The differences between the old and new versions made me overlook some configurations.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/525682?ContentTypeID=1</link><pubDate>Tue, 04 Mar 2025 10:19:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d31d6333-29b6-43b4-ac66-a3fe92f188f3</guid><dc:creator>Edvin</dc:creator><description>[quote user="Edvin Holmseth"]CONFIG_BT_CTLR_SDC_PERIPHERAL_COUNT=2[/quote]
&lt;p&gt;Did you try this one?&lt;/p&gt;
[quote user="SunHuang"]BLE advertising should restart automatically[/quote]
&lt;p&gt;That depends on the definition of &amp;quot;automatically&amp;quot;. It needs to be done from the application, but apparently it is being done, since it fails.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;But did you try the config: CONFIG_BT_CTLR_SDC_PERIPHERAL_COUNT=2 ?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/525633?ContentTypeID=1</link><pubDate>Tue, 04 Mar 2025 05:46:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b97908a2-6b5f-4da6-9803-2778259bd714</guid><dc:creator>SunHuang</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p data-start="0" data-end="234"&gt;No, I did not use any features related to Matter. Please focus on the BLE advertising issue. I believe that when &lt;code data-start="113" data-end="133"&gt;CONFIG_BT_MAX_CONN&lt;/code&gt; is greater than 1, the device should automatically restart advertising after a successful pairing.&lt;/p&gt;
&lt;p data-start="236" data-end="501"&gt;The error message &lt;code data-start="254" data-end="294"&gt;&amp;quot;Failed to start BLE advertising: -12&amp;quot;&lt;/code&gt; is the result of my intentional call to &lt;code data-start="335" data-end="365"&gt;BleService::StartAdvertising&lt;/code&gt;. In reality, BLE advertising should restart automatically, but it is clear that this version of the SDK does not handle it correctly.&lt;/p&gt;
&lt;p data-start="503" data-end="612"&gt;If I want to allow multiple pairings, besides &lt;code data-start="549" data-end="569"&gt;CONFIG_BT_MAX_CONN&lt;/code&gt;, what other configurations are required?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/525544?ContentTypeID=1</link><pubDate>Mon, 03 Mar 2025 14:24:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fd441692-4693-4778-901f-a9db4aed3f28</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;At this point, is the device provisioned into your Matter network, or is it not?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/524943?ContentTypeID=1</link><pubDate>Thu, 27 Feb 2025 01:31:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2f7f7ee0-90b7-4cf0-a25a-b909b22e7a5b</guid><dc:creator>SunHuang</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Yes, the example I used is NCS 2.9.0 Matter Lock. The expected state is Matter + BLE + multiple-to-one connection.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/524826?ContentTypeID=1</link><pubDate>Wed, 26 Feb 2025 13:52:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1368cd2d-1de0-46f4-903c-aad35b04f914</guid><dc:creator>Edvin</dc:creator><description>[quote user="Edvin Holmseth"]&lt;p&gt;Are you doing normal BLE advertising, or do you have some other radio protocol as well?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;So you are using &lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/protocols/matter/index.html"&gt;Matter&lt;/a&gt;, right? Is that intentional, or did you choose this application because it was using C++?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/524764?ContentTypeID=1</link><pubDate>Wed, 26 Feb 2025 09:19:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7324e926-7702-4a57-a214-a927640f4d7c</guid><dc:creator>SunHuang</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Basically, my BLE service is built based on NUS. So it&amp;#39;s just &lt;span&gt;normal&amp;nbsp;&lt;/span&gt;advertising. What other information do you need to diagnose the issue? By the way, I don&amp;#39;t need the CENTRAL role.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;bool BleService::StartAdvertising() {
  if (madvStarted) {    
    LOG_INF(&amp;quot;BLE advertising is already started&amp;quot;);
    return false;
  }

  CHIP_ERROR ret = BLEAdvertisingArbiter::InsertRequest(mAdvertisingRequest);
        
  if (CHIP_NO_ERROR != ret) {
    LOG_ERR(&amp;quot;Could not start BLE advertising&amp;quot;);
    return false;
  }
  madvStarted = true;

  LOG_INF(&amp;quot;BLE advertising has started&amp;quot;);
  return true;
}&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: When BLE is paired, advertising cannot be restarted</title><link>https://devzone.nordicsemi.com/thread/524635?ContentTypeID=1</link><pubDate>Tue, 25 Feb 2025 14:18:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1436a2b0-24d6-466c-be1b-601807c7442f</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;It is difficult to say without more context. What function returned the value -12? Are you doing normal BLE advertising, or do you have some other radio protocol as well?&lt;/p&gt;
&lt;p&gt;Does your build log say anything that would suggest that the CONFIG_BT_MAX_CONN is not set to 3?&lt;/p&gt;
&lt;p&gt;Do you support scanning/central? CONFIG_BT_CENTRAL=y?&lt;/p&gt;
&lt;p&gt;If so, you also need to specify:&lt;/p&gt;
&lt;p&gt;CONFIG_BT_CTLR_SDC_PERIPHERAL_COUNT=2&lt;/p&gt;
&lt;p&gt;or whatever value you want it to be. It will default to 1 if CONFIG_BT_CENTRAL is set to y.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>