 
 int numberOfFiles = 0;
 int pastMode = HIGH;
+int pastTest = HIGH;
 boolean SD_OK = false;
 
 // The setup (runs once at start up)

    }
  }
  else { // Uesd to debug a bmp file
    if (bmpDraw(TESTPICTURE, 0, 0)) delay(DELAY_TIME);
  }
}

    Serial.println('1');
  }
  else {
    Serial.println(numberOfFiles);
  }

  tft.setRotation(0); // Portrait

  // Seed random number generator
  randomSeed(analogRead(A0));

  // Display splash screen
  if (digitalRead(TEST_PIN) == LOW) {
    Serial.print("Mode = ");
    Serial.println((digitalRead(MODE_PIN)) ? "Random" : "Sequential");
    Serial.println();
    displaySplashScreen();
  }
  else {
    Serial.print("Mode = ");
    Serial.println("TEST");
    Serial.println();
    displaySplashScreen(Test);
  }
  pastMode = digitalRead(MODE_PIN);
}

// The loop (runs forever)
