<?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>Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/18426/custom-baud-rate-with-uart</link><description>Hi, 
 I am trying to run a MIDI slave chip with the nRF51822 which requires me to use the MIDI standard baud rate of 31250. Is it possible to use nrf_drv_uart with a custom baud rate such as this? 
 Thanks</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 20 Dec 2016 15:58:41 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/18426/custom-baud-rate-with-uart" /><item><title>RE: Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/thread/71104?ContentTypeID=1</link><pubDate>Tue, 20 Dec 2016 15:58:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6d19e3e7-56e9-4242-aaf7-4aec7433396b</guid><dc:creator>RPDben</dc:creator><description>&lt;p&gt;Works perfectly, thanks!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/thread/71103?ContentTypeID=1</link><pubDate>Thu, 15 Dec 2016 14:58:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dfb6bad8-44bc-442c-9917-fd2cafccd2cc</guid><dc:creator>RPDben</dc:creator><description>&lt;p&gt;I&amp;#39;ll give it a go now!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/thread/71102?ContentTypeID=1</link><pubDate>Thu, 15 Dec 2016 14:42:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a492b7bd-9f60-4b2e-ad59-9a84d06364b1</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;Yes, that will work, just add the define.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/thread/71101?ContentTypeID=1</link><pubDate>Thu, 15 Dec 2016 14:41:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:12940c2c-7e6c-4a91-b124-e32240936356</guid><dc:creator>RPDben</dc:creator><description>&lt;p&gt;I forgot to mention, I am on sdk10.0.0. It doesn&amp;#39;t seem to be in there for that sdk. Will it work if I manually add that define in?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom Baud rate with UART</title><link>https://devzone.nordicsemi.com/thread/71100?ContentTypeID=1</link><pubDate>Thu, 15 Dec 2016 14:39:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:940db4c9-7ab1-4fa9-af05-ee0f9421712f</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Yes, that is possible. It&amp;#39;s already defined in &lt;code&gt;nrf51_bitfields.h&lt;/code&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#define UART_BAUDRATE_BAUDRATE_Baud31250 (0x00800000UL) /*!&amp;lt; 31250 baud. */
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If you want to do other custom baudrates that is not defined in nrf5x_bitfields.h, take a look at &lt;a href="https://devzone.nordicsemi.com/question/1181/uart-baudrate-register-values/"&gt;this post&lt;/a&gt; for how to calculate the value of the baudrate register.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>