This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28388D: Problem with FAT32 writting name of files with SD and SPI

Part Number: TMS320F28388D
Other Parts Discussed in Thread: C2000WARE

Good afternoon,

I am writing to you because I have the following problem that I cannot solve: I want to create .csv files with SPI on the SD card using the controlcard of a TMS320F28388D. I am using both the example "sd_fat32" and the example "sd_fat32_exfat". The problem I have is with the length of the filename I want to create in f_open. If the file I create is longer than 7 letters (I exclude ":" and ".txt" ) I get an INVALID_NAME error in fresult. I would like to know if this limitation can be corrected in a way because it limits me a lot. My idea is to create files with date and time names such as "YYYYY/MM/DD_HH/mm/ss.csv". This file would have a name of 19 characters (removing the "/" and "_" it could be 14 characters). However, it is impossible to create a file with such a name. I would like to know if there is a way to implement it. In principle I don't care if it is FAT32 or exFAT format, I would really appreciate your help, because I don't see any way how to do it.

Thank you in advance,

Pedro

  • Pedro, 

    In f_open, the INVALID_NAME error is obtained when the path is incorrect, it really is not dependent on the character length. 

    I would suggest work from the C2000ware example available, edit the path incrementally and try to figure out where it breaks in case it does. 

    Could you also mention how have you actually checked that the error is being caused by length of the file and not any other factor?

    Thanks.