 #include <Shiftduino.h>
 #include "Square.h"
 
+#include <Wire.h>
+#include <GraphicDisplay.h>
+#include <SM125.h>
+
+#define DISPLAY_ADDRESS  0x51
+#define BUTTONS_CHANGE   43
+#define SM125_ADDRESS 0x46
+
+// Baseboard screen
+GraphicDisplay display;
+// Baseboard RFID reader
+SM125 sm125;
+
+// Configuration for the shift registers
 int numShifts = 3;
 int datapin = 22;
 int clockpin = 24;
 int latchpin = 23;
 
 Shiftduino _sd(datapin, clockpin, latchpin, numShifts);
+
+// Unique board ID (TODO: right now is set manually for testing purposes)
+int player_id = 1;
+int rival_id = 0;
+
+// Each of the squares of the tictactoe
 Square * squares[9];
 
 //int gameStatus = 0; //0 = ongoing game, 1 = you win, 2 = opponent wins
 //int currentTurn = 0; //0 you, 1 opponent
 
+// square status
 int redStatus [] = {0,0,0,0,0,0,0,0,0};
 int greenStatus [] = {0,0,0,0,0,0,0,0,0};
 
+// conditions for victory
 int winConditions [][9] = {{1,1,1,0,0,0,0,0,0},
                               {0,0,0,1,1,1,0,0,0},
                               {0,0,0,0,0,0,1,1,1},

  squares[7]->calibrateCNY70(480, 430, 380, 300);
  squares[8]->calibrateCNY70(340, 290, 230, 170);  
}

void updateColorStatus(){
  for (int i=0; i < 9; i++){

    }  
    win = isSame(result, winConditions[i]); 
  }
  return win;  
}

void checkColor(int s){
  int colorValue = squares[s]->getColorValue();
  Serial.println(colorValue);
}

void victoryLoop(char color){
