#include <TFT_eSPI.h>
#include <SPI.h> // this is needed for display
#include <ArduinoTrace.h>
//This display 320 x 240 pixels;
#define SCREEN_WIDTH 240
#define SCREEN_HEIGHT 320
TFT_eSPI tft = TFT_eSPI(); // Invoke custom library with default width and height
//----- TODO: DECLARE GLOBAL VARIABLES ------------------//
uint16_t colors[4] = {TFT_RED, TFT_GREEN, TFT_BLUE, TFT_YELLOW};
uint8_t maxrad = (SCREEN_WIDTH / 2);
uint8_t xorigin = (SCREEN_WIDTH / 2), yorigin = (SCREEN_HEIGHT / 2);
uint8_t circle_gap = 25;
//------------------------------------------------------//
void setup(void) {
Serial.begin(115200);
Serial.println("INICIO:");
tft.init();
tft.setRotation(0);
//----- TODO: WRITE REQUIRED CODE ------------ ---------//
for (int i = 0; i < 4; i++) {
tft.fillCircle(xorigin, yorigin, maxrad - (circle_gap * i), colors[i]);
}
//------------------------------------------------------//
}
void loop() {
}