The problem with using a microcontroller to drive an LCD is that an LCD requires constant attention. This can be mitigated with a CPLD driven over SPI (using DMA, of course), but then you run into the other problem: Color LCDs require a lot of data. 320x240 in black and white is marginal at 9.6KB, but make it 24 bit color and suddenly you need to deliver 230KB of data in 1/60th of a second. (Don't forget, though, that you can get 4-bit, 16-color control just by tieing the low 20 bits to one setting). A 24-bit frame buffer no longer fits in onboard RAM on most microcontrollers, and you probably don't have time to read from an external RAM chip, clock the data out, and still do other processing. Trying to do this with a CPLD (or an FPGA) and a RAM chip gets you well over the $2 price that caused you to balk in your question.
The traditional solution to interfacing a microcontroller with a color LCD is a display controller like an SSD1963. Here's a very simple block diagram:
Parallel input to a big RAM frame buffer (Translation: More than $2) interfaced with a register-configurable parallel LCD interface. The parallel input is usually compatible with a memory bus interface.
The color LCD market is not always easy to find on the web, usually being the domain of OEMs only, with the rest buying displays from companies who integrate the controller with the display. The best resource I've found has been Crystal Fontz, specifically this page on choosing graphic LCDs. Scroll to the bottom for the controllers, which include the following options (note: Not all are color controllers):
- Epson S1D13521B01 E Ink Broadsheet (1 module)
- Epson S1D13700 (11 modules)
- Epson SED1520 Compatible (8 modules)
- Himax HX8345 Compatible (1 module)
- ILITek ILI9325 Compatible (3 modules)
- KS0107/KS0108 Compatible (26 modules)
- Novatek NT7534 (14 modules)
- Orise Technology OTM2201A (1 module)
- Orise Technology SPFD5420A (1 module)
- RAiO RA8835 (1 module)
- Sanyo LC7981 (13 modules)
- Sino Wealth SH1101A (2 modules)
- Sitronix ST7920 (29 modules)
- Solomon SSD1303 (1 module)
- Solomon SSD1305 (9 modules)
- Solomon SSD1325 (2 modules)
- Solomon SSD1332 (1 module)
- Solomon SSD2119 (2 modules)
- ST STV8105 (1 module)
- Toshiba T6963 (23 modules)
Ok, I'd comment to you but now I try to answer to your question.
At first, Which compiler(or IDE) is better? keil or LPCxpresso?
It completely depends on your job and yourself. Well there are many features for each one of them. for LPCxpresso:
- Complete C/C++ integrated development environment
- Eclipse-based IDE with many ease-of-use enhancements
- The IDE can be further enhanced with many Eclipse plugins
- CVS source control built in; Git, Subversion, TFS, and others are
available for download
- Command-line tools included for integration into build, test, and
manufacturing systems
- Industry-standard GNU toolchain, including
- C and C++ compilers, assembler, and linker
- Converters for SREC, HEX, and binary
- Fully featured debugger supporting JTAG and SWD
- Built-in flash programming
- High-level and instruction-level debug
- Views of CPU registers and on-chip peripherals
- Support for multiple devices on JTAG scan-chain
- Library support
- Redlib: a small-footprint embedded C library
- Newlib: a complete C and C++ library
- Cortex Microcontroller Software Interface Standard (CMSIS) libraries
and source code
- Full support for LPCOpen libraries
- Device-specific support for NXP's ARM-based MCUs (including
Cortex-M, ARM7, and ARM9 based parts)
- Linker scripts automatically generated for correct placement of code
and data into flash and RAM
- Startup code and device initialization provided
- No assembler required with Cortex-M based MCUs
- Red Trace
- Red Trace enables instruction-level debugging via Embedded Trace
Buffer (ETB) or Micro Trace Buffer (MTB)
- Red State state machine designer and code generator
- Graphically design your state machines
- Generates standard C code
- Configures NXP State Configurable Timer (SCT) as well as supporting
software state machines
for Keil:
- Feature The µVision Device Database automatically configures the development tools for the target microcontroller .:Benefit:. Mistakes in tool settings are practically eliminated and tool configuration time is minimized.
- Feature The µVision IDE integrates additional third-party tools like VCS, CASE, and FLASH/Device Programming .:Benefit:. This allows you to quickly access all your development tools (development tools and third-party tools) from a single environment. All configuration details are saved in the µVision project.
- Feature µVision incorporates project manager, editor, and debugger in a single environment .:Benefit:. Accelerates application development. While editing, you may configure debugger features. While debugging, you may make source code modifications.
- Feature Identical Target Debugger and Simulator User Interface .:Benefit:. Shortens your learning curve.
- Feature The Code Coverage feature of the µVision Simulator provides statistical analysis of your program's execution .:Benefit:. Safety-critical systems can be thoroughly tested and validated. Execution analysis reports can be viewed and printed for certification requirements.
- Feature The µVision Simulator is the only debugger that completely simulates all on-chip peripherals of the Atmel, Philips, and Samsung smart card ARM devices .:Benefit:. This allows you to write and test application code before production hardware is available. You may investigate different hardware configurations to optimize the hardware design.
- Feature Simulation capabilities may be expanded using the Advanced Simulation Interface (AGSI) .:Benefit:. Your sophisticated systems can be accurately simulated by adding your own peripheral drivers.
Also you can see the µVision Simulator Benefits here.
If you ask me about selecting the compiler, I want to choose the Keil because this company has a bigger and older experience in designing and making the IDEs and compilers and also I can see some disadvantages for LPCxpresso. for example seems it doesn't support non-NXP products (ST and TI and freescale and etc) and you cannot find many consultant and expert for speaking with them to figure out your problems. on the other hand, if you just want to use the NXP products then I think the LPCxpresso is better than the Keil.
NXP has many examples of code, all of which have full drivers and everything. Normally that'd be awesome, although I want to write my own drivers since I want to know exactly what is going on with as little overhead as possible.
Why!? don't waste your time, Shannon! there are many HAL(Hardware Abstraction Layer (standard peripheral library)) that you can have a look at those and know exactly what is going on with as little overhead as possible. for example: the HAL library of company of your MCU or CMSIS or MBED.org lib and or etc.
a recommendation for choosing compiler:
if you have enough money, you can buy IAR(IAR Embedded Workbench for ARM) from IAR Systems. I have heared that it's the best compiler but you have to have enough skill for working with it.
I hope this will help you. if you still have any question, then ask in comment and if my knowledge is enough, I will answer you.
refrence:
Keil Wikipage
Advantages of the µVision IDE for ARM
Advantages of the µVision Simulator for ARM
LPCXpresso home
Mbed
Best Answer
You should be able to do this with GCC, either in the form of an ARM-maintained version or Yagarto. I believe all the normal STL is available; most of it is in the form of templates rather than libraries, anyway. You may need to sort out a platform definition and get
malloc()/new
working, depending on your exact platform.