Adding libraries to hardware for which demos are not provided


I’d like to try getting FreeRTOS+FAT running on a Cyclone V SoC eval board to read and write to an SD card but can’t seem to find any good documentation on how to get started. I was able to get the Altera Cyclone V SoC ARM Cortex-A9 Demo Application running ( and was hoping I could add the +FAT files to that project to do so.

I found this post FreeRTOS+FAT on Altera (Intel) Cyclone V SoC that gave me some clues but I’m not sure how to proceed with this information. For example do I have to write an ff_sddisk.c file specific for the Cylcone V or can I pull this from somewhere else?

Any direction would be much appreciated.

Did you see these pages? - you will need to create an initialise function (presumably), a read function and a write function that store and retrieve the file system data and structures created by FreeRTOS+FAT to and from the SD card. Are you using an SPI interface to the SD card? If so you can take a look at some of the other SD drivers in subdirectories from here and adapt to whichever drivers Intel/Altera provide with the SoC. You may like to get the code working with a RAM driver, so storing the files in RAM, and then adapt that to the SD card as that will not require any porting as reading from and writing to ram is the same on all architectures.

Hi Richard,

Thanks for the info. That gives me some good direction for now.