Hi All,
I am a beginner,Can you please explain me what is the role of this line?
APP_ERROR_CHECK(nrf_drv_spi_transfer(&spi, m_tx_buf, m_length, m_rx_buf, m_length));
Hi All,
I am a beginner,Can you please explain me what is the role of this line?
APP_ERROR_CHECK(nrf_drv_spi_transfer(&spi, m_tx_buf, m_length, m_rx_buf, m_length));
Is there any redundant or unused data i am sending in here?
No, calling nrf_drv_spi_transfer
function like this only starts the transfer. As everything on nRF5x (and any other uC) it is asynchronous so the result comes in spi_event_handler
callback function which was provisioned to SPI driver in nrf_drv_spi_init
call.
Btw. are you planning to use BLE stack (Nordic Soft Device)? If yes then such linear architecture won't work, WFE
/WFI
is used only in HW drivers' examples without BLE...
Ok, so this is ok to practice like this? No extra data is sent and i can rely on this?
Yes, i am using BLE. But, it is working, all the ble, display and the sd card, i was just bothered about the data what i am sending should not be extra.