<?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>LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/72372/lp-uart-sample-crashes-continuously</link><description>Setup - 
 
 nRF52840-DK 
 Nordic Connect SDK version 1.5.0 
 Sample - nrf/samples/peripheral/lpuart 
 Commented out &amp;quot;uart0&amp;quot; in the board specific overlay 
 Uncommented console logging from &amp;quot;prj.conf&amp;quot; 
 Commented &amp;quot;CONFIG_CONSOLE=n&amp;quot; and &amp;quot;CONFIG_UART_CONSOLE</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 06 May 2021 13:55:04 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/72372/lp-uart-sample-crashes-continuously" /><item><title>RE: LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/thread/308572?ContentTypeID=1</link><pubDate>Thu, 06 May 2021 13:55:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:494fcb34-3f92-4005-b616-b1632f72792d</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;Please create a new DevZone ticket&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/thread/308553?ContentTypeID=1</link><pubDate>Thu, 06 May 2021 12:46:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43b63faa-6d42-4ff1-a10a-1cffa91c3d60</guid><dc:creator>Hamada888</dc:creator><description>&lt;p&gt;hei&lt;br /&gt;Can you help me to make the UART transmitioin goes only once?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/thread/302358?ContentTypeID=1</link><pubDate>Mon, 29 Mar 2021 12:12:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0c189aca-c61f-4217-af27-d8bd5b93edd1</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I was able to make&amp;nbsp;&lt;span&gt;&amp;quot;interrupt driven&amp;quot; mode&lt;/span&gt;&amp;nbsp;work using NCS v1.5.0 and nrf52840dk_nrf52840 and the following changes:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;diff --git a/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay b/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
index 54d3d0bc1..266936e12 100644
--- a/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
+++ b/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
@@ -15,6 +15,6 @@
        };
 };

