<?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>Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73197/zigbee-and-serial-communication-issue</link><description>Hello Nordic! 
 I have been developing a Zigbee application and now, I need to connect via Serial communication with another device. I just need to listen to the port, not send any data. Unfortunately I don&amp;#39;t have that device so I am simulating it with</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 07 Jul 2021 14:52:48 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73197/zigbee-and-serial-communication-issue" /><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/319019?ContentTypeID=1</link><pubDate>Wed, 07 Jul 2021 14:52:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:28652106-4e67-4cbb-9b58-e0e07c323d00</guid><dc:creator>Marjeris Romero</dc:creator><description>&lt;p&gt;Hi Alejandro,&lt;/p&gt;
&lt;p&gt;I have taken over this case from Susheel. I don&amp;#39;t think you should delete the ZBOSS libraries provided. Could it be that you are having problems adding a new UART instance since the Zigbee examples also use UART for nrf log output?&lt;/p&gt;
&lt;p&gt;Have you tried changing APP_UART_DRIVER_INSTANCE to 1 in sdk_config.h and set UART1_ENABLED?&lt;/p&gt;
&lt;p&gt;nRF logging module in the examples will use UART0 as default.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Marjeris&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/315765?ContentTypeID=1</link><pubDate>Thu, 17 Jun 2021 07:39:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d8a0bed4-e278-4a7a-8a0a-61ae75866a53</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello again!&lt;/p&gt;
&lt;p&gt;I have been experiencing some problems with Serial and Zigbee communication. The previous solution I found about &amp;quot;libzboss.a&amp;quot; library is not suitable, that library is not used on Zigbee End Devices (I need to use libzboss.ed.a) so when I try to reconnect to my Coordinator it connects as a device with GreenPower cluster only (when I don&amp;#39;t use it).&lt;/p&gt;
&lt;p&gt;Please, I need to fix this issue as soon as possible, it&amp;#39;s been 3 months since the beginning of the question and I still have the UART working.&lt;/p&gt;
&lt;p&gt;Regards.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/313463?ContentTypeID=1</link><pubDate>Thu, 03 Jun 2021 14:16:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:67f198ef-722a-4851-8191-5b5e42d225eb</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Susheel!&lt;/p&gt;
&lt;p&gt;I have continued and realised the cause of the error. I am posting the info in case someone else has the same problem in the future.&lt;/p&gt;
&lt;p&gt;After a week of debugging, I find out that the library &amp;quot;libzboss.ed.a&amp;quot;&amp;nbsp;located in &amp;quot;external/zboss/lib/gcc/&amp;quot; was&amp;nbsp;causing the code to fail. If I use the &amp;quot;libzboss.a&amp;quot; library instead of the &amp;quot;libzboss.ed.a&amp;quot; (note the difference between .ed.a and&amp;nbsp;just .a) it works like a charm.&lt;/p&gt;
&lt;p&gt;In fact, as Susheel told me, there is no incompatibilities between Zigbee and UART. And I simply changed that library and everything started working. There is also one little thing to modify, and that is to remove the &amp;quot;ZB_ED_ROLE&amp;quot; from the Preprocessor definitions, but if you don&amp;#39;t do that, Segger (or whatever you use) will throw an error.&lt;/p&gt;
&lt;p&gt;To close the thread, I just want to know why was happening this error. I would appreciate it if someone could explain a bit more about why this problem is occurring.&lt;/p&gt;
&lt;p&gt;Cheers!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/310697?ContentTypeID=1</link><pubDate>Thu, 20 May 2021 10:39:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b9b8a9cc-6420-491e-8af5-6c9035700898</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Susheel!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote userid="6207" url="~/f/nordic-q-a/73197/zigbee-and-serial-communication-issue/310050#310050"]There is also a BLE UART/Zigbee doorlock, that uses uart gor logging.[/quote]
&lt;p&gt;I think the example you said is the same&amp;nbsp;example I am using as a guide for my project. In fact, what I am trying to make is a Zigbee doorlock but with a lot of features. That example uses NUS for sending data over BLE,&amp;nbsp;could&amp;nbsp;that be&amp;nbsp;my problem?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;I&amp;#39;ve been trying unsuccesfully to add uart communication to the template you mention but I am not able to do it. I am using the same code that is working in my&amp;nbsp;current board (with BLE and Zigbee deactivated)&amp;nbsp;but it refuses to work. Below I show yo the code I am using (it is written in spanish, sorry):&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;void uart_event_handle(app_uart_evt_t * p_event)
{
    static uint8_t buffer[LONGITUD_MAX_MENSAJE];
    static uint8_t index = 0;
    uint32_t err_code;

    switch (p_event-&amp;gt;evt_type)
    {
        case APP_UART_COMMUNICATION_ERROR:
            APP_ERROR_HANDLER(p_event-&amp;gt;data.error_communication);
            break;

        case APP_UART_FIFO_ERROR:
            //APP_ERROR_HANDLER(p_event-&amp;gt;data.error_code);
            break;

        case APP_UART_DATA:
            UNUSED_VARIABLE(app_uart_get(&amp;amp;buffer[index]));
            if ((buffer[index] == 0x0a) || (buffer[index] == 0x0d) || index &amp;gt;= LONGITUD_MAX_MENSAJE)
            {
                // Do something
                index = 0;
            }
            else
            {
                index++;
            }
            break;

        default:
            break;
    }
}


