Code: Select all
File file = directory.openNextFile();
tmp = file.name();
Serial.printf("_Testing %s\r\n", tmp.c_str());
if (file.isDirectory() || !(tmp.endsWith(".wav") || tmp.endsWith(".WAV"))) {
// skip if it's a directory or not wav
}
If they'd be shorten or modified in some way like, say, Windows did (SHORTE~1.TXT), that'd be fine.
Or maybe there's some way to open one particular file when we don't know it's name?