I am using the FRDM-K64F board, MCUxpresso SDK, FreeRTOS and the SDHC driver.
I created a new project and have a FRTOS task that initialises the SD card and attempts to write a raw block of data to it, I am using the code from the "xxxx_driver_examples_sdcard_sdcard_freertos" SDK example which runs fine if I build that project to the K64F.
In my new project, I am using an almost identical configuration as the example, yet my project crashes on a hard fault when attempting to write a block the SD card. SD card powers on and initialises fine.
I have attached the thread/stack frame list and highlighted the block of code where it crashes. I have tried many fixes with ISR priorities and heap/stack sizes, and even when I use the same config as the example, it still crashes.
The only major difference is that my project is C++ using NewLibNano, and the example project is C RedLib.