static void uart_init(void)
{
    uint32_t err_code;
    app_uart_comm_params_t const comm_params =
    {
        .rx_pin_no    = RX_PIN,
        .tx_pin_no    = TX_PIN,
        .rts_pin_no   = RTS_PIN,
        .cts_pin_no   = CTS_PIN,
        .flow_control = FLOW_CONTROL,
        .use_parity   = USE_PARITY,
        .baud_rate    = BAUDRATE
    };

    APP_UART_INIT(&amp;amp;comm_params,
                  uart_event_handle,
                  APP_IRQ_PRIORITY_HIGH,
                  err_code);

    APP_ERROR_CHECK(err_code);
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I also modified the sdk_config file to&amp;nbsp;define&amp;nbsp;UART_ENABLED to 1 and used the&amp;nbsp;APP_UART_DRIVER_INSTANCE 0, the sdk_donfig file is pretty similar to mine. But I don&amp;#39;t discard that the error may be in that file.&lt;/p&gt;
&lt;p&gt;Cheers!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;EDIT: I realised that the problem was having both the log and the uart, so I commented out the initialisation function for the log and everything seems to work. I have yet to test the full functionality, but it looks promising.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/310050?ContentTypeID=1</link><pubDate>Tue, 18 May 2021 08:35:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8ee4e1fa-bcbd-423a-9ba9-73c2fd244245</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;I am now talked to the Zigbee developer in support and she says that she does not see any reason that UART will have any compatibility issues when used with BLE and Zigbee. There is also a BLE UART/Zigbee doorlock, that uses uart gor logging.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;there is also a template you should follow if you wants to run both BLE and Zigbee, adding UART peripheral to this example and then the rest of his application will be much easier for you than&amp;nbsp;adding BLE to an existing Zigbee project:&lt;/div&gt;
&lt;div&gt;&lt;a title="https://infocenter.nordicsemi.com/topic/sdk_tz_v4.1.0/zigbee_multi_dynamic_template_example.html" href="https://infocenter.nordicsemi.com/topic/sdk_tz_v4.1.0/zigbee_multi_dynamic_template_example.html" rel="noopener noreferrer" target="_blank"&gt;https://infocenter.nordicsemi.com/topic/sdk_tz_v4.1.0/zigbee_multi_dynamic_template_example.html&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/309694?ContentTypeID=1</link><pubDate>Fri, 14 May 2021 05:24:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c4377188-f8ba-4b15-bfc3-09ab32485264</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;I have asked the Zigbee expert to shed some light on the BLE, Zigbee and UART compatibility. She is on holiday today but will respond most likely on Tuesday as Monday is also holiday (Norwegian National Day)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/309409?ContentTypeID=1</link><pubDate>Wed, 12 May 2021 08:43:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a06f75a4-aece-49b8-bec4-097f09baed4e</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Susheel,&lt;/p&gt;
&lt;p&gt;Right now I am working in different features of the code so I couldn&amp;#39;t try what you said. As soon as possible, I will try what you told me.&lt;/p&gt;
&lt;p&gt;Meanwhile, the question I was referring was the following&lt;/p&gt;
[quote userid="95765" url="~/f/nordic-q-a/73197/zigbee-and-serial-communication-issue/307282#307282"]&lt;p&gt;I have tried to follow the path why BLE and UART are not compatible and I have found that they can be compatible, but once some time has passed, the UART communication ends and BLE and Zigbee start working as usual.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/308644?ContentTypeID=1</link><pubDate>Fri, 07 May 2021 07:05:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ceb10bdd-af49-4656-98d4-fd9fb743dd1f</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="mazis"]From what I read, the problem is that I am not reading the registers fast enough, right? I am not using the FIFO rergister, I don&amp;#39;t know if that is relevant. Anyway, I will try to&amp;nbsp;fix it as soon as possible. What do you think is the best approach to solve the issue?[/quote]
&lt;p&gt;&amp;nbsp;Use flow control if possible (change NRF_UARTE_HWFC_DISABLED to NRF_UARTE_HWFC_ENABLED)&lt;/p&gt;
&lt;p&gt;Also try with application uart priority&amp;nbsp;APP_IRQ_PRIORITY_HIGH instead of&amp;nbsp;APP_IRQ_PRIORITY_LOW.&lt;/p&gt;
&lt;p&gt;I think that you are doing a lot of uart post processing, which is causing the hardware FIFO to overflow causing overrun errors. Enabling hardware flow control will greatly reduce the chance of this overrun error.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]What do you mean? Modify the SDK API error_handler function? Would you mind elaborate on this a bit more?&amp;nbsp;I find it pretty interesting to me.[/quote]
&lt;p&gt;&amp;nbsp;No need to change any SDK API, what I mean to say is that when you get any errors and your application is notified using&amp;nbsp;NRF_DRV_UART_EVT_ERROR, then you need to handle it properly. Sometimes you might have to read an extra char from the FIFO to restart the state machine of the underlying driver. Please look at other examples in the SDK that handle this&amp;nbsp;NRF_DRV_UART_EVT_ERROR event.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]Furthermore, did you see the last comment I posted? The one below me about the issue with Zigbee and BLE.[/quote]
&lt;p&gt;Not really, that is strange, can you repost the question about Zigbee and BLE? I do not find your specific question regarding the issue with this combo.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/308592?ContentTypeID=1</link><pubDate>Thu, 06 May 2021 15:06:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b4e4b35e-4e50-4e3b-893f-30de105b9c2f</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Susheel!&lt;/p&gt;
&lt;p&gt;From what I read, the problem is that I am not reading the registers fast enough, right? I am not using the FIFO rergister, I don&amp;#39;t know if that is relevant. Anyway, I will try to&amp;nbsp;fix it as soon as possible. What do you think is the best approach to solve the issue?&lt;/p&gt;
[quote userid="6207" url="~/f/nordic-q-a/73197/zigbee-and-serial-communication-issue/308505#308505"]It is good idea that you handle this errors manually but I recommend you to do it inside the error_handler to make it architecturally same as before.[/quote]
&lt;p&gt;What do you mean? Modify the SDK API error_handler function? Would you mind elaborate on this a bit more?&amp;nbsp;I find it pretty interesting to me.&lt;/p&gt;
&lt;p&gt;Furthermore, did you see the last comment I posted? The one below me about the issue with Zigbee and BLE.&lt;/p&gt;
&lt;p&gt;Cheers!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/308505?ContentTypeID=1</link><pubDate>Thu, 06 May 2021 10:22:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f148c786-b9d0-417e-80f0-7e50e8b0a6ec</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Hi Alejandro,&lt;/p&gt;
&lt;p&gt;Edvin is on leave so I am taking over this thread and will try to assist you. I am not an expert in Zigbee, but I have good understanding on the UART related issues which hopefully will be useful in this case.&lt;/p&gt;
[quote user="mazis"]- I receive data via Serial correctly but sometimes I get some communication errors. The most frequent is the error code 1. What does it mean? Where can I find a table/list of the error codes and the associated explanation?[/quote]
&lt;p&gt;I think what you are seeing is somewhat similar to &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/62428/nrf52832-uart-overrun-issue-with-error-code-return-nrf_error_svc_handler_missing-from-ble_nus_data_send"&gt;this&lt;/a&gt; error. There was a bug where the communication which does not translate the internal hardware error src to library specific error. Probably you should figure out what this error was and how to handle this specific error in your case.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]- I also had to delete the APP_ERROR_HANDLER call in the APP_UART_COMMUNICATION_ERROR case in uart_event_handle() function when an error occurs because it was stopping my code. I will have to&amp;nbsp;handle the errror codes manually.&amp;nbsp;For me, there is no problem, but&amp;nbsp;for the board? Is it better to use the error_handler or the error_check than to do it manually?[/quote]
&lt;p&gt;It is good idea that you handle this errors manually but I recommend you to do it inside the error_handler to make it architecturally same as before.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]Thanks for all your help. As you said, the ble_app_uart gave me the inspiration I needed. OOnce I&amp;#39;ve cleared my doubts, I will verify the answer and finish this thread.[/quote]
&lt;p&gt;&amp;nbsp;Thanks for the kind words and again sorry for the late reply.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/307282?ContentTypeID=1</link><pubDate>Wed, 28 Apr 2021 13:45:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e5c558c1-7bb2-4ec8-8dd0-1f4a2e138aa3</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;I have continued testing and debugging and I have found something strange...&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have tried to follow the path why BLE and UART are not compatible and I have found that they can be compatible, but once some time has passed, the UART communication ends and BLE and Zigbee start working as usual.&lt;/p&gt;
&lt;p&gt;I am not able to understand why this happens....&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/307164?ContentTypeID=1</link><pubDate>Wed, 28 Apr 2021 08:23:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:447e9592-aa66-4dee-a3b3-583f37dc7061</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Edvin!&lt;/p&gt;
&lt;p&gt;I finally made it, I have the Serial communication working but I still have some doubts...&lt;/p&gt;
&lt;p&gt;- I receive data via Serial correctly but sometimes I get some communication errors. The most frequent is the error code 1. What does it mean? Where can I find a table/list of the error codes and the associated explanation?&lt;/p&gt;
&lt;p&gt;- When I set the Serial communication, the BLE stops working. I remember seeing something about RTT in my sdk_config file, is this related?. What may be causing this issue? Right now it&amp;#39;s not a&amp;nbsp;big problem but I will need to implement BLE in the future so I need to fix this.&lt;/p&gt;
&lt;p&gt;- I also had to delete the APP_ERROR_HANDLER call in the APP_UART_COMMUNICATION_ERROR case in uart_event_handle() function when an error occurs because it was stopping my code. I will have to&amp;nbsp;handle the errror codes manually.&amp;nbsp;For me, there is no problem, but&amp;nbsp;for the board? Is it better to use the error_handler or the error_check than to do it manually?&lt;/p&gt;
&lt;p&gt;Thanks for all your help. As you said, the ble_app_uart gave me the inspiration I needed. OOnce I&amp;#39;ve cleared my doubts, I will verify the answer and finish this thread.&lt;/p&gt;
&lt;p&gt;Thanks again!&lt;/p&gt;
&lt;p&gt;Cheers!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/305045?ContentTypeID=1</link><pubDate>Thu, 15 Apr 2021 10:18:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4fc4ac22-f030-45f7-963d-590454107b70</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 for the last 8 days.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Just to sort out a couple of things. If the NRF_LOG is using the UART backend, then I think you will have a hard time reading the UART, because it is occupied by the log module. But in this example, the log uses the RTT backend.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]What are the differences between the nrf_drv_uart and libuarte libraries?[/quote]
&lt;p&gt;&amp;nbsp;the libuarte is tailored for fast UART transfers. If it is not very fast, I suggest you stick to the nrf_drv_uart.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I suggest you check out the ble_app_uart example from the SDK. This doesn&amp;#39;t use Zigbee, but perhaps you can get some inspiration from the UART handler in that example.&lt;/p&gt;
&lt;p&gt;Alternatively, you can add the commands you need in the pool of CLI commands. Look at how it sets up the CLI commands. That is why I initially mentioned the CLI example.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;br /&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/303681?ContentTypeID=1</link><pubDate>Thu, 08 Apr 2021 08:47:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7f17acc0-bea8-4000-8fb3-c00209b8a90d</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Edvin!&lt;/p&gt;
&lt;p&gt;I&amp;#39;m using Segger and I&amp;#39;ve got NRF_LOG working. I am going to change all my printf functions to NRF_LOG_INFO and NRF_LOG_ERROR.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have been reading and understanding the cli_agent code but I have some doubts about it. The cli_agent uses the nrf_drv_uart libraries and macros. I just need to read the serial port and wait for a specific string to arrive. I thought about using interruptions for that, so I think I don&amp;#39;t need to implement DMA. Am I right? Do you recommend using it anyway? What are the differences between the nrf_drv_uart and libuarte libraries?&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thanks!&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Cheers!&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/302154?ContentTypeID=1</link><pubDate>Fri, 26 Mar 2021 13:57:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cc955d54-2cb6-4bfa-908b-f20a681c2f56</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;It may not be clear what this does based on the main.c file, but check the test description:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_tz_v4.1.0/zigbee_example_cli_agent.html?cp=7_3_3_8_5_1_3#zigbee_example_cli_agent_testing"&gt;https://infocenter.nordicsemi.com/topic/sdk_tz_v4.1.0/zigbee_example_cli_agent.html?cp=7_3_3_8_5_1_3#zigbee_example_cli_agent_testing&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"] I&amp;nbsp;guess it is more useful than the printf function that I am currently using.[/quote]
&lt;p&gt;&amp;nbsp;The reason I asked about this is that it will print the error information in the log.&lt;/p&gt;
&lt;p&gt;Try to run any of the examples that are already using the log, e.g. ble_app_uart (NB: You need to flash the sofdevice manually if you are not using Segger Embedded Studio). Then either open JLink RTT Viewer, or if you are using Segger Embedded Studio, then change this define in sdk_config.h from 1 to 0:&lt;/p&gt;
&lt;p&gt;#define NRF_FPRINTF_FLAG_AUTOMATIC_CR_ON_LF_ENABLED 1&lt;br /&gt;to&lt;br /&gt;#define NRF_FPRINTF_FLAG_AUTOMATIC_CR_ON_LF_ENABLED 0&lt;/p&gt;
&lt;p&gt;and click &amp;quot;build and debug&amp;quot;.&lt;/p&gt;
&lt;p&gt;Then look at how this is set up in that project, and try to do the same in your project. If you get the log up and running it is a useful tool for debugging, since the error handler will print errors in the log. Please define DEBUG in your preprocessor definitions to see extra logging information from the error handler. Let me know what IDE you are using if you don&amp;#39;t know how to add preprocessor definitions.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote user="mazis"]Anyway, I placed the printf function right under the&amp;nbsp;&lt;span&gt;NRF_LOG_DEFAULT_BACKENDS_INIT() call and it didn&amp;#39;t show in the debug terminal... What&amp;nbsp;could be causing this&amp;nbsp; issue?&lt;/span&gt;[/quote]
&lt;p&gt;I am not sure. printf doesn&amp;#39;t use the NRF_LOG.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="mazis"]EDIT: I just found out that the error code 0x0085 means that the module is already initialized. So I think I can either remove that call or remove the call to the APP_ERROR_CHECK function. Am I right? Unfortunately the code still fails in the call to NRF_LOG_DEFAULT_BACKENDS_INIT()... I will continue to investigate this issue...[/quote]
&lt;p&gt;&amp;nbsp;Perhaps you are trying to use the UART for both NRF_LOG and printf (not possible). Try to set the RTT backend in sdk_config.h. If you don&amp;#39;t know how to do it, see ble_app_uart&amp;#39;s sdk_config.h file (since it uses the RTT backend for logging by default).&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/301975?ContentTypeID=1</link><pubDate>Thu, 25 Mar 2021 15:47:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:acda0c1d-f5ec-4ce3-a944-2681ba707bab</guid><dc:creator>mazis</dc:creator><description>&lt;p&gt;Hello Edvin!&lt;/p&gt;
&lt;p&gt;Thanks for your quick reply!&lt;/p&gt;
&lt;p&gt;Could you specify a bit more what should I&amp;nbsp;look at in the cli_agent_router example? The code is too short...&lt;/p&gt;
&lt;p&gt;About the log, I haven&amp;#39;t had time to learn how to use the NRF_LOG so what I am using is the printf function to show some info via Debug Terminal (in Segger). May you link some information about how to use it? I&amp;nbsp;guess it is more useful than the printf function that I am currently using.&lt;/p&gt;
&lt;p&gt;Anyway, I placed the printf function right under the&amp;nbsp;&lt;span&gt;NRF_LOG_DEFAULT_BACKENDS_INIT() call and it didn&amp;#39;t show in the debug terminal... What&amp;nbsp;could be causing this&amp;nbsp; issue?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;What I found is that the call to&amp;nbsp;nrf_drv_clock_init() is failing, it is returning 0x85 error code. I will debug a bit more this...&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;EDIT: I just found out that the error code 0x0085 means that the module is already initialized. So I think I can either remove that call or remove the call to the APP_ERROR_CHECK function. Am I right? Unfortunately the code still fails in the call to NRF_LOG_DEFAULT_BACKENDS_INIT()... I will continue to investigate this issue...&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thanks in advance!&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Zigbee and Serial communication issue</title><link>https://devzone.nordicsemi.com/thread/301924?ContentTypeID=1</link><pubDate>Thu, 25 Mar 2021 13:37:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:173c319b-6dcc-4a9a-8d85-735315173c30</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Perhaps you can look into the Zigbee CLI example found in:&lt;/p&gt;
&lt;p&gt;SDK_for_thread_and_zigbee_v4.1.0\examples\zigbee\experimental\cli\cli_agent_router, which is an example where a lot of the zigbee api is serialized.&lt;/p&gt;
&lt;p&gt;If you want to continue on the libuarte path, did you try writing something to the log? Try adding:&lt;/p&gt;
&lt;p&gt;NRF_LOG_INFO(&amp;quot;starting application&amp;quot;); right after&amp;nbsp;NRF_LOG_DEFAULT_BACKENDS_INIT(). Do you see the log anywhere? (RTT perhaps, if you are using UART for your application).&lt;/p&gt;
&lt;p&gt;If you see the log, does the log say anything when your application isn&amp;#39;t working?&lt;/p&gt;
&lt;p&gt;BR,&lt;br /&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>