Is AudioSourceSDFAT capable of using SdFat in SD_FAT_TYPE 3 mode (Fat16/Fat32/ExFat)? #2139
-
I'm trying to go through all the examples to get my program to work with AudioSourceSDFAT, but I want to get the code to work with the AudioPlayer class using AudioSourceSDFAT in what appears to be an oddball configuration. Currently, I can get it to work with my FAT32 formatted SDCard, but I want to use a bigger SD card in its place, formatted as ExFAT, with the option to still use a FAT32-formatted SD card. currently, I can make the example player-sd_m4a-audiokit.ino somewhat work as a baseline (using I2SStream instead), so my hardware works. I get audio playback. But All the SdFat examples in your repo have been using it in the FAT32 mode, using a similar method to the latest example you uploaded (player-vector_sdfat-audiokit.ino) but it seems to be using SdFat in Fat32 mode, using SdFat and File32 classes. From my understanding of the documentation of SdFat, I need to use SdFs sd; and FsFile instead if I want to support FAT16/FAT32/ExFAT at the same time. Is this a supported configuration? I haven't had a chance to try for myself and compile the player-vector_sdfat-audiokit.ino example using SdFs and FSFile instead, but I guess I will try and see if I can get it to work when I get back to my developer board. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If you check the class documentation for AudioSourceSDFAT you can see that it is a template class (that uses SdFat32 and File32 automatically if nothing has been specified) so just provide your desired FS and File class!
But I suggest that you test your desired functionality outside of the AudioTools first... |
Beta Was this translation helpful? Give feedback.
If you check the class documentation for AudioSourceSDFAT you can see that it is a template class (that uses SdFat32 and File32 automatically if nothing has been specified) so just provide your desired FS and File class!
But I suggest that you test your desired functionality outside of the AudioTools first...