This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

About a procedure with UART as disable

Because of the power-saving support, I want to disable the UART before Call the sd_app_evt_wait().

I referred to two following sites to know the procedure of the case. 1.https://devzone.nordicsemi.com/question/5186/how-to-minimize-current-consumption-for-ble-application-on-nrf51822/?answer=5187#post-id-5187

2.https://devzone.nordicsemi.com/question/1119/handling-the-uart-when-sleeping/

However, there is for difference at the point that execute the following code when disable does UART in a procedure written as 1 to 2.


// Set TXD, RXD, CTS, RTS as high outputs
// Alternatively use NRF_GPIO->PIN_CNF to set pull resistors

NRF_GPIO->DIRSET = (1 << UART_TXD_GPIO) | (1 << UART_RXD_GPIO) | (1 << UART_RTS_GPIO) | (1 << UART_CTS_GPIO);

NRF_GPIO->OUTSET = (1 << UART_TXD_GPIO) | (1 << UART_RXD_GPIO) | (1 << UART_RTS_GPIO) | (1 << UART_CTS_GPIO);

As a result of having tried each procedure, I became able to reuse UART in 2 procedures, but UART did not become reusable in 1 procedure.

When disable does UART, is it right to perform in a procedure listed in 2?

Related