<?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>Zephyr BLE: bt_le_scan_start Fails with Error -5 (-EIO)</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/103399/zephyr-ble-bt_le_scan_start-fails-with-error--5--eio</link><description>I was running BLE tests between two nrf52dk boards and from time to time I saw the error message as below: 
 W: opcode 0x2005 status 0x0c 
 And my debug message showed as: BLE_GAP_StartScan error (err = -5), which printed out when the function bt_le_scan_start</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 06 Sep 2023 07:31:19 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/103399/zephyr-ble-bt_le_scan_start-fails-with-error--5--eio" /><item><title>RE: Zephyr BLE: bt_le_scan_start Fails with Error -5 (-EIO)</title><link>https://devzone.nordicsemi.com/thread/444633?ContentTypeID=1</link><pubDate>Wed, 06 Sep 2023 07:31:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d5d8e8c3-8793-4c20-9d3c-5e656c42e046</guid><dc:creator>AHaug</dc:creator><description>&lt;p&gt;Thank you for clarifying&lt;/p&gt;
[quote user="wliao"]1. I didn&amp;#39;t record the callstack last time but I will if I have the same issue next time.[/quote]
&lt;p&gt;Let me know if you find something there&lt;/p&gt;
[quote user="wliao"]5. I also noticed there was a similar complain about this error last year, here is the link:[/quote]
&lt;p&gt;Do you mean &amp;quot;Similar&amp;quot;, or &amp;quot;Identical and reproduceable on your firmware&amp;quot;? This report were posted in 2022&amp;nbsp;where they used NCS v2.1.0,&amp;nbsp;meaning that this might have been fixed in later versions.&lt;/p&gt;
&lt;p&gt;I will check if I&amp;#39;m able to reproduce the steps in the bug report in v2.4.0 with two 52840dks but it might be a while before I have time to do so. In the meanwhile let me know if you&amp;#39;re able to reproduce it on your firmware.&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;br /&gt;Andreas&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zephyr BLE: bt_le_scan_start Fails with Error -5 (-EIO)</title><link>https://devzone.nordicsemi.com/thread/444563?ContentTypeID=1</link><pubDate>Tue, 05 Sep 2023 16:33:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ca20e2a9-cdca-4720-b495-f277eb2dc6bc</guid><dc:creator>wliao</dc:creator><description>&lt;p&gt;1. I didn&amp;#39;t record the callstack last time but I will if I have the same issue next time.&lt;/p&gt;
&lt;p&gt;2. The test was based on our custom code.&lt;/p&gt;
&lt;p&gt;3. The SDK is v2.4.0 of nrf Connect SDK&lt;/p&gt;
&lt;p&gt;4. As to the test itself we just&amp;nbsp;ran the cycle of&amp;nbsp;connecting, exchanging some data, disconnecting and reconnecting to&amp;nbsp;make sure the communication robust.&lt;/p&gt;
&lt;p&gt;5. I also noticed there was a similar complain about this error last year, here is the link:&lt;/p&gt;
&lt;p&gt;&lt;a id="" href="https://github.com/zephyrproject-rtos/zephyr/issues/50438"&gt;https://github.com/zephyrproject-rtos/zephyr/issues/50438&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zephyr BLE: bt_le_scan_start Fails with Error -5 (-EIO)</title><link>https://devzone.nordicsemi.com/thread/444329?ContentTypeID=1</link><pubDate>Mon, 04 Sep 2023 12:55:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f6318a81-67f1-4417-84a3-eb14d1100524</guid><dc:creator>AHaug</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Could you elaborate some ore about what you&amp;#39;ve done?&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Have you traced where in the callstack this error is triggered? It could lie deeper than bt_le_scan_start()&lt;/li&gt;
&lt;li&gt;Are you basing your tests on any samples existing in nRF Connect SDK?&lt;/li&gt;
&lt;li&gt;What SDK are you using?&lt;/li&gt;
&lt;li&gt;Are you aiming for anything specific with your tests? If so are there any information there that might be relevant, for instance if you&amp;#39;ve written custom code the fault may be caused by not using the API correct&lt;/li&gt;
&lt;/ol&gt;
[quote user=""]Could it be a BLE stack issue?[/quote]
&lt;p&gt;From &lt;a href="https://docs.zephyrproject.org/apidoc/latest/group__bt__gap.html#gac5e19c26b53a08dadb8efa7ecc692ad6"&gt;https://docs.zephyrproject.org/apidoc/latest/group__bt__gap.html#gac5e19c26b53a08dadb8efa7ecc692ad6&lt;/a&gt;&amp;nbsp;you can see that a negative (POSIX) error number is returned&amp;nbsp;in case of stack internal error.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;br /&gt;Andreas&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>