       victoryLoop('g');
     }
   }
-  
+
   if ((turn > 0) || (turn == 0 && start_turn=="1")){
     // ************************************************************************
     // ******* Rival turn *****************************************************
     // ************************************************************************
     printMsg("Wait for your rival's move.");
-    
+
     // 1- Check rival move, wait until it happens
     int rival_move = -1;
     rival_move = getMove();
-      
+
     // 2- Update color status
     if (rival_move > -1 && rival_move  < 9){
       redStatus[rival_move] = 1;
       squares[rival_move]->setRed();
     }
-    
+
     // 3 -Check victory conditions
     redVictory = checkWin(redStatus);
     if (redVictory){

      player_move = i;
    }
  }
  
  if (totalMoves == 0) {
    // The player has not done any move
    player_move = -1;
  } else if (totalMoves > 1) {
    // The player has moved 2 pieces, which is an illegal move
    player_move = -2;
  }

/**********************************************
 *   COMMUNICATION WITH THE GAME SERVER
 **********************************************/

void registerPlayer(){
  Serial.println("Registering player...");
  sendMsg(MSG_REGISTER + SEP_CHAR_COMMANDS + player_id + END_CHAR);
