Hello,
IDE - Visual Studio Code
SDK version - 2.9.0
Computer platform - Win11
I'm at the early stages of a project which first requires to send ~10K of data to the nrf52dk (configured as 52832) in a series of slices between 300 to ~2,000 bytes per slice. This is done as write without response so there are three stages each with a separate characteristic:
1. Start transfer sending the total number of bytes which will eb sent
2.Repeated transfers until the number of bytes is reached
3. End transfer detailign how many bytes will be expanded to using LZ4 (though this is not implemented yet)
I've got a GATT characteristic for each item:
Start Transfer
This calls a separate method which mallocs the memory for the data:
Then the data is repeatedly transferred and the image_data variable has the data appended to it until we reach the end:
The end basically just frees up the image_data memory (we'll add the implementation to actually process the data later):
When I execute this I have success for the first ~5K but then I get the following error:
I've used coredump to get a stack trace from this which gives:
I'm not sure where to go next; do we just have a case that the calls from the other end (currently a test python script sending data using bleak) is running much faster than the nordic and just overruns the nordic as it cannot keep up with the data? I'm not sure about that though because I'm not sending _huge_ amounts of data. If that is the case do I setup a notify system between each slice to give a handshake to central so it 'slows down'? I've tried increasing the stack size up to 16K but it still fails at the same place.
Thanks for your help.
Cheers,
Neil