Hello all, I hope you are doing well.
I Have a project on NRF52840 in which I have multiple sensors connected to the NRF52 and the sensor data are storing in the SD card in the form of a CSV file of size 240 MB. I want to read this large file from the SD card and then send it to the mobile app using ble_periperhial. I have used This example and modified it, but the problem is that I can only read 220000 bytes from the SD card in the buffer at once and when I am trying to increase
#define FILE_SIZE_MAX (Maximum size in bytes of the file to be read from SDCARD) greater than 220000, while the following;
static uint8_t file_buffer[FILE_SIZE_MAX];
ff_result = f_read(&file, file_buffer, FILE_SIZE_MAX, (UINT *) &bytes_read);
Then it gives the following error:
.bss is too large to fit in RAM1 memory segment
.heap is too large to fit in RAM1 memory segment
section .heap overlaps absolute placed section .stack
section .stack VMA [000000002003e000,000000002003ffff] overlaps section .bss VMA [0000000020002c64,0000000020224b08]
I don't know about this error and how to solve it. Simply I want to read the whole file (234MB) from the SD card at once and then send it in chunks to the mobile app, Is this possible or do I have to read in chunks from the SD card too?
Any help regarding this will be highly appreciated.