<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://test-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 scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/f/nordic-q-a/87884/ble-scan-and-uart-data-reception-issue</link><description>Hello, All: 
 I have a problem, when I turn on bluetooth scanning, my UART can&amp;#39;t process the received data in time. 
 When I only use UART to send and receive data, it is normal, but after turning on the Bluetooth scanning function (after turning on the</description><dc:language>en-US</dc:language><generator>Telligent Community 13 Non-Production</generator><lastBuildDate>Mon, 30 May 2022 11:58:28 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://test-devzone.nordicsemi.com/f/nordic-q-a/87884/ble-scan-and-uart-data-reception-issue" /><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/369972?ContentTypeID=1</link><pubDate>Mon, 30 May 2022 11:58:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8dde330e-fc47-4999-b589-4677925c3996</guid><dc:creator>user72692</dc:creator><description>&lt;p&gt;I&amp;#39;m still not able to reproduce your issue. I set up 5 advertisers around the device running your sample and waited respectively 5 and 9 minutes, but the serial log showed up immediately.&lt;/p&gt;
&lt;p&gt;However, could you try the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Increase the priority of the thread handling the UART communication and turn down the priority of the other threads
&lt;ul&gt;
&lt;li&gt;This may be useful:&amp;nbsp;&lt;a href="https://www.youtube.com/watch?v=kV9Ab0Opxyc"&gt;https://www.youtube.com/watch?v=kV9Ab0Opxyc&lt;/a&gt;&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Use less aggressive scan parameters&lt;/li&gt;
&lt;li&gt;Use flow control&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Also, could you check if you&amp;#39;re able to reproduce the issue in an area without any BLE activity, so we can confirm that the issue is actually due to the scanner handling adv. packets.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/369615?ContentTypeID=1</link><pubDate>Wed, 25 May 2022 19:41:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0f03ffd2-6fd6-41f2-9d57-d8f873c2d766</guid><dc:creator>user72692</dc:creator><description>&lt;p&gt;I&amp;#39;m not able to reproduce it. I did the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Modifed the file nrf52840dk_nrf52840.overlay like shown below, so uart0 is connected to the interface MCU and the computer&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;&amp;amp;uart0 {
	compatible = &amp;quot;nordic,nrf-uarte&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	current-speed = &amp;lt;1000000&amp;gt;;
//	hw-flow-control;
	/*tx-pin = &amp;lt;6&amp;gt;;
	rx-pin = &amp;lt;4&amp;gt;;
	rts-pin = &amp;lt;41&amp;gt;;
	cts-pin = &amp;lt;8&amp;gt;;*/
};
&lt;/pre&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Built and flashed the sample to an nRF52840DK v3.0.0&lt;/li&gt;
&lt;li&gt;Opened RTT Viewer and a Termite instance with the following settings&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src="https://test-devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/6710.pastedimage1653507070087v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I saw that the program started by looking at the RTT logs&lt;/li&gt;
&lt;li&gt;Waited around 7 minutes and sent the following through termite: &amp;quot;1234567890&amp;quot; and got the following response in RTT &lt;strong&gt;1-2 seconds later&lt;/strong&gt;:&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;00&amp;gt; [00:07:45.290,069] &amp;lt;inf&amp;gt; mt_uart: Evt RX_READY.
00&amp;gt; [00:07:45.290,191] &amp;lt;inf&amp;gt; mt_uart: Evt RX_BUF_REL.
00&amp;gt; [00:07:45.290,222] &amp;lt;inf&amp;gt; mt_uart: Evt RX_BUF_REL.
00&amp;gt; [00:07:45.290,252] &amp;lt;inf&amp;gt; mt_uart: Evt RX_DISABLE.
00&amp;gt; [00:07:45.290,313] &amp;lt;inf&amp;gt; mt_uart: Evt RX_BUF_REQ.
00&amp;gt; [00:07:45.290,435] &amp;lt;inf&amp;gt; event_manager: [0038] UART_RECV_REPORT
00&amp;gt; [00:07:45.290,527] &amp;lt;inf&amp;gt; main: UART received data:
00&amp;gt;                                31 32 33 34 35 36 37 38  39 30 0a                |12345678 90.&lt;/pre&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I waited 10 more minutes and sent a new string, but I got the response immediately&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Maybe it is because I&amp;#39;m in home office without much advertising around, and the scanner is not too busy parsing packets. I will try in the office on Monday.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simohn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/369349?ContentTypeID=1</link><pubDate>Tue, 24 May 2022 15:29:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e6a4f2ed-0b12-486e-ba02-6cc771e78976</guid><dc:creator>user72692</dc:creator><description>&lt;p&gt;Sorry for the delay on this, I&amp;#39;ve been quite busy lately. I will priotize your issue tomorrow&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/369134?ContentTypeID=1</link><pubDate>Tue, 24 May 2022 02:18:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e3d203e9-bb4e-4579-b213-8d43af7587b1</guid><dc:creator>user104364</dc:creator><description>&lt;p&gt;How&amp;#39;s it going? Did you find a problem?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/368446?ContentTypeID=1</link><pubDate>Wed, 18 May 2022 15:35:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6fc9b102-08e4-489d-a42d-947491ee4fe1</guid><dc:creator>user72692</dc:creator><description>&lt;p&gt;Thanks for uploading the project. I will take a look at it tomorrow&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/368184?ContentTypeID=1</link><pubDate>Wed, 18 May 2022 06:14:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:32085af1-38f9-4739-b853-6984a8f7d39f</guid><dc:creator>user104364</dc:creator><description>&lt;p&gt;&lt;a href="https://test-devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/nrf52.zip"&gt;test-devzone.nordicsemi.com/.../nrf52.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Here is my test demo.&lt;/p&gt;
&lt;p&gt;Originally, I used nRF9160 to communicate with it. The nRF9160 sends data through key control. Now it is connected to the PC and tested through the serial port tool.&lt;/p&gt;
&lt;p&gt;The device runs normally at the beginning, wait for a period of time (a few minutes or more) and then send data through the serial port assistant on the PC side, the device cannot receive it immediately, and prompts to receive data after a long delay.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE scan and UART data reception issue</title><link>https://test-devzone.nordicsemi.com/thread/368102?ContentTypeID=1</link><pubDate>Mon, 16 May 2022 15:52:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3efea231-79d6-4768-bf3c-482504a21f11</guid><dc:creator>user72692</dc:creator><description>&lt;p&gt;Hello Kenny,&lt;/p&gt;
&lt;p&gt;It is hard to say what may cause the issue.&lt;/p&gt;
&lt;p&gt;Could you enable logging to see if you get some more information about the fault? Assert? Hard fault? Error?&lt;/p&gt;
&lt;p&gt;I can see that you have shared a lot of files, but would you be able to share a minimal project, including main.c that reproduces the issue, and provide some detailed steps how to reproduce it? That would make it much easier to debug on my side.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>