if (SD_present) {
File dataFile = SD.open("datalog.txt", FILE_READ); // Now read data from SD Card
if (dataFile) {
if (dataFile.available()) { // If data is available and present
String dataType = "application/octet-stream";
if (server.streamFile(dataFile, dataType) != dataFile.size()) {Serial.print(F("Sent less data than expected!")); }
}
}
dataFile.close(); // close the file:
}
}