Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Graphic LCD 128x64 help needed

Status
Not open for further replies.

maria258

Member level 2
Joined
Feb 10, 2011
Messages
42
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Activity points
1,577
I want to interface this graphic lcd that has a KS0108 controller with PIC16f877. Can anyone help me with some basic steps to get a satisfied result pls?

All help will be greatly appreciated.

Thanks
Maria
 

bigdogguru

Administrator
Joined
Mar 12, 2010
Messages
9,831
Helped
2,349
Reputation
4,692
Reaction score
2,275
Trophy points
1,413
Location
Southwest, USA
Activity points
62,380
There are plenty of libs out there for PIC24s, PIC32 or dsPIC which all have PMP.

I found two projects which uses PIC18 with a lib and source:

gLCD pong

Glcd

Upgrading your PIC to a 16-bit would make this quite a bit easier.

Hope this gives you some pointers.
 

Attachments

  • en023491.pdf
    1 MB · Views: 102
Last edited:

maria258

Member level 2
Joined
Feb 10, 2011
Messages
42
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Activity points
1,577
there is no information on that website you gave
 

bigdogguru

Administrator
Joined
Mar 12, 2010
Messages
9,831
Helped
2,349
Reputation
4,692
Reaction score
2,275
Trophy points
1,413
Location
Southwest, USA
Activity points
62,380
Check the bottom of the page for the source code for the lib. I have also add another blog which discusses in more depth the interface and also has source code for a lib on the second page.
 

anandpv2009

Advanced Member level 1
Joined
Aug 11, 2009
Messages
407
Helped
60
Reputation
120
Reaction score
40
Trophy points
1,308
Activity points
3,341
Upgrading your PIC to a 16-bit would make this quite a bit easier.

Hope this gives you some pointers.

Links that you posted are maybe useful to maria258 but How a 16bit controller make his job easy??? !!!

maria258 is talking about KS0108 based LCDs not about PIC LCD controllers.

PMP is not an essential for ks0108 based LCD. :-D
 

maria258

Member level 2
Joined
Feb 10, 2011
Messages
42
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Activity points
1,577
do you have any suggestions anandpv2009?
thanks
 

bigdogguru

Administrator
Joined
Mar 12, 2010
Messages
9,831
Helped
2,349
Reputation
4,692
Reaction score
2,275
Trophy points
1,413
Location
Southwest, USA
Activity points
62,380
Please do not put words in my mouth. No it's not essential and that's not what I said. There are numerous PMP based libs and examples using PIC24, dsPIC and PIC32 available for KS0108, therefore easier to adapt one of these to their needs. There are very few libs and examples using an PIC16 or PIC18.
 

tinto

Junior Member level 2
Joined
Mar 23, 2011
Messages
21
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
Kerala, India
Activity points
1,413
You will find library functions in mikroC for this Graphical LCD screen with KS0108 processor. There is an example program also in it. It has the follwing library routines:
Glcd_Iint
Glcd_Set_Side
Glcd_Set_X
Glcd_set_page
Glcd_Read_data
Glcd_Write_Data

It also has advanced routines for drwing lines, rectangles, circles, images etc.
 

maria258

Member level 2
Joined
Feb 10, 2011
Messages
42
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Activity points
1,577
I am using MPLAB son mikroC will not be good. but ill have a look at it.
 

bigdogguru

Administrator
Joined
Mar 12, 2010
Messages
9,831
Helped
2,349
Reputation
4,692
Reaction score
2,275
Trophy points
1,413
Location
Southwest, USA
Activity points
62,380
Here's another project and source lib specifically for PIC 16F and the KS0108:



It has been written for PICC Lite (Hi-Tech) which I believe MicroChip now owns.

By the way, if your using MPLAB what compiler are you using?
 

anandpv2009

