#include <TFT_eSPI.h>
#include <SPI.h>       // this is needed for display
#include <ArduinoTrace.h>

#include "Display.h"
#include "Led.h"
#include "Square.h"

//This display 320 x 240 pixels; TTGO display 240 x 135
TFT_eSPI display = TFT_eSPI(); // Invoke custom library with default width and height

Led mled(&display, (SCREEN_WIDTH  / 2), (SCREEN_HEIGHT  / 2));
Square squ(&display);

void setup(void)
{
  Serial.begin(115200);
  mled.init();
}


void loop()
{
  unsigned long curr_time = millis();
  squ.handle(curr_time);
  mled.handle(curr_time);
}