 //  Display.touch_DetectRegion(100,100, 200, 200) ;
  //Display.gfx_MoveTo(30, 30);
 
+#include <stdio.h>
 
 #define DisplaySerial Serial1 
 #define HWLOGGING Serial // Serial port for debugging
 #define RESETLINE 4
-#define TEXTWIDTH 3
-#define TEXTHEIGHT 2
-#define BUTTON_H 44
-#define BUTTON_W 160
-#define BUTTON_SMALL_W 36
-#define PADDING 10
+#define TEXTWIDTH 5
+#define TEXTHEIGHT 5
+#define BUTTON_H 70
+#define BUTTON_W 230
+#define BUTTON_SMALL_W 55
+#define PADDING 12
+#define OK_BUTTON_ROW 6
 
 #include "Picaso_Serial_4DLib.h"
 #include "Picaso_Const4D.h"

  drawSmallButton("9", 2+coladd, 3+rowadd, BUTTON_UP);

  drawSmallButton("0", 1+coladd, 4+rowadd, BUTTON_UP);  
  drawButton("BACK", 0, 10, BUTTON_UP);
  drawButton("OK", 1, 10, BUTTON_UP);
}




void debugCoordinates()
{
  Display.txt_Width(1);
  Display.txt_Height(1);
  Display.txt_FontID(FONT1);
  Display.txt_MoveCursor(1,0);
  printint(x);
  Display.txt_MoveCursor(2,0);
  printint(y);
  Display.txt_Width(TEXTWIDTH);
  Display.txt_Height(TEXTHEIGHT);
}

void go()
{
  //TODO:go
  Display.gfx_Cls();
  for (int i=0; i!= index;i++)
  {
    Display.txt_MoveCursor(i,0);
    printCommand(i, commands[i], duration[i]);
  }
}

void printCommand(int i, int command, int duration)
{
  Display.txt_Width(2);
  Display.txt_Height(2);
  Display.txt_FontID(FONT3); 
  String c = "Move";
  c=i+" "+c+" "+duration;
  c.toCharArray(cstr,16);  
  Display.putstr(cstr);
}
