for Arduino TFT LCD Screen 160x128
Dependents: TFTLCDSCREEN Pong_ILI9163C
Fork of TFT_ILI9163C by
README.md@0:f90a4405ef98, 2015-01-21 (annotated)
- Committer:
- peu605
- Date:
- Wed Jan 21 14:32:07 2015 +0000
- Revision:
- 0:f90a4405ef98
- Child:
- 10:1ebc27775d92
initial
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
peu605 | 0:f90a4405ef98 | 1 | TFT_ILI9163C |
peu605 | 0:f90a4405ef98 | 2 | |
peu605 | 0:f90a4405ef98 | 3 | ILI9163C- A fast SPI driver for TFT that use Ilitek ILI9163C. |
peu605 | 0:f90a4405ef98 | 4 | |
peu605 | 0:f90a4405ef98 | 5 | ![ILI9163C](http://i1189.photobucket.com/albums/z437/theamra/github/CIMG6810.jpg) |
peu605 | 0:f90a4405ef98 | 6 | |
peu605 | 0:f90a4405ef98 | 7 | Link to a video: |
peu605 | 0:f90a4405ef98 | 8 | |
peu605 | 0:f90a4405ef98 | 9 | https://www.youtube.com/watch?v=y5f-VNBxgEk&feature=youtu.be |
peu605 | 0:f90a4405ef98 | 10 | |
peu605 | 0:f90a4405ef98 | 11 | ========================== |
peu605 | 0:f90a4405ef98 | 12 | |
peu605 | 0:f90a4405ef98 | 13 | Features: |
peu605 | 0:f90a4405ef98 | 14 | |
peu605 | 0:f90a4405ef98 | 15 | - Very FAST!, expecially with Teensy 3.x where uses DMA SPI. |
peu605 | 0:f90a4405ef98 | 16 | - It uses just 4 or 5 wires. |
peu605 | 0:f90a4405ef98 | 17 | - Compatible at command level with Adafruit display series so it's easy to adapt existing code. |
peu605 | 0:f90a4405ef98 | 18 | - It uses the standard Adafruit_GFX Library (you need to install). |
peu605 | 0:f90a4405ef98 | 19 | |
peu605 | 0:f90a4405ef98 | 20 | |
peu605 | 0:f90a4405ef98 | 21 | Pay Attention to connections!!!!: |
peu605 | 0:f90a4405ef98 | 22 | |
peu605 | 0:f90a4405ef98 | 23 | - This display has logic at 3V3 volt so YOU NEED A VOLTAGE CONVERTER if you plan to use with arduino. |
peu605 | 0:f90a4405ef98 | 24 | If you try to connect directly you can burn it very fast so PAY ATTENTION! |
peu605 | 0:f90a4405ef98 | 25 | - My display works at 3V3 volt for logic but LED background has resistor for 5V. Your can be different |
peu605 | 0:f90a4405ef98 | 26 | so carefully check out before connect it. |
peu605 | 0:f90a4405ef98 | 27 | - My library works only in SPI mode by using MOSI,SCLK and a CS pin plus an additional pin for DC (or RS). |
peu605 | 0:f90a4405ef98 | 28 | I've used also the reset pin but you can save it by connect it at 3V3 volt and use the constructor without |
peu605 | 0:f90a4405ef98 | 29 | the reset pin. The initialization routine will automatically use the software reset. |
peu605 | 0:f90a4405ef98 | 30 | - People using Teensy3 should remember that have to choose for CS and DC a pin that satisfy: |
peu605 | 0:f90a4405ef98 | 31 | |
peu605 | 0:f90a4405ef98 | 32 | if (pin == 2 || pin == 6 || pin == 9) return true; |
peu605 | 0:f90a4405ef98 | 33 | if (pin == 10 || pin == 15) return true; |
peu605 | 0:f90a4405ef98 | 34 | if (pin >= 20 && pin <= 23) return true; |
peu605 | 0:f90a4405ef98 | 35 | |
peu605 | 0:f90a4405ef98 | 36 | |
peu605 | 0:f90a4405ef98 | 37 | Background: |
peu605 | 0:f90a4405ef98 | 38 | |
peu605 | 0:f90a4405ef98 | 39 | I got one of those displays from a chinese ebay seller but unfortunatly I cannot get |
peu605 | 0:f90a4405ef98 | 40 | any working library so I decided to hack it. ILI9163C looks pretty similar to other |
peu605 | 0:f90a4405ef98 | 41 | display driver but it uses it's own commands so it's tricky to work with it unlsess you |
peu605 | 0:f90a4405ef98 | 42 | carefully fight with his gigantic and not so clever datasheet. |
peu605 | 0:f90a4405ef98 | 43 | My display it's a 1.44"", 128x128 that suppose to substitute Nokia 5110 LCD and here's the |
peu605 | 0:f90a4405ef98 | 44 | first confusion! Many sellers claim that it's compatible with Nokia 5110 (that use a philips |
peu605 | 0:f90a4405ef98 | 45 | controller) but the only similarity it's the pin names since that this one it's color and |
peu605 | 0:f90a4405ef98 | 46 | have totally different controller that's not compatible. Altrough I discovered that it's not |
peu605 | 0:f90a4405ef98 | 47 | 128x128 but 128x160 (!??)... Check links below to see if it's similar to yours. |
peu605 | 0:f90a4405ef98 | 48 | |
peu605 | 0:f90a4405ef98 | 49 | http://www.ebay.com/itm/Replace-Nokia-5110-LCD-1-44-Red-Serial-128X128-SPI-Color-TFT-LCD-Display-Module-/141196897388 |
peu605 | 0:f90a4405ef98 | 50 | |
peu605 | 0:f90a4405ef98 | 51 | http://www.elecrow.com/144-128x-128-tft-lcd-with-spi-interface-p-855.html |
peu605 | 0:f90a4405ef98 | 52 | |
peu605 | 0:f90a4405ef98 | 53 | Pay attention that ILI9163C can drive different resolutions and your display can be |
peu605 | 0:f90a4405ef98 | 54 | 160*128 or whatever, also there's a strain of this display with a black PCB that a friend of mine |
peu605 | 0:f90a4405ef98 | 55 | got some weeks ago and need some small changes in library to get working. |
peu605 | 0:f90a4405ef98 | 56 | If you look at TFT_ILI9163C.h file you can add your modifications and let me know so I |
peu605 | 0:f90a4405ef98 | 57 | can include for future versions. |
peu605 | 0:f90a4405ef98 | 58 | |
peu605 | 0:f90a4405ef98 | 59 | Code Optimizations: |
peu605 | 0:f90a4405ef98 | 60 | |
peu605 | 0:f90a4405ef98 | 61 | The purpose of this library it's SPEED. I have tried to use hardware optimized calls |
peu605 | 0:f90a4405ef98 | 62 | where was possible and results are quite good for most applications. |
peu605 | 0:f90a4405ef98 | 63 | Of course it can be improved so feel free to add suggestions. |
peu605 | 0:f90a4405ef98 | 64 | ------------------------------------------------------------------------------- |
peu605 | 0:f90a4405ef98 | 65 | Copyright (c) 2014, .S.U.M.O.T.O.Y., coded by Max MC Costa. |
peu605 | 0:f90a4405ef98 | 66 | |
peu605 | 0:f90a4405ef98 | 67 | TFT_ILI9163C Library is free software: you can redistribute it and/or modify |
peu605 | 0:f90a4405ef98 | 68 | it under the terms of the GNU General Public License as published by |
peu605 | 0:f90a4405ef98 | 69 | the Free Software Foundation, either version 3 of the License, or |
peu605 | 0:f90a4405ef98 | 70 | (at your option) any later version. |
peu605 | 0:f90a4405ef98 | 71 | |
peu605 | 0:f90a4405ef98 | 72 | TFT_ILI9163C Library is distributed in the hope that it will be useful, |
peu605 | 0:f90a4405ef98 | 73 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
peu605 | 0:f90a4405ef98 | 74 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
peu605 | 0:f90a4405ef98 | 75 | GNU General Public License for more details. |
peu605 | 0:f90a4405ef98 | 76 | |
peu605 | 0:f90a4405ef98 | 77 | You should have received a copy of the GNU General Public License |
peu605 | 0:f90a4405ef98 | 78 | along with Foobar. If not, see <http://www.gnu.org/licenses/>. |
peu605 | 0:f90a4405ef98 | 79 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
peu605 | 0:f90a4405ef98 | 80 | |
peu605 | 0:f90a4405ef98 | 81 | This file needs the following Libraries: |
peu605 | 0:f90a4405ef98 | 82 | |
peu605 | 0:f90a4405ef98 | 83 | *Adafruit_GFX by Adafruit: |
peu605 | 0:f90a4405ef98 | 84 | |
peu605 | 0:f90a4405ef98 | 85 | https://github.com/adafruit/Adafruit-GFX-Library |
peu605 | 0:f90a4405ef98 | 86 | |
peu605 | 0:f90a4405ef98 | 87 | Remember to update GFX library often to have more features with this library! |
peu605 | 0:f90a4405ef98 | 88 | |
peu605 | 0:f90a4405ef98 | 89 | *From this version I'm using my version of Adafruit_GFX library: |
peu605 | 0:f90a4405ef98 | 90 | |
peu605 | 0:f90a4405ef98 | 91 | https://github.com/sumotoy/Adafruit-GFX-Library |
peu605 | 0:f90a4405ef98 | 92 | |
peu605 | 0:f90a4405ef98 | 93 | It has faster char rendering and some small little optimizations but you can |
peu605 | 0:f90a4405ef98 | 94 | choose one of the two freely since are both fully compatible. |
peu605 | 0:f90a4405ef98 | 95 | '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' |
peu605 | 0:f90a4405ef98 | 96 | |
peu605 | 0:f90a4405ef98 | 97 | Special Thanks: |
peu605 | 0:f90a4405ef98 | 98 | |
peu605 | 0:f90a4405ef98 | 99 | Thanks Adafruit for his Adafruit_GFX! |
peu605 | 0:f90a4405ef98 | 100 | Thanks to Paul Stoffregen for his beautiful Teensy3 and DMA SPI. |
peu605 | 0:f90a4405ef98 | 101 | |
peu605 | 0:f90a4405ef98 | 102 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
peu605 | 0:f90a4405ef98 | 103 | |
peu605 | 0:f90a4405ef98 | 104 | Version: |
peu605 | 0:f90a4405ef98 | 105 | |
peu605 | 0:f90a4405ef98 | 106 | 0.1a1: First release, compile correctly. Altrough not fully working! |
peu605 | 0:f90a4405ef98 | 107 | 0.1a3: Some bugfix, still some addressing problems, partial rotation solved. |
peu605 | 0:f90a4405ef98 | 108 | 0.1b1: Beta version! Fully working but still not tested with Arduino and DUE (altrough it compile) |
peu605 | 0:f90a4405ef98 | 109 | 0.2b2: Code cleaned and added support for 2.2" RED PCB displays. |
peu605 | 0:f90a4405ef98 | 110 | 0.2b4: Bug fixes and added color space support. |
peu605 | 0:f90a4405ef98 | 111 | +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
peu605 | 0:f90a4405ef98 | 112 | |
peu605 | 0:f90a4405ef98 | 113 | BugList of the current version: |
peu605 | 0:f90a4405ef98 | 114 | |
peu605 | 0:f90a4405ef98 | 115 | - Beta version fully working! |
peu605 | 0:f90a4405ef98 | 116 |