Add totalBytes / usedBytes to SD/SDMMC (#673)

to be same as SPIFFS
This commit is contained in:
Luc
2017-09-28 10:01:02 +08:00
committed by Me No Dev
parent a66b544d18
commit 3ba46c7fbc
6 changed files with 65 additions and 0 deletions

View File

@ -209,6 +209,8 @@ void setup(){
renameFile(SD_MMC, "/hello.txt", "/foo.txt");
readFile(SD_MMC, "/foo.txt");
testFileIO(SD_MMC, "/test.txt");
Serial.printf("Total space: %lluMB\n", SD_MMC.totalBytes() / (1024 * 1024));
Serial.printf("Used space: %lluMB\n", SD_MMC.usedBytes() / (1024 * 1024));
}
void loop(){