Advanced Member level 1
Joined
Aug 11, 2009
Messages
407
Helped
60
Reputation
120
Reaction score
40
Trophy points
1,308
Activity points
3,341
Please do not put words in my mouth. No it's not essential and that's not what I said. There are numerous PMP based libs and examples using PIC24, dsPIC and PIC32 available for KS0108, therefore easier to adapt one of these to their needs. There are very few libs and examples using an PIC16 or PIC18.

but the PDF that you uploaded is irrelevant, that doc is about PIC LCD controllers. And also you can't use PIC32 or PIC24 controllers directly with these GLCDs because of the voltage level problems. 5v is required for these GLCDs. RAM read is essential to draw a line on the LCD, ie 5V to the controller (all ports are not 5v tolerant).RAM write is not a problem because 3.3v is enough.

I am using MPLAB son mikroC will not be good. but ill have a look at it.

Use CCS compiler. You can use its inbuilt library for KS0108 controller based GLCDs. If you need a ks0108 library for C18/C30 i can give you one (My own).

Good Luck.
 

maria258

Member level 2
Joined
Feb 10, 2011
Messages
42
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Activity points
1,577
if you can give it to me i would be very grateful to you.
thanks
ps: where is the location where i can put this library?
 

anandpv2009

Advanced Member level 1
Joined
Aug 11, 2009
Messages
407
Helped
60
Reputation
120
Reaction score
40
Trophy points
1,308
Activity points
3,341
am repeating my opinion, use ccs compiler it has an inbuilt library because the library is for c18/c30/c32 (PIC18F,PIC24,dsPIC30,dsPIC30,PIC32 controllers)compilers only.

if you can give it to me i would be very grateful to you.
thanks
ps: where is the location where i can put this library?

Sample program.
Code:
#include <HDM64GS12.c>
#include <graphics.c>

and in main

glcd_init(ON); 
glcd_line(10,10,40,40,ON); //This will draw a line on the screen.....
 

bianchi77

Advanced Member level 4
Joined
Jun 11, 2009
Messages
1,313
Helped
21
Reputation
44
Reaction score
20
Trophy points
1,318
Location
California
Activity points
9,442
I want to interface this graphic lcd that has a KS0108 controller with PIC16f877. Can anyone help me with some basic steps to get a satisfied result pls?

All help will be greatly appreciated.

Thanks
Maria

You need to init the LCD first, read from KS0108 datasheet,

For example :
Code:
void GDispInit(void)
{
	GDispBackLite(ENABLE);
	GDispReset();
	GDispSwitch(DISABLE);
	GDispWr(CMD,DISPLAY_START_LINE);//set display start line at the top of the LCD
	GDispClr(0x00);					//clear the display
	GDispSwitch(ENABLE);
}
 

Attachments

  • ks0108.pdf
    119.6 KB · Views: 41

luong.nv1610

Newbie level 3
Joined
Dec 25, 2010
Messages
3
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,299
Dear Friends,
I'm doing with graphic LCD 128*64, i use PIC C30 and Mplab,
i need library for C30,
could you help me?
 

bianchi77

Advanced Member level 4
Joined
Jun 11, 2009
Messages
1,313
Helped
21
Reputation
44
Reaction score
20
Trophy points
1,318
Location
California
Activity points
9,442
you must init the display first....for example :
Code:
void GDispInit(void)
{
	GDispBackLite(ENABLE);
	GDispReset();
	GDispSwitch(DISABLE);
	GDispWr(CMD,DISPLAY_START_LINE);//set display start line at the top of the LCD
	GDispClr(0x00);					//clear the display
	GDispSwitch(ENABLE);
}
 

DR.boy

Junior Member level 1
Joined
Mar 8, 2013
Messages
16
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,362
Hey Maria
i recommend you to use CCS c compiler , it has very good drivers for this KS0107/0108 controller . its easy to use and you can draw graphs , show pics (bitmap ones ..etc
i worked on a project last year and i used that GLCD .
you can use that drivers with Pic16f as well . IMAG0192.jpg
IMAG0217.jpg
IMAG0219.jpg
those are some pics of that project
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top