<?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>STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/36866/stoprx-task-of-uarte-during-reception-of-bytes</link><description>Hi all 
 Previously, I used the nRF52832 with the interrupt-driven UART at 1Mbaud. But due to SoftDevice interrupts that blocked the UART-RX-IRQ for more than 6 bytes, I tried to use the UARTE with EasyDMA. 
 I need to receive an arbitrary amount of bytes</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 23 Aug 2018 05:39:40 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/36866/stoprx-task-of-uarte-during-reception-of-bytes" /><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/145398?ContentTypeID=1</link><pubDate>Thu, 23 Aug 2018 05:39:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3cda1254-a46f-4b1e-a4e1-0506dd04698b</guid><dc:creator>Remo</dc:creator><description>&lt;p&gt;Thank you very much for your answer.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/145305?ContentTypeID=1</link><pubDate>Wed, 22 Aug 2018 12:04:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8596b936-6fe6-48da-a6fe-9366c600b824</guid><dc:creator>MartinBL</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;As my colleague run_ar says in that thread,&amp;nbsp;there is no exact answer to that&amp;nbsp;because it depends on whether or not other, higher priority, peripherals are using the same DMA channel. However, the system architect says it will occur &amp;quot;within spec&amp;quot;. That is, data should be moved out of the FIFO before the next data arrives, so moving one byte should take less time than it takes to receive one byte at whatever baud rate you are using.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/145207?ContentTypeID=1</link><pubDate>Wed, 22 Aug 2018 05:24:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:37d5934e-3b20-4d6e-bd15-ad5ca63f93c0</guid><dc:creator>Remo</dc:creator><description>&lt;p&gt;Thank you for the clarification. &lt;/p&gt;
&lt;p&gt;Is it possible that you can make a generous statement about the maximum duration that is necessary to put a byte from the FIFO to the RAM via EasyDMA?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/144593?ContentTypeID=1</link><pubDate>Thu, 16 Aug 2018 16:16:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8d56ec6d-5c61-47fc-aef1-092e1d4f026a</guid><dc:creator>MartinBL</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Yes, you are right. If you are only going to check the amounts of received bytes at ENDRX events you may just as well check RXD.AMOUNT rather than using a counter.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The libUARTE library is still in experimental mode, meaning it is still a work in progress (or at least it&amp;#39;s not finished). I have asked around and it seems like libUARTE is put on hold for the time being. I imagine that there is/was a thought behind the counter, but it just hasn&amp;#39;t been put to full use yet.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/142123?ContentTypeID=1</link><pubDate>Tue, 31 Jul 2018 09:50:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d907d29b-72bb-498c-a400-cc11a4a20276</guid><dc:creator>Remo</dc:creator><description>&lt;p&gt;Thanks for your answer. I assumed that due to the shortcut, the reception would seamless continue in the second RX buffer. Seems that I was wrong. The solution with the PPI channel and the counter sounds promising.&lt;/p&gt;
&lt;p&gt;But I don&amp;#39;t quite understand why in the&amp;nbsp;nrf_libuarte.c the capture value of the timer is only retrieved when the ENDRX event occurred. Wouldn&amp;#39;t it be easier in this case to check the AMOUNTRX value? Is that correct that the capture value could also be retrieved when the reception is ongoing?&lt;/p&gt;
&lt;p&gt;In the thread that you&amp;#39;ve linked they are talking about the number of clock cycles it takes for a received byte to be written from the FIFO to the buffer. I didn&amp;#39;t find this information in the product specification. Is there a maximum time that you can state?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: STOPRX task of UARTE during reception of bytes</title><link>https://devzone.nordicsemi.com/thread/142002?ContentTypeID=1</link><pubDate>Mon, 30 Jul 2018 16:38:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:64d1c92c-0b92-4feb-9277-fe50310ca68c</guid><dc:creator>MartinBL</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I have seen this method been attempted before, but unfortunately it is not possible to&amp;nbsp;start and stop the UART asynchronously like this without concern for the incoming data stream. When you randomly start and stop the UART midstream like this, you will stop the logic, reset DMA channels, etc. at random times and you are bound to lose some bytes.&lt;/p&gt;
&lt;p&gt;In SDK 15 we have what we call the&amp;nbsp;&lt;a title="Command Line Interface library" href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.0.0/lib_cli.html?cp=4_0_0_3_10"&gt;Command Line Interface library&lt;/a&gt;&amp;nbsp;where one of the available transport layers are the UARTE. If you look in the source code for that (&amp;quot;SDK_folder\components\libraries\experimental_libuarte\nrf_libuarte.c&amp;quot;) you can see how the SDK team has chosen to implement something similar. They don&amp;#39;t start and stop the UART like this, but use PPI and a counter to keep track of how many bytes are available in the buffer. Maybe you can try something similar.&lt;/p&gt;
&lt;p&gt;Here is a relevant thread:&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/28420/uarte-in-circular-mode"&gt;https://devzone.nordicsemi.com/f/nordic-q-a/28420/uarte-in-circular-mode&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>