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

NRF51DK disable transmission

I am using the ble_app_uart on the nrf51dk.RX is always enabled.I want to enable TX when data is to be transmitted and then disable it again.

I am using

NRF_UART0->TASKS_STOPTX = 1;

to disable transmission.

But when i use

NRF_UART0->TASKS_STARTTX = 1;

transmission is not enabled again..

Is there anything else that i have to write to Reenable transmission?

please help..

  • FormerMember
    0 FormerMember

    ble_app_uart uses the UART module (app_uart) for the UART communication. The UART module uses the UART driver, nrf_drv_uart.

    When I test the bare UART example in the "peripheral" folder, which also uses the UART module, it seems like writing directly to the register to doesn't work..

    However, calling nrf_drv_uart_tx_abort() should stop TX, and nrf_drv_uart_tx() should start TX. To call the nrf_drv_uart_xx functions, you will need the instance structure (or a pointer to it). I haven't tested it, but it's worth a try.

Related