I am using a ultra-miniature (BMD-350) series module from Rigdo which has the nRF52832 BLE SoC. The pins from the nrf52 SoC are all brought out on a female headers on a custom PCB.
Firmware/SDK configuration:
- nRF5_SDK_15.3.0_59ac345 SDK
- pca10040 and softdevice s132
- nrf52832_xxaa
Debugger
- J-Link EDU Mini debug module and using Segger Ozone software for debugging.
nrf Android Apps:
- nrFConnect, nrF Logger and nrfUART app
I have modified the ble_app_uart example and attached the zip file of modified code.
In the main.c file, I modified the function nus_data_handler to send dummy packets(appx. 24 bytes per packet) to the nrfUART app by calling the function ble_nus_data_send periodically 5 seconds over BLE NUS to nrfUART app inside a loop over 500 times. Below is the code snippet:
While I do receive first 12 packets on nRFUART app but thereafter I stop receiving anything even though I should continue to receive remaining 489 of 500 dummy packets. The Bluetooth connection also gets disconnected and I dont see the nrf52 advertising. Thereafter, I have to reset my nRF52 to make new Bluetooth connection and restart this process.
I have tried manipulating buffer sizes used by ble_nus_data_send as well as UARt bufffers, but nothing seems to work. Either I get run-time error or issue remains.
What is the proper way to send streaming data packets to the nrfUART from nrf52 continuously using the BLE UART service ?