Library to drive an ILI9225 2.2" SPI TFT.

Dependents:   ILI9225_TFT_Sample

ILI9225 SPI TFT Library

/media/uploads/Arman92/ili9225_tft_front-1-.jpg

This library works with the ILI9225 based 2.2" 176x220 TFT LCD shields commonly found on eBay. Note that there is a commonly available 2.2" 240x320 TFT module very similar in appearance but using the ILI9341 driver. (Only the main Buffer IC and I/O pins are different)

Sample Usage program

Wiring guide :

mbed boardLCD board
+ 3,3V or +5VVCC
GNDGND
GPIO_PINRST (Reset pin)
GPIO_PINRS [Command (RS=0)/ Parameter (RS=1)]
GPIO_PIN or GNDCS (Chip selection pin)
SPI_MOSISDI (Serial data input )
SPI_SCKCLK (Reference clock)
GPIO_PIN or PWM or VCCLED (Backlit)
Revision:
0:e97881aef140
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/FAmap.h	Mon Aug 31 05:05:09 2015 +0000
@@ -0,0 +1,87 @@
+//------------------------------------------------------------------------------------------------
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+//------------------------------------------------------------------------------------------------
+/*
+....::::: In The Name Of GOD :::::....
+
+
+****************                               ******************
+
+Ported to ILI9225 by Arman Safikhani  31-08-2015
+
+****************                               ******************
+
+
+TFT LCD (ILI9325-ILI9320 LCD Driver) Functions (ECA 2.8 inch LCD Module)
+Version : 1.0
+By Ali Imanifar                 11/06/2013
+
+ECA Corporation........www.ECA.ir
+ECA Eshop..............www.Eshop.ECA.ir
+ECA Forum..............www.ECA.ir/Forum2
+ECA Video Center.......www.TV.ECA.ir
+ECA Blog...............www.Blog.ECA.ir
+
+Important Note :
+DO NOT Change LCD Register Definitions And LCD Command Codes
+*/
+//------------------------------------------------------------------------------------------------
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+//------------------------------------------------------------------------------------------------
+
+
+const unsigned char FAmap[50][6] =
+{
+    //x-C1+5
+    0xB0,0x8C,0xB0,0x8C,1,1,    //34  ک     -   223 
+    0x81,0x03,0x81,0x03,1,1,    //0  پ      -   234
+    0x8D,0x93,0x94,0x93,1,1,    //1  چ      -   235
+    0x8E,0x8E,0x8E,0x8E,1,0,    //2  ژ      -   238
+    0x90,0x01,0x90,0x01,1,1,    //3  گ      -   239
+    0x98,0x96,0x98,0x96,0,1,    //4  ئ      -   193
+    0x99,0x99,0x02,0x02,1,0,    //5  آ      -   194
+    0xC3,0xC3,0x01,0x01,1,0,    //6     -   195
+    0xC4,0xC4,0xC4,0xC4,0,0,    //7     -   196
+    0xC5,0xC5,0x03,0x03,1,0,    //8     -   197
+    0xC6,0xC6,0xC6,0xC6,0,0,    //9     -   198
+    0x9A,0x9A,0x00,0x00,1,0,    //10  ا     -   199
+    0x9B,0x04,0x9B,0x04,1,1,    //11  ب     -   200
+    0xC9,0xFE,0xE9,0x95,1,1,    //12    -   201
+    0x9C,0x05,0x9C,0x05,1,1,    //13  ت    -    202
+    0x9D,0x06,0x9D,0x06,1,1,    //14  ث     -   203
+    0x9E,0x07,0x08,0x07,1,1,    //15  ج     -   204
+    0x9F,0x09,0x0A,0x09,1,1,    //16  ح     -   205
+    0xA0,0x0B,0x0C,0x0B,1,1,    //17  خ     -   206
+    0xA1,0xA1,0xA1,0xA1,1,0,    //18  د     -   207
+    0xA2,0xA2,0xA2,0xA2,1,0,    //19  ذ     -   208
+    0xA3,0xA3,0xA3,0xA3,1,0,    //20  ر     -   209
+    0xA4,0xA4,0xA4,0xA4,1,0,    //21  ز     -   210
+    0xA5,0x8A,0xA5,0x8A,1,1,    //22  س     -   211
+    0xA6,0x0E,0xA6,0x0E,1,1,    //23  ش     -   212
+    0xA7,0x0F,0xA7,0x0F,1,1,    //24  ص     -   213
+    0xA8,0x1A,0xA8,0x1A,1,1,    //25  ض     -   214
+    0xD7,0xD7,0xD7,0xD7,0,0,    //26    -   215
+    0xA9,0xA9,0xA9,0xA9,1,1,    //27  ط     -   216
+    0xAA,0xAA,0xAA,0xAA,1,1,    //28  ظ     -   217
+    0xAB,0x1B,0x89,0x88,1,1,    //29  ع     -   218
+    0xAC,0x85,0x7F,0x84,1,1,    //30  غ     -   219
+    0xAD,0xAD,0xAD,0xAD,1,1,    //31  -     -   220
+    0xAE,0x80,0xAE,0x80,1,1,    //32  ف     -   221
+    0xAF,0x83,0xAF,0x83,1,1,    //33  ق     -   222
+    0xB0,0x8C,0xB0,0x8C,1,1,    //34  ک     -   223
+    0xE0,0xE0,0xE0,0xE0,0,0,    //35    -   224
+    0xB1,0x86,0xB1,0x86,1,1,    //36  ل     -   225
+    0xE2,0xE2,0xE2,0xE2,0,0,    //37    -   226
+    0xB2,0x82,0xB2,0x82,1,1,    //38  م     -   227
+    0xB3,0x87,0xB3,0x87,1,1,    //39  ن     -   228
+    0xB4,0x0D,0x8B,0x91,1,1,    //40  ه     -   229
+    0xB5,0xB5,0xB5,0xB5,1,0,    //41  و     -   230
+    0xE7,0xE7,0xE7,0xE7,0,0,    //42    -   231
+    0xE8,0xE8,0xE8,0xE8,0,0,    //43    -   232
+    0xE9,0xE9,0xE9,0xE9,0,0,    //44    -   233
+    0xFE,0xFE,0xFE,0xFE,0,0,    //45    -   254
+    0xFF,0xFF,0xFF,0xFF,0,0,    //46    -   255
+    0xEC,0xC0,0xA0,0xC0,1,1,    //47    -   236
+    0xB6,0x8F,0x92,0x8F,1,1     //48  ي     -   237
+
+};