Re: GUI for LCD



On Aug 9, 1:38 pm, "Tom Lucas"
<news@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
"Ajab" <jasusvi...@xxxxxxxxx> wrote in message

news:1186634638.484580.306260@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

What steps do I need to follow to develope a GUI for LCD?
Are there any specific tools which you would recommend?

You can buy a number of graphics libraries off the shelf. I use Segger's
emwin and I am very pleased with it but I've heard other people get on
well with C/PEG and C/PEG++. This is not cheap though. I remember there
was also someone on this group a year or so ago who was developing a
cut-down open source GUI - you'd have to check the archives.

To write one yourself then your biggest hurdle will be getting the LCD
controller to function correctly - creating images is secondary to that.
Some microcontroller vendors (Sharp for one although soon to be NXP)
have software tools that will create C header files to initialise your
LCD controller to suit your panel.

Once you can drive the LCD then you just need a few simple functions
that will populate the frame buffer in the right way. You can go a long
way toward a good GUI with simple functions like ClearScreen, DrawPoint,
DrawLine, DrawBox, DrawCircle etc.

If you want predrawn pictures then bitmaps are easiest to work with and
RLE encoding them can compress them if you are short of space. There are
a number of programs available that will convert a bitmap file to a C
file for inclusion in your project - bmp2c is one I believe is free. I
use the one that came with emwin and it is very good but certainly not
free. A function like DrawBitmap is not too tricky to implement and is
mainly just setting the colour of the frame buffer pixels in sequence. A
bit harder if you use compression.

So with these tools (emwin/PEG..), I will develope the GUI
(images,dialogs etc., which will be displayed on LCD). And then I need
to write some event handler routines for each button/image.
Whatever code will be written will be flashed into the microcontroller
and then microcontroller will control the display. Is it this way?

.