6 Replies Latest reply on Jul 19, 2020 6:17 PM by RodolfoG_11

    Porting FatFs to PSoC 6



      I am working on a master thesis project where basically I need to create a stand alone datalogger. While connection to the different sensors is not an issue, I cannot find an "easy" way to save the data somewhere and read it on a PC (best would be to generate a csv file).

      I am trying now to save the data on a SD card using SPI communication and FatFs. However, it seems there is no code working "out of the box" and my experience is very limited, so I ask for help to the community.


      I have found the following GitHub

      GitHub - hackingchips/PSoC_FatFs: Port of ELM-CHAN FatFs library to Cypress PSoc microcontrollers.

      I've tried to modify the sdcard.c and main file (my files in attachment) to match PSoC 6 macros, but I always get a "sdcard not ready" error.


      I have also tried to use the workaround code given in emFile component for PSoC 6 . I can read the files on the card, but the code does not include any writing capability and implement it myself is out of my league.


      Can I get help from somebody? Or perhaps, does anybody already have a working code?


      BTW, I am using Clicker 2 for PSoC® 6 with a microSD click.


      Thanks a lot