#include <UTFT.h>
#include <URTouch.h>

UTFT myGLCD(SSD1289, 38, 39, 40, 41);
URTouch myTouch(42, 43, 44, 45, 46);

// Declare which fonts we will be using
extern uint8_t BigFont[];
extern uint8_t SmallFont[];

int x, y;
char stCurrent[20] = "";
int stCurrentLen = 0;
char stLast[20] = "";

#define D0 4
#define D1 5
#define D2 6
#define D3 7
#define D4 9
#define D5 10
#define D6 11
#define D7 12

#define STROBE 50
#define BUSY 51

#define _pinDisplayPower 53

String inputString = "";         // a string to hold incoming data
boolean stringComplete = false;  // whether the string is complete

void setup() {
  // put your setup code here, to run once:
  Serial.begin(9600);

  pinMode(_pinDisplayPower, OUTPUT);
  digitalWrite(_pinDisplayPower, HIGH);

  InitPrinter();
  setupScreen();
  setupSerialInput();

  // printCentronics("Printer test\r");
}
