Can data in the cache be moved to the RF FIFO via DMA?

  • I want to increase the rate of data from UARTE to RF FIFO.Can data be transferred from the cache to the RF FIFO using DMA?

  • nrf52832 nRF5_SDK_17.1.0_ddde560  S132
  • Hello,

    No, that is not possible, unfortunately. It is not a full fledged DMA in that way. In addition, if you are using the softdevice (s132), then you will not have full access to the radio either way, and all the data that you want to send over BLE needs to be wrapped in headers before it is sent, which is what the SoftDevice will do for you. But you need to use the SoftDevice API.

    Perhaps you want to look into the ble_app_uart example from SDK17.1.0\examples\ble_peripheral\ble_app_uart. Perhaps this is doing something similar to what you want to acheive.

    Best regards,

    Edvin

  • Thank you for your help.

    • I have two more questions.app_uart_get() only gets one byte at a time. Can I use it to get more than one byte at a time?I see DMA carrying multiple bytes at a time. Can I get multiple bytes at a time if I use registers directly?I need to transmit data through uart and Bluetooth, and I want to increase the rate as much as possible.The current baud rate 460800 peripheral is 37.5kb/s, and I want to find a way to increase the rate on the uart. The Bluetooth rate is about 120kb/s.

  • Hello,

    app_uart_get() will give you one byte at the time, yes. You need to call it in a loop to get more bytes. But this uses an internal buffer (app_fifo) and the app_uart module also gives you an interrupt whenever new data is available (which is where you would typically call app_uart_get())

    A baud rate of 460800 equals 57kB/s.

    You can increase the uart baudrate to 1M (1000000), which equals 125kB/s.

    in ble_app_uart, you can do so by changing 

    .baud_rate    = NRF_UART_BAUDRATE_115200
    to
    .baud_rate    = NRF_UART_BAUDRATE_1000000

    But of course the baudrate needs to be matched on the connected device. 

    • How can I increase the rate without changing the baud rate

  • A baud rate of 460800 equals 45kB/s.

    • The actual serial port rate is about 38kb/s

Related