Rihards Balass / 4DGL-mbed-32PTU
Revision:
5:890ddd974624
Parent:
4:50511ed54ab4
Child:
6:a1a85f2bc04b
--- a/Picaso_4DGL-32PTU.h	Fri Sep 09 12:45:28 2016 +0000
+++ b/Picaso_4DGL-32PTU.h	Mon Sep 12 10:15:54 2016 +0000
@@ -34,7 +34,7 @@
 #define ORIENTATION         0xFF9E
 
 // text functions values
-#define TEXT_BG_COLOR      0xFFE6
+#define TEXT_BG_COLOR       0xFFE6
 #define SET_FONT            0xFFE5
 #define PUT_CHAR            0xFFFE
 #define PUT_STRING          0x0018
@@ -52,7 +52,7 @@
 #define TEXT_ATTRIBUTES     0xFFDA
 
 // graphics functions values
-#define CHANGE_COLOR       0xFFB4
+#define CHANGE_COLOR        0xFFB4
 #define DRAW_CIRCLE         0xFFC3
 #define CIRCLE_FILLED       0xFFC2
 #define DRAW_LINE           0xFFC8
@@ -157,7 +157,7 @@
 #define font2           2
 #define font3           3
 
-#define bufLen          32
+#define RXBUFLEN        32
 
 //**************************************************************************
 class PICASO_4DGL {
@@ -166,13 +166,14 @@
 
     Serial pc; // serial variable for debug information
     PICASO_4DGL(PinName tx, PinName rx, PinName rst); // LCD serial construnctor
-    int resp, respLen; // received response from screen
+    int index; // received response from screen
     char response[];
-    uint8_t rxBuf[];
+    char rxBuf[];
     
 // General Commands
-    void getResponse();
-    void responseBuild(int);
+    void rxCallback();
+    void getResponse(int); // wait for LCD response
+    //void responseBuild(int);
     void reset(); // reset screen
     void baudrate(long); // set baudrate
     void screenOrientation(char); // set desired orientation of a screen
@@ -225,7 +226,6 @@
     
     
     void freeBUFFER  (void);
-    void clearResponse();
     void writeBYTE   (char);
     void writeCOMMAND(char *, int); // send command to screen
 };