<?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>nrf52 UART pins</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/12392/nrf52-uart-pins</link><description>Hi,
I am trying to figure out which GPIO pins i can use as UART on a nrf52 chip if i put it on a custom PCB (Not DK !!). From the reference manual (page 513, 48.10.7 and 48.10.9) it looks to me as if any (0 to 31) GPIO pin can be used as UART (as long</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 07 Mar 2016 21:31:31 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/12392/nrf52-uart-pins" /><item><title>RE: nrf52 UART pins</title><link>https://devzone.nordicsemi.com/thread/46846?ContentTypeID=1</link><pubDate>Mon, 07 Mar 2016 21:31:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a44b6d58-5721-4e5c-b125-8cd887f81c0b</guid><dc:creator>Nikolaus Wittenstein</dc:creator><description>&lt;p&gt;You&amp;#39;re correct, you can use any pin for UART. Here&amp;#39;s a screenshot so we can talk about it:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/Screen-Shot-2016_2D00_03_2D00_07-at-16.25.15.png" alt="image description" /&gt;&lt;/p&gt;
&lt;p&gt;The id &amp;quot;A&amp;quot; in the leftmost column corresponds to the A below each bit number. If you look at the ENABLE register, only the lowest four bits have an A below them. What that&amp;#39;s saying is that the ENABLE field in that register is only the lowest four bits. The other bits have no letter, and are thus opaque to you. They may be used for something internally and just undocumented, so it&amp;#39;s good practice to not write to them.&lt;/p&gt;
&lt;p&gt;The PSELRTS field takes up the entire 32-bit register, as shown by an A underneath every bit. However, most of these bits will always be 0. You can see that valid values for the PSELRTS field are [0..31] (i.e., 0 through 31) and &lt;code&gt;0xFFFFFFFF&lt;/code&gt;. Any of the following lines would be valid:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;p_reg-&amp;gt;PSELRTS = 4; // set to pin four
p_reg-&amp;gt;PSELRTS = 31; // set to pin thirty-one
p_reg-&amp;gt;PSELRTS = 0xFFFFFFFF; // disable
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If you write an invalid value (for example, &lt;code&gt;0xFFFFFFFE&lt;/code&gt;), then the behavior is undocumented and perhaps undefined.&lt;/p&gt;
&lt;p&gt;The rest of the stuff in the table: RW means readable and writeable, and Reset 0x00000000 tells you the default value when you reset the chip.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>