void TestPrintln(){
  Serial.println("Test from subroutine success.");
  }

void setup() {
  // put your setup code here, to run once:
    Serial.begin(115200);
    Serial.println("Boot started.");
    Serial.println("----------------");
}

void loop() {
  //Check commands over serial  
  if (Serial.available())
  {
    String command = Serial.readStringUntil(10);

    if (command == "reboot"){ESP.restart();}
    else if (command == "testl") {Serial.println("Test from loop success.");}
    else if (command == "tests") {TestPrintln;}
    
  }
}