??? 03/16/04 02:49 Read: times |
#66802 - Graphic LCD issue |
I am using a 128 x 64 graphic LCD module with the KS0108 driver (same as HD61202).
I have mostly used this for text and recently tried to convert BMP images for display on to it and ran into this problem : I am unable to display 0x00 when fetched from a table located in the code area. It displays as 0xff. All other values display properly. The relevant code snippet is here : ;Routine to draw converted BMP images. BMPDATA1 table contains pixel data suitable for KS0108 driver. BMP_IMAG: mov dptr, #BMPDATA1-1 clr Select mov r3, #0b8h ; First page NexPage: mov a, r3 ; pre-load page counter call Write_Instr mov a, #040h ; First column.. call Write_Instr mov r4, #0 ; Sub- column counter mov r6, #0 ; Total column counter PageLup: inc dptr mov a, #00H movc a, @a+dptr ; acc with table data call Write_Data call Sel_CS2 ; check if left half is over.. inc r6 cjne r6, #128, PageLup ; end of page check clr Select inc r3 cjne r3, #0c0h, NexPage ; one page over ImgOver: ret ; all 8 pages over Sel_CS2: inc r4 ; To switch to CS2 cjne r4, #40h, NoCS2 setb Select ; change to right half. mov a, r3 call Write_Instr mov a, #040h call Write_Instr NoCS2: ret Just to check I have tried to run the code by eliminating the "movc a, @a+dptr" line. As expected the display is cleared as all writes are with 0x00 values. So I am unable to comprehend as to what goes wrong when I fetch the 0x00 value from the table. (it produces the display equivalent of 0xff ) Thanks for any enlightenment. Raghu |
Topic | Author | Date |
Graphic LCD issue | 01/01/70 00:00 | |
RE: Graphic LCD issue | 01/01/70 00:00 | |
RE: Graphic LCD issue | 01/01/70 00:00 | |
RE: Graphic LCD issue - Michael & Pravin | 01/01/70 00:00 | |
RE: Graphic LCD issue - Michael & Pravin | 01/01/70 00:00 | |
Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
RE: Yes_Its FlashMagic | 01/01/70 00:00 | |
Problem Solved - Michael Karas | 01/01/70 00:00 | |
RE: Problem Solved - Michael Karas | 01/01/70 00:00 | |
RE: Problem Solved - Michael Karas![]() | 01/01/70 00:00 |