<?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>UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/117206/uart1-and-uart0-on-nrf52833</link><description>I am currently using SDK 17.1.0 to implement dual UART mode on the nRF52833. UART0 is used for logging, and it directly utilizes the SDK library without any modifications. Additionally, I created an app_uart1_fifo.c file based on the app_uart_fifo.c file</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 03 Jan 2025 13:54:08 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/117206/uart1-and-uart0-on-nrf52833" /><item><title>RE: UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/thread/516823?ContentTypeID=1</link><pubDate>Fri, 03 Jan 2025 13:54:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d52256e2-145e-4a48-b73e-b87bcb6cba74</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Sorry for the late reply. I have been out of office. I am sorry for the inconvenience.&lt;/p&gt;
&lt;p&gt;Can you please try to capture a logic trace of the UART pins using a logic analyzer? If you have a saleae, you can save the trace and upload it here. Please specify what channels that are capturing the different pins.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/thread/516248?ContentTypeID=1</link><pubDate>Wed, 25 Dec 2024 08:26:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2b9acaeb-f8f6-49e1-aa30-e9f2a9e7d935</guid><dc:creator>Taylor</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;uart1_init(AFD_UART_RX_PIN, AFD_UART_TX_PIN, 0x0EBEE000UL);//0x0EBED000UL NRF_UART_BAUDRATE_921600 NRF_UART_BAUDRATE_1000000

bool uart1_init(uint8_t rx_pin, uint8_t tx_pin, uint32_t baud_rate)
{
    uint32_t	errCode;
	if (NRF_UARTE1-&amp;gt;ENABLE == (UARTE_ENABLE_ENABLE_Enabled &amp;lt;&amp;lt; UARTE_ENABLE_ENABLE_Pos))
	{
    	;
	}else
	{
		app_uart1_comm_params_t const comm_paramsa1 =
		{
			.rx_pin_no    = rx_pin,
			.tx_pin_no    = tx_pin,
			.rts_pin_no   = NULL,
			.cts_pin_no   = NULL,
			.flow_control = APP_UART1_FLOW_CONTROL_DISABLED,
			.use_parity   = false,
			.baud_rate    = baud_rate,
		};
		APP_UART1_FIFO_INIT(&amp;amp;comm_paramsa1,
							UART_RX_BUF_SIZE,
							UART_TX_BUF_SIZE,
							uart1_event_handle,
							APP_IRQ_PRIORITY_LOWEST,
							errCode);					
		APP_ERROR_CHECK(errCode);
		NRF_LOG_INFO(&amp;quot;Uart1 open.&amp;quot;);
	}

	return true;
}&lt;/pre&gt;Thank you for your reply. I tried changing these configurations, but the data loss issue is still quite severe.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/thread/516247?ContentTypeID=1</link><pubDate>Wed, 25 Dec 2024 08:24:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ddd5c1c7-87e1-4f22-9d0d-c58c44e99b10</guid><dc:creator>Taylor</dc:creator><description>[quote userid="26071" url="~/f/nordic-q-a/117206/uart1-and-uart0-on-nrf52833/514547"]If it is not an option to change the baudrate, make sure that you enable the HFXTAL. You can test in a simple application by using:[/quote]
&lt;p&gt;I&amp;#39;m sorry for the late reply. I added this code before initializing the UART, but it caused a reset. I believe it triggered an error handling routine.I also adjusted the baud rate of both the transmitter and the nRF52833 to 1M, but data loss still occurs.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/thread/514612?ContentTypeID=1</link><pubDate>Wed, 11 Dec 2024 20:36:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:97716f88-ccb2-4ff8-ad8a-861663bb2382</guid><dc:creator>hmolesworth</dc:creator><description>&lt;p&gt;Following on from&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/edvin-holmseth"&gt;edvin&amp;#39;s&lt;/a&gt; comments, maybe try this value (0x0EBEE000) to see if it helps; this is from nRF52832 and nRF52840, but should be the same on nRF52833:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;//  --------Calculated-------------------  ---------------Documentation---------------
//  Required Register      Actual   Error  Register    Required   Actual  Error   Ok?
//  ======== =========== ======== =======  =========== ======== ======== =======  ====
//     1200, 0x0004F000,    1205, +0.416%  0x0004F000,    1200,    1205, +0.416%,   -,
//     2400, 0x0009D000,    2395, -0.208%  0x0009D000,    2400,    2396, -0.166%,   -,
//     4800, 0x0013B000,    4806, +0.125%  0x0013B000,    4800,    4808, +0.166%,   -,
//     9600, 0x00275000,    9597, -0.031%  0x00275000,    9600,    9598, -0.020%,   -,
//    14400, 0x003B0000,   14404, +0.027%  0x003AF000,   14400,   14401, +0.006%,  No,
//    19200, 0x004EA000,   19195, -0.026%  0x004EA000,   19200,   19208, +0.041%,   -,
//    28800, 0x0075F000,   28793, -0.024%  0x0075C000,   28800,   28777, -0.079%,  No,
//    38400, 0x009D5000,   38406, +0.015%  0x009D0000,   38400,   38369, -0.080%,  No,
//    57600, 0x00EBF000,   57601, +0.001%  0x00EB0000,   57600,   57554, -0.079%,  No,
//    76800, 0x013A9000,   76797, -0.003%  0x013A9000,   76800,   76923, +0.160%,   -,
//   115200, 0x01D7E000,  115203, +0.002%  0x01D60000,  115200,  115108, -0.079%,  No,
//   230400, 0x03AFC000,  230407, +0.003%  0x03B00000,  230400,  231884, +0.644%,  No,
//   250000, 0x04000000,  250000,       -  0x04000000,  250000,  250000, +0.000%,   -,
//   460800, 0x075F7000,  460800, +0.000%  0x07400000,  460800,  457143, -0.793%,  No,
//   921600, 0x0EBEE000,  921600, +0.000%  0x0F000000,  921600,  941176, +2.124%,  No,&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;The documentation was updated for nRF52832 (almost correctly), but it seems not for the nRF52840 and&amp;nbsp; nRF52833.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UART1 and UART0 on nRF52833</title><link>https://devzone.nordicsemi.com/thread/514547?ContentTypeID=1</link><pubDate>Wed, 11 Dec 2024 14:20:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:656b9eae-a3ac-42a8-bb06-d9c48edc1b73</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Is it a possibility to use a different baudrate? The reason I ask is that some baudrates are more off than others. Looking at the specification for the nRF52833&amp;#39;s UART registers:&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1733926628757v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;(&lt;a href="https://docs.nordicsemi.com/bundle/ps_nrf52833/page/uarte.html#ariaid-title37"&gt;Source&lt;/a&gt;)&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So this is one of the baudrates with the largest difference from the target baudrate. if you can use e.g. 1M baudrate, it will be much closer to the target baudrate.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;If it is not an option to change the baudrate, make sure that you enable the HFXTAL. You can test in a simple application by using:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;NRF_CLOCK-&amp;gt;TASKS_HFCLKSTART=1;
while (NRF_CLOCK-&amp;gt;EVENTS_HFCLKSTARTED == 0)
{
    // Wait...
}
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;before starting the UART. But if your application is using some drivers that are requesting the clock in a proper way (such as BLE), then it will also release the clock properly, turning off the HFCLK. But using this snippet in a very simple application will make it possible to check if always using the HFXTAL will make the precision &amp;quot;good enough&amp;quot;.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>