Hi Nordic Dev Team,
I am trying to send my log data from my flash memory into Android Phone. I followed this example :
github.com/.../nRF5x-custom-ble-service-tutorial
So I have already set up a custom UUID Service and Characteristics for this purpose, so whenever the command is triggered. My unit is going to write its flash data into the characteristics, so I tried to look at how ble_nus_data_send() is implemented and kinda copied it but I got confused with the
err_code = blcm_link_ctx_get(p_nus->p_link_ctx_storage, conn_handle, (void *) &p_client);
So scenario is like:
1. Detect the amount of flash memory data that is going to be send.
2. Call err_code = sd_ble_gatts_hvx(p_cus->conn_handle, &hvx_params);
3. Send continuously until the end of flash memory data.
I kept getting NRF_ERROR_DATA_SIZE on sd_ble_gatts_hvx(p_cus->conn_handle, &hvx_params), since I try to convert the data that I stored (uint32_t and uint32_t) into uint8_t buffer[8]; everything is already converted to byte arrays and I just passed the value and the length.
I wonder if there's any example that does this? It's so confusing