<?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>nRF9160 change UART port at runtime</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/54181/nrf9160-change-uart-port-at-runtime</link><description>Hi, 
 I am using ncs 1.0.0 and Modem FW version 1.0.1. 
 I am using UART 2 and i have kept UART TX and RX port 0.11 and 0.10 in overlay file. 
 I want to change the port pins at run time to 6 and 5. 
 Is it possible to do that ? 
 
 Regards, 
 Smitesh</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 08 Nov 2019 14:35:35 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/54181/nrf9160-change-uart-port-at-runtime" /><item><title>RE: nRF9160 change UART port at runtime</title><link>https://devzone.nordicsemi.com/thread/219314?ContentTypeID=1</link><pubDate>Fri, 08 Nov 2019 14:35:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:233ebc1c-09a2-40de-9794-6e99ee90c2fe</guid><dc:creator>Martin Lesund</dc:creator><description>&lt;p&gt;Hi Smitesh,&lt;/p&gt;
&lt;p&gt;Can disable the &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf9160%2Fuarte.html&amp;amp;cp=2_0_0_5_18_7&amp;amp;anchor=concept_wmv_f2m_wr" rel="noopener noreferrer" target="_blank"&gt;UART in runtime and then change the pins and then enable the UART peripheral again &lt;/a&gt;with the help of setting the&lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf9160%2Fuarte.html&amp;amp;cp=2_0_0_5_18_8_39&amp;amp;anchor=register.PSEL.TXD"&gt; registers found in the documentation.&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;example:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/Rallare/fw-nrfconnect-nrf/blob/nrf9160_samples/samples/nrf9160/udp_with_psm/src/main.c#L211" rel="noopener noreferrer" target="_blank"&gt;Here is a snippet on how you can stop the UART RX&amp;nbsp;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf9160%2Fuarte.html&amp;amp;cp=2_0_0_5_18_8_1&amp;amp;anchor=register.TASKS_STOPRX" rel="noopener noreferrer" target="_blank"&gt;the register&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>