 SdFat SD; //Added for backwards compatability. This was suggested on the Arduino forum
 //by user Scottrockcafe to user trilbytim (https://forum.arduino.cc/index.php?topic=231495.0).
 //Create file for saving to SD Card
-File resultFile;
-String fileName = "test.txt"; //Change as needed
+String fileName = "calibration.txt"; //Change as needed
 #define SD_CS_PIN SS //Defines CS pin as SS for SD card
+SdFile file;
 
 
 //Set pins for MISO/MOSI/SS/PP

Adafruit_ADS1115 ads1115; //Creates instance of ads1115
Adafruit_ADS1115 ads(0x48); //Sets base address
//Create variables for displaying on LCD and saving to SD Card
float cVoltage; //16 bit variable reading from ADC's A0
String resultmV; //String containing reading from ADC in mV
String resultV; //String containing reading from ADC in V


//The LiquidCrystal library facilitates usage of the  LCD screen
#include <LiquidCrystal.h>

  LCDwrite("Detecting SD..", "");
  delay(500);
  LCDwrite("Detecting SD...", "");
  delay(500);
  //Begin SD Card module
  if (!SD.begin(SD_CS_PIN)) {
    lcd.clear();
