<?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>The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board</link><description>Hi I am trying to do the led blinking in nrf52840 but the led is not even turning on i have given the code below can any body help me out. 
 
 nrf_gpio_cfg_output(14); nrf_gpio_cfg_output(15); nrf_gpio_cfg_output(16); nrf_gpio_cfg_output(13); while (true</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 24 Nov 2021 15:05:38 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board" /><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340584?ContentTypeID=1</link><pubDate>Wed, 24 Nov 2021 15:05:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e9d2cbb5-733e-448c-81ba-5153178b4eb0</guid><dc:creator>Nagaraj JP</dc:creator><description>&lt;p&gt;thankyou i will check it out.&lt;/p&gt;
[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340471#340471"]In general, if your new issues or questions diverge from the original topic of the ticket I will have to ask that you open another ticket for the new matter.[/quote]
&lt;p&gt;yes sure i will make an seperate ticket for this thankyou&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340471?ContentTypeID=1</link><pubDate>Wed, 24 Nov 2021 08:44:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5919cc00-378d-443d-9556-35b6639fab35</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]now i am trying to read a differentia adc and to display the voltage in the serial monitor without using the log function how can i do in can you please help me out in this differential adc[/quote]
&lt;p&gt;If you would like to print something to the serial terminal without using the logger you may do so by using the app_uart library, or the UART driver directly. Alternatively, you could make sure to enable&amp;nbsp;RETARGET_ENABLED in your sdk_config.h, and then use the printf function as normal to display your data in the serial logger, after you have initialized the UART peripheral.&lt;br /&gt;You could see how this can be done in the BLE NUS example.&lt;br /&gt;&lt;br /&gt;In general, if your new issues or questions diverge from the original topic of the ticket I will have to ask that you open another ticket for the new matter.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340405?ContentTypeID=1</link><pubDate>Tue, 23 Nov 2021 15:58:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e2e1d1ad-7692-41d4-9d51-24d161578fcd</guid><dc:creator>Nagaraj JP</dc:creator><description>&lt;p&gt;Actually the board was given to the local service people in banglore. now i am trying to read a differentia adc and to display the voltage in the serial monitor without using the log function how can i do in can you please help me out in this differential adc&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340274?ContentTypeID=1</link><pubDate>Tue, 23 Nov 2021 09:04:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ef2ccd85-508f-42e1-92bb-a4c7aa12f995</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]yes still the led is not working, i have also checked with the BLE examples also the results are same.[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Then it does sound like the LEDs might have been damaged or otherwise disabled.&lt;br /&gt;Does everything else on the board function as expected?&lt;/p&gt;
[quote user="Nagaraj JP"]not exactly, we gave the board to the service people there they might have damaged the led section.[/quote]
&lt;p&gt;It might be the case that the LEDs have been damaged indeed.&lt;br /&gt;Which service people were this, have you had the board worked on by a third-party?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340161?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 15:34:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0e5c441c-53db-46dd-ad7b-6bc1bed85f40</guid><dc:creator>Nagaraj JP</dc:creator><description>[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340150#340150"]I am not sure I understand what you mean here - the Solder bridges are intact, but the leds still does not work? Does the leds light up in any of the other examples, such as one of the BLE peripheral examples? The LED1 will be blinking when the device is advertising, and solid if it enters into a connection.[/quote]
&lt;p&gt;yes still the led is not working, i have also checked with the BLE examples also the results are same.&lt;/p&gt;
[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340150#340150"] Do you suspect that the 4 LED pins have been damaged by the previous user of the board?[/quote]
&lt;p&gt;not exactly, we gave the board to the service people there they might have damaged the led section.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340150?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 15:13:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d4787c5f-1004-4734-9827-c54fdd33d03a</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]yes had a close look at the SB5 SB6 SB7 SB8 all the bridge are connected only, i have also checked with the multimeter it is showing connection. and now i checked with the p0.27 i can see the port pin working as per my commands as for now i am thinking to use this pin as the output. I think the u4 ic must have been damaged in my hardware. thankyou for the support..[/quote]
&lt;p&gt;I am not sure I understand what you mean here - the Solder bridges are intact, but the leds still does not work? Does the leds light up in any of the other examples, such as one of the BLE peripheral examples? The LED1 will be blinking when the device is advertising, and solid if it enters into a connection.&lt;/p&gt;
[quote user="Nagaraj JP"]I think the u4 ic must have been damaged in my hardware. thankyou for the support..[/quote]
&lt;p&gt;No problem at all, I am happy to help!&lt;br /&gt;This is the part I do not understand from your comment. Do you suspect that the 4 LED pins have been damaged by the previous user of the board?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340133?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 14:45:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dd34337f-fd24-432d-9a59-f5737a2e8e0c</guid><dc:creator>Nagaraj JP</dc:creator><description>[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340126#340126"]Did somebody else use the board for a different project prior to this?[/quote]
&lt;p&gt;yes it was used by our another person before that.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340126#340126"]They are marked SB5, SB6, SB7, and SB8 respectively. If they are cut then the LEDs will be disconnected from use.[/quote]
&lt;p&gt;yes had a close look at the SB5 SB6 SB7 SB8 all the bridge are connected only, i have also checked with the multimeter it is showing connection. and now i checked with the p0.27 i can see the port pin working as per my commands as for now i am thinking to use this pin as the output. I think the u4 ic must have been damaged in my hardware. thankyou for the support..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340126?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 14:22:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b3011855-e1c2-46e5-b135-fbabf0b23a3a</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]no this is an 6 months old board went for soldering service for the usb port and just now i recieved it.[/quote]
&lt;p&gt;Thank you for clarifying. Did somebody else use the board for a different project prior to this?&lt;/p&gt;
[quote user="Nagaraj JP"]sorry i could not understand this.[/quote]
&lt;p&gt;Could you do a close visual inspection of the Solder Bridges 5, 6, 7, and 8 on the PCB, to see if they may be cut?&lt;br /&gt;They are marked SB5, SB6, SB7, and SB8 respectively. If they are cut then the LEDs will be disconnected from use.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340110?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 14:00:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5f7ec466-e3fc-4c0e-a37f-65dc4840c765</guid><dc:creator>Nagaraj JP</dc:creator><description>[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340026#340026"]Where did you get your DK - was it a new kit, [/quote]
&lt;p&gt;no this is an 6 months old board went for soldering service for the usb port and just now i recieved it.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote userid="87869" url="~/f/nordic-q-a/81927/the-led-is-not-blinking-or-turning-on-in-nrf52840-dk-board/340026#340026"]In case of the latter, could you verify whether SolderBridge 5 - 8 is cut or not?[/quote]
&lt;p&gt;sorry i could not understand this.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340026?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 11:34:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d1291531-88bc-48a2-8f3a-fcb23c86cffb</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]yes i tried with the blinky example i could not see the led blinking[/quote]
&lt;p&gt;Then we need to debug this before we start debugging your application, since it may not be an application-logical issue.&lt;br /&gt;Where did you get your DK - was it a new kit, or did you get it from somebody else?&lt;br /&gt;In case of the latter, could you verify whether SolderBridge 5 - 8 is cut or not?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/340012?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 10:42:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb084482-eedb-4689-b80b-ec40da4733d5</guid><dc:creator>Nagaraj JP</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#include &amp;lt;stdbool.h&amp;gt;
#include &amp;lt;stdint.h&amp;gt;
#include &amp;lt;stdio.h&amp;gt;
#include &amp;quot;app_uart.h&amp;quot;
#include &amp;quot;app_error.h&amp;quot;
#include &amp;quot;nrf_delay.h&amp;quot;
#include &amp;quot;nrf_gpio.h&amp;quot;
#include &amp;quot;nrf.h&amp;quot;
#include &amp;quot;bsp.h&amp;quot;
//#include &amp;quot;nrf_drv_adc.h&amp;quot;
#include &amp;quot;nrf_drv_saadc.h&amp;quot;
#include &amp;quot;nrf_drv_ppi.h&amp;quot;
#include &amp;quot;nrf_drv_timer.h&amp;quot;

 


#include &amp;quot;nrf_log.h&amp;quot;
#include &amp;quot;nrf_log_ctrl.h&amp;quot;
#include &amp;quot;nrf_log_default_backends.h&amp;quot;



#if defined (UART_PRESENT)
#include &amp;quot;nrf_uart.h&amp;quot;
#endif
#if defined (UARTE_PRESENT)
#include &amp;quot;nrf_uarte.h&amp;quot;
#endif


//#define ENABLE_LOOPBACK_TEST  /**&amp;lt; if defined, then this example will be a loopback test, which means that TX should be connected to RX to get data loopback. */

#define MAX_TEST_DATA_BYTES     (15U)                /**&amp;lt; max number of test bytes to be used for tx and rx. */
#define UART_TX_BUF_SIZE 256                         /**&amp;lt; UART TX buffer size. */
#define UART_RX_BUF_SIZE 256                         /**&amp;lt; UART RX buffer size. */

void uart_error_handle(app_uart_evt_t * p_event)
{
    if (p_event-&amp;gt;evt_type == APP_UART_COMMUNICATION_ERROR)
    {
        APP_ERROR_HANDLER(p_event-&amp;gt;data.error_communication);
    }
    else if (p_event-&amp;gt;evt_type == APP_UART_FIFO_ERROR)
    {
        APP_ERROR_HANDLER(p_event-&amp;gt;data.error_code);
    }
}


#ifdef ENABLE_LOOPBACK_TEST
/* Use flow control in loopback test. */
#define UART_HWFC APP_UART_FLOW_CONTROL_ENABLED

/** @brief Function for setting the @ref ERROR_PIN high, and then enter an infinite loop.
 */
static void show_error(void)
{

    bsp_board_leds_on();
    while (true)
    {
        // Do nothing.
    }
}


/** @brief Function for testing UART loop back.
 *  @details Transmitts one character at a time to check if the data received from the loopback is same as the transmitted data.
 *  @note  @ref TX_PIN_NUMBER must be connected to @ref RX_PIN_NUMBER)
 */
static void uart_loopback_test()
{
    uint8_t * tx_data = (uint8_t *)(&amp;quot;\r\nLOOPBACK_TEST\r\n&amp;quot;);
    uint8_t   rx_data;

    // Start sending one byte and see if you get the same
    for (uint32_t i = 0; i &amp;lt; MAX_TEST_DATA_BYTES; i++)
    {
        uint32_t err_code;
        while (app_uart_put(tx_data[i]) != NRF_SUCCESS);

        nrf_delay_ms(10);
        err_code = app_uart_get(&amp;amp;rx_data);

        if ((rx_data != tx_data[i]) || (err_code != NRF_SUCCESS))
        {
            show_error();
        }
    }
    return;
}
#else
/* When UART is used for communication with the host do not use flow control.*/
#define UART_HWFC APP_UART_FLOW_CONTROL_DISABLED
#endif


/**
 * @brief Function for main application entry.
 */
 
 
int main(void)
{
    uint32_t err_code;

    bsp_board_init(BSP_INIT_LEDS);
	  NRF_LOG_DEFAULT_BACKENDS_INIT();

    const app_uart_comm_params_t comm_params =
      {
          RX_PIN_NUMBER,
          TX_PIN_NUMBER,
          RTS_PIN_NUMBER,
          CTS_PIN_NUMBER,
          UART_HWFC,
          false,
#if defined (UART_PRESENT)
          NRF_UART_BAUDRATE_115200
#else
          NRF_UARTE_BAUDRATE_115200
#endif
      };

    APP_UART_FIFO_INIT(&amp;amp;comm_params,
                         UART_RX_BUF_SIZE,
                         UART_TX_BUF_SIZE,
                         uart_error_handle,
                         APP_IRQ_PRIORITY_LOWEST,
                         err_code);

    APP_ERROR_CHECK(err_code);

#ifndef ENABLE_LOOPBACK_TEST
    printf(&amp;quot;\r\nUART example started.\r\n&amp;quot;);
    
		 
		  nrf_gpio_cfg_output(13);
			NRF_LOG_INFO(&amp;quot;SAADC HAL simple example started.&amp;quot;);
    while (true)
    {
			 
			nrf_gpio_pin_clear(13);
			 
			printf(&amp;quot;Ae\r\n&amp;quot;);
			nrf_delay_ms(100);
       // uint8_t cr;
       // while (app_uart_get(&amp;amp;cr) != NRF_SUCCESS);
       // while (app_uart_put(cr) != NRF_SUCCESS);

        /*if (cr == &amp;#39;q&amp;#39; || cr == &amp;#39;Q&amp;#39;)
        {
            printf(&amp;quot; \r\nExit!\r\n&amp;quot;);

            while (true)
            {
                // Do nothing.
            }
        }*/
    }
#else

    // This part of the example is just for testing the loopback .
    while (true)
    {
        uart_loopback_test();
    }
#endif
}
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;yes i tried with the blinky example i could not see the led blinking, and im sure that the controller has been flashed because im getting the printf function printing &amp;quot;AE&amp;quot; which im sending, i dont know where i am missing..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/339992?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 09:56:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c2d70480-5b01-4052-954b-ea270d4a9af0</guid><dc:creator>Karl Ylvisaker</dc:creator><description>[quote user="Nagaraj JP"]thankyou for the reply[/quote]
&lt;p&gt;No problem at all, I am happy to help!&lt;/p&gt;
[quote user="Nagaraj JP"]i am just trying to just on the first led which is given to 13 my full code is as follows even i tried the led blinky example though the led is not blinking.[/quote]
&lt;p&gt;Please use the&amp;nbsp;&lt;em&gt;Insert -&amp;gt; Code&amp;nbsp;&lt;/em&gt;option when sharing code on the forum. This drastically increases its readability.&lt;br /&gt;Are you saying that you tried the Blinky example, but it did not work? Did you not see the leds blink in sequence? Could you confirm that the program was successfully flashed and running on your DK?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/339982?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 09:33:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d12a38da-5ffd-4b33-8064-9d8b5b588d78</guid><dc:creator>Nagaraj JP</dc:creator><description>&lt;p&gt;thankyou for the reply i am just trying to just on the first led which is given to 13 my full code is as follows even i tried the led blinky example though the led is not blinking. the below is my full code for led burning but it is not working&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;#include &amp;lt;stdbool.h&amp;gt;&lt;br /&gt;#include &amp;lt;stdint.h&amp;gt;&lt;br /&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include &amp;quot;app_uart.h&amp;quot;&lt;br /&gt;#include &amp;quot;app_error.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf_delay.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf_gpio.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf.h&amp;quot;&lt;br /&gt;#include &amp;quot;bsp.h&amp;quot;&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;#include &amp;quot;nrf_drv_ppi.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf_drv_timer.h&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;#include &amp;quot;nrf_log.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf_log_ctrl.h&amp;quot;&lt;br /&gt;#include &amp;quot;nrf_log_default_backends.h&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;#if defined (UART_PRESENT)&lt;br /&gt;#include &amp;quot;nrf_uart.h&amp;quot;&lt;br /&gt;#endif&lt;br /&gt;#if defined (UARTE_PRESENT)&lt;br /&gt;#include &amp;quot;nrf_uarte.h&amp;quot;&lt;br /&gt;#endif&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;//#define ENABLE_LOOPBACK_TEST /**&amp;lt; if defined, then this example will be a loopback test, which means that TX should be connected to RX to get data loopback. */&lt;/p&gt;
&lt;p&gt;#define MAX_TEST_DATA_BYTES (15U) /**&amp;lt; max number of test bytes to be used for tx and rx. */&lt;br /&gt;#define UART_TX_BUF_SIZE 256 /**&amp;lt; UART TX buffer size. */&lt;br /&gt;#define UART_RX_BUF_SIZE 256 /**&amp;lt; UART RX buffer size. */&lt;/p&gt;
&lt;p&gt;void uart_error_handle(app_uart_evt_t * p_event)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;if (p_event-&amp;gt;evt_type == APP_UART_COMMUNICATION_ERROR)&lt;br /&gt; {&lt;br /&gt; APP_ERROR_HANDLER(p_event-&amp;gt;data.error_communication);&lt;br /&gt; }&lt;br /&gt; else if (p_event-&amp;gt;evt_type == APP_UART_FIFO_ERROR)&lt;br /&gt; {&lt;br /&gt; APP_ERROR_HANDLER(p_event-&amp;gt;data.error_code);&lt;br /&gt; }&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;#ifdef ENABLE_LOOPBACK_TEST&lt;br /&gt;/* Use flow control in loopback test. */&lt;br /&gt;#define UART_HWFC APP_UART_FLOW_CONTROL_ENABLED&lt;/p&gt;
&lt;p&gt;/** @brief Function for setting the @ref ERROR_PIN high, and then enter an infinite loop.&lt;br /&gt; */&lt;br /&gt;static void show_error(void)&lt;br /&gt;{&lt;/p&gt;
&lt;p&gt;bsp_board_leds_on();&lt;br /&gt; while (true)&lt;br /&gt; {&lt;br /&gt; // Do nothing.&lt;br /&gt; }&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;/** @brief Function for testing UART loop back.&lt;br /&gt; * @details Transmitts one character at a time to check if the data received from the loopback is same as the transmitted data.&lt;br /&gt; * @note @ref TX_PIN_NUMBER must be connected to @ref RX_PIN_NUMBER)&lt;br /&gt; */&lt;br /&gt;static void uart_loopback_test()&lt;br /&gt;{&lt;br /&gt; uint8_t * tx_data = (uint8_t *)(&amp;quot;\r\nLOOPBACK_TEST\r\n&amp;quot;);&lt;br /&gt; uint8_t rx_data;&lt;/p&gt;
&lt;p&gt;// Start sending one byte and see if you get the same&lt;br /&gt; for (uint32_t i = 0; i &amp;lt; MAX_TEST_DATA_BYTES; i++)&lt;br /&gt; {&lt;br /&gt; uint32_t err_code;&lt;br /&gt; while (app_uart_put(tx_data[i]) != NRF_SUCCESS);&lt;/p&gt;
&lt;p&gt;nrf_delay_ms(10);&lt;br /&gt; err_code = app_uart_get(&amp;amp;rx_data);&lt;/p&gt;
&lt;p&gt;if ((rx_data != tx_data[i]) || (err_code != NRF_SUCCESS))&lt;br /&gt; {&lt;br /&gt; show_error();&lt;br /&gt; }&lt;br /&gt; }&lt;br /&gt; return;&lt;br /&gt;}&lt;br /&gt;#else&lt;br /&gt;/* When UART is used for communication with the host do not use flow control.*/&lt;br /&gt;#define UART_HWFC APP_UART_FLOW_CONTROL_DISABLED&lt;br /&gt;#endif&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;/**&lt;br /&gt; * @brief Function for main application entry.&lt;br /&gt; */&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;int main(void)&lt;br /&gt;{&lt;br /&gt; uint32_t err_code;&lt;/p&gt;
&lt;p&gt;bsp_board_init(BSP_INIT_LEDS);&lt;br /&gt; NRF_LOG_DEFAULT_BACKENDS_INIT();&lt;/p&gt;
&lt;p&gt;const app_uart_comm_params_t comm_params =&lt;br /&gt; {&lt;br /&gt; RX_PIN_NUMBER,&lt;br /&gt; TX_PIN_NUMBER,&lt;br /&gt; RTS_PIN_NUMBER,&lt;br /&gt; CTS_PIN_NUMBER,&lt;br /&gt; UART_HWFC,&lt;br /&gt; false,&lt;br /&gt;#if defined (UART_PRESENT)&lt;br /&gt; NRF_UART_BAUDRATE_115200&lt;br /&gt;#else&lt;br /&gt; NRF_UARTE_BAUDRATE_115200&lt;br /&gt;#endif&lt;br /&gt; };&lt;/p&gt;
&lt;p&gt;APP_UART_FIFO_INIT(&amp;amp;comm_params,&lt;br /&gt; UART_RX_BUF_SIZE,&lt;br /&gt; UART_TX_BUF_SIZE,&lt;br /&gt; uart_error_handle,&lt;br /&gt; APP_IRQ_PRIORITY_LOWEST,&lt;br /&gt; err_code);&lt;/p&gt;
&lt;p&gt;APP_ERROR_CHECK(err_code);&lt;/p&gt;
&lt;p&gt;#ifndef ENABLE_LOOPBACK_TEST&lt;br /&gt; printf(&amp;quot;\r\nUART example started.\r\n&amp;quot;);&lt;br /&gt; &lt;br /&gt; &lt;br /&gt; nrf_gpio_cfg_output(13);&lt;br /&gt; NRF_LOG_INFO(&amp;quot;SAADC HAL simple example started.&amp;quot;);&lt;br /&gt; while (true)&lt;br /&gt; {&lt;br /&gt; &lt;br /&gt; nrf_gpio_pin_clear(13);&lt;br /&gt; &lt;br /&gt; printf(&amp;quot;Ae\r\n&amp;quot;);&lt;br /&gt; nrf_delay_ms(100);&lt;br /&gt; &lt;br /&gt; }&lt;br /&gt;#else&lt;/p&gt;
&lt;p&gt;// This part of the example is just for testing the loopback .&lt;br /&gt; while (true)&lt;br /&gt; {&lt;br /&gt; uart_loopback_test();&lt;br /&gt; }&lt;br /&gt;#endif&lt;br /&gt;}&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The led is not blinking or turning on in nrf52840 dk board</title><link>https://devzone.nordicsemi.com/thread/339970?ContentTypeID=1</link><pubDate>Mon, 22 Nov 2021 08:56:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1c7b09a7-73e1-496f-8deb-30ccfa2770fa</guid><dc:creator>Karl Ylvisaker</dc:creator><description>&lt;p&gt;Hello,&lt;br /&gt;&lt;br /&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/ug_nrf52840_dk/UG/dk/hw_buttons_leds.html"&gt;The LEDs on the nRF52840 DK are &lt;em&gt;active low&lt;/em&gt;&lt;/a&gt;, meaning that you have to set it to a logical zero to illuminate the LED. In your code, you are continuously setting pin 14, 15, and 16 in your while look, so there is no difference when running this in a loop. Are you not seeing your LED 1 illuminated? Is your program running at all?&lt;br /&gt;To toggle a LED I would recommend that you take a look at &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/gpio_example.html"&gt;the Blinky Example from the SDK&lt;/a&gt;. Please try this example, and verify that it functions as expected.&lt;br /&gt;&lt;br /&gt;As an additional comment you should use the BSP_LED definitions, or create a similar NRF_GPIO_MAP define for your LEDs, so that you avoid using magic numbers in your code. This drastically increases readability and maintainability of your code.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Karl&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>