Changed SD library for nrf52 and got S&F working (#6382)

- Changed library from deprecated arduino SD library to wrapper of SdFat library
- Fixed some bugs in the S&F code for SD card storage
Now the S&F functionality works on nrf52 (tested on rak4631 with RAK15002)
This commit is contained in:
Woutvstk
2025-03-29 13:15:21 +01:00
committed by GitHub
parent d237d4f311
commit 7e7792aa51
5 changed files with 28 additions and 15 deletions

View File

@@ -138,6 +138,12 @@ static const uint8_t SCK = PIN_SPI_SCK;
#define SPI_MISO PIN_SPI1_MISO
#define SDCARD_CS (26)
// Some settings for the SdFat library to optimize flash usage
#define SDFAT_FILE_TYPE 1 // only support FAT16/FAT32, not exFAT
#define CHECK_FLASH_PROGRAMMING \
0 // this reduces flash usage but may cause higher power usage when sd card is idle TODO:Check if power usage is higher
#define MAINTAIN_FREE_CLUSTER_COUNT 1 // maintain free cluster count
/*
* eink display pins
*/