First

Dependencies:   UniGraphic mbed

Revision:
0:f17efa877b15
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/LCD.cpp	Thu Jan 14 20:54:51 2016 +0000
@@ -0,0 +1,41 @@
+#include "LCD.h"
+#include "stdio.h"
+#include "string"
+#include "ILI932x.h"
+
+#include "Arial12x12.h"
+#include "Arial24x23.h"
+#include "pavement_48x34.h"
+
+Serial pc(USBTX, USBRX);
+
+PinName dataBus[]= {p30, p29, p28, p27, p26, p25, p24, p23};
+ILI932x myLCD(BUS_8, dataBus, p15, p17, p16, p14, p20, "myLCD", 240, 320); // Bus 8 bit, bus pin array, CS, RST, DC, WR, RD, name, xpixels, ypixels
+
+char orient=3;
+int x,y;
+
+int pos1=160;
+int pos2=120;
+int direction1= 0;
+int direction2= 0;
+
+void LCD_init()
+{
+    myLCD.set_orientation(orient);
+    myLCD.set_font((unsigned char*) Arial24x23);
+    myLCD.background(Blue);    // set background to red
+    myLCD.foreground(White);    // set chars to black
+    myLCD.cls();    
+}
+
+void LCD(int x,int y)
+{
+    
+    myLCD.cls();
+    if(!x){pos1--;}
+    if(!y){pos1++;}
+    myLCD.circle(pos1,pos2,30,Red);
+    wait(.1);
+  
+}
\ No newline at end of file