-&amp;amp;uart0 {
+/*&amp;amp;uart0 {
        status = &amp;quot;disabled&amp;quot;;
-};
+};*/
diff --git a/samples/peripheral/lpuart/diffs.patch b/samples/peripheral/lpuart/diffs.patch
new file mode 100644
index 000000000..e69de29bb
diff --git a/samples/peripheral/lpuart/prj.conf b/samples/peripheral/lpuart/prj.conf
index ba5f898e0..4f1e856dd 100644
--- a/samples/peripheral/lpuart/prj.conf
+++ b/samples/peripheral/lpuart/prj.conf
@@ -11,13 +11,13 @@ CONFIG_NRF_SW_LPUART=y
 # in overlay.

 # CONFIG_USE_SEGGER_RTT=n
-# CONFIG_LOG=y
+CONFIG_LOG=y
 # CONFIG_NO_OPTIMIZATIONS=y
 # CONFIG_ASSERT=y

 # Comment this section for debugging
-CONFIG_CONSOLE=n
-CONFIG_UART_CONSOLE=n
+#CONFIG_CONSOLE=n
+#CONFIG_UART_CONSOLE=n

 # Uncomment to use lpuart using interrupt driven API
-# CONFIG_NRF_SW_LPUART_INT_DRIVEN=y
+CONFIG_NRF_SW_LPUART_INT_DRIVEN=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I then got the following output in Termite:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;*** Booting Zephyr OS build v2.4.99-ncs1  ***
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes
read 1 bytes
read 5 bytes&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Could you test this on your end and see if you&amp;#39;re able to make it work?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/thread/301236?ContentTypeID=1</link><pubDate>Mon, 22 Mar 2021 14:02:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c4fb1dcb-145d-4973-9d30-762a40be2be8</guid><dc:creator>Anirudh Agarkhed</dc:creator><description>&lt;p&gt;That config seems to work fine, when I apply the patches - &lt;a href="https://github.com/nrfconnect/sdk-nrf/pull/3972"&gt;Patch 1&lt;/a&gt; and &lt;a href="https://github.com/nrfconnect/sdk-nrf/pull/4020"&gt;Patch 2&lt;/a&gt;. Changing the prj.conf by itself does not make this work.&lt;/p&gt;
&lt;p&gt;With the patch applied, LP-UART works when &amp;quot;async&amp;quot; mode is used.&lt;/p&gt;
&lt;p&gt;When configuration is changed to &amp;quot;Interrupt Driven&amp;quot; mode, MPU fault is observed. Following configuration changes were made -&lt;/p&gt;
&lt;p&gt;In prj.conf enabled - CONFIG_NRF_SW_LPUART_INT_DRIVEN=y&lt;/p&gt;
&lt;p&gt;In board specific config -&lt;/p&gt;
&lt;p&gt;CONFIG_UART_1_ASYNC=n&lt;br /&gt;CONFIG_UART_1_INTERRUPT_DRIVEN=y&lt;/p&gt;
&lt;p&gt;Changing these configurations results in continuous crash due to &amp;quot;MPU Fault - Data Access Violation&amp;quot;&lt;/p&gt;
&lt;p&gt;Which configurations are to be modified to change to &amp;quot;interrupt driven&amp;quot; mode?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: LP-UART sample crashes continuously</title><link>https://devzone.nordicsemi.com/thread/298369?ContentTypeID=1</link><pubDate>Mon, 08 Mar 2021 12:49:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:08d8d13a-b167-4602-a5db-f18d7853d2b0</guid><dc:creator>Simon</dc:creator><description>&lt;p&gt;I was not able to reproduce the MPU fault. Can you test with the same changes I did:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="diff"&gt;diff --git a/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay b/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
index 54d3d0bc1..d3ad94ce1 100644
--- a/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
+++ b/samples/peripheral/lpuart/boards/nrf52840dk_nrf52840.overlay
@@ -1,8 +1,8 @@
 /* SPDX-License-Identifier: LicenseRef-Nordic-5-Clause */

 &amp;amp;uart1 {
-       rx-pin = &amp;lt;44&amp;gt;;
-       tx-pin = &amp;lt;45&amp;gt;;
+       rx-pin = &amp;lt;44&amp;gt;; // 12
+       tx-pin = &amp;lt;45&amp;gt;; // 13
        /delete-property/ rts-pin;
        /delete-property/ cts-pin;

@@ -10,11 +10,11 @@
                compatible = &amp;quot;nordic,nrf-sw-lpuart&amp;quot;;
                status = &amp;quot;okay&amp;quot;;
                label = &amp;quot;LPUART&amp;quot;;
-               req-pin = &amp;lt;46&amp;gt;;
-               rdy-pin = &amp;lt;47&amp;gt;;
+               req-pin = &amp;lt;46&amp;gt;; // 14
+               rdy-pin = &amp;lt;47&amp;gt;; // 15
        };
 };

-&amp;amp;uart0 {
+/*&amp;amp;uart0 {
        status = &amp;quot;disabled&amp;quot;;
-};
+};*/
diff --git a/samples/peripheral/lpuart/prj.conf b/samples/peripheral/lpuart/prj.conf
index ba5f898e0..6c0eaf00c 100644
--- a/samples/peripheral/lpuart/prj.conf
+++ b/samples/peripheral/lpuart/prj.conf
@@ -11,13 +11,13 @@ CONFIG_NRF_SW_LPUART=y
 # in overlay.

 # CONFIG_USE_SEGGER_RTT=n
-# CONFIG_LOG=y
+CONFIG_LOG=y
 # CONFIG_NO_OPTIMIZATIONS=y
 # CONFIG_ASSERT=y

 # Comment this section for debugging
-CONFIG_CONSOLE=n
-CONFIG_UART_CONSOLE=n
+#CONFIG_CONSOLE=n
+#CONFIG_UART_CONSOLE=n

 # Uncomment to use lpuart using interrupt driven API
 # CONFIG_NRF_SW_LPUART_INT_DRIVEN=y&lt;/pre&gt;&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>