Thanks for looking at this, code in the webduino handler is cut and pasted from the example with a change to variable names viz;
if (!sd.init(SPI_FULL_SPEED, chipSelect)) fatalError("SD init error");
...
while (myFile.openNext(sd.vwd(), O_READ)) {
myFile.getFilename(name);
cout << name << endl;
myFile.close();
}
...
Files are all YYYYMMDD.LOG or ALPARMS.TXT, some of the .LOG files are missing as is ALPARMS.TXT and I'm using the latest SDFAT code (Sept 2nd 2011).
I worked around it with the following which works fine;
...
if (!card.init(SPI_FULL_SPEED, chipSelect)) fatalError("SD init error");
if (!volume.init(&card)) fatalError("vol.init failed!");
if (!root.openRoot(&volume)) fatalError("openRoot failed");
...
while (root.readDir(p) >0) {
if (p.name[0] == DIR_NAME_FREE) break;
if (p.name[0] == DIR_NAME_DELETED || p.name[0] == '.') continue;
if (!DIR_IS_FILE_OR_SUBDIR(&p)) continue;
nameS = "";
for (uint8_t i = 0; i < 11; i++) {
if (p.name[i] == ' ') continue;
if (i == 8) {
nameS += '.';
}
nameS += String(p.name[i]);
}
Serial.print(nameS);
...
}
This is part of a very large sketch (1,381 lines) so difficult to produce a minimum reproducible case, its probably not worth spending much time getting to the bottom of this unless others have similar problems.