 
   if (inputLength == 0)
   {
-    Serial.println("Error: No valid date was found!");
+    Serial.println("Error: No valid input was found!\n");
     return;
   }
 
   // Convert char string to string. SDCard writeFile method expects String.
   String message = String(buffer);
 
+  Serial.println("Writing to " + String(FILENAME) + ":");
+  Serial.println(message);
+  Serial.println();
+
   bool isSuccess = sd.writeFile(FILENAME, message);
 
   if (isSuccess)
   {
-    Serial.println("Message written to file successfully!");
+    Serial.println("Message written to file successfully!\n");
   }
   else
   {
-    Serial.println("Error: Could not write message to file!");
+    Serial.println("Error: Could not write message to file!\n");
   }
 }
 

const int MESSAGE_SIZE = 101;

// Set the name of the file to be read.
#define FILENAME "backup.txt"

// Instantiate SDCard object. Need to call begin before using.
UASensors_SDCard sd(CS_PIN);


// Menu options recognized from Serial input
const char READ_FILE = 'r';
const char WRITE_FILE = 'w';


  - Write file appends to existing content

  Created 14 6 2014
  Modified 22 6 2014
*/
#include <UASensors_SDCard.h>

