Home arrow Support arrow Forums

Luminary Micro Forums

<< Start < Prev 1 2 Next > End >>

jrmymllr

Platinum Boarder

2008/09/25 19:09

Unrelated LCD question

I'm hoping someone has some knowledge on this. I have a SED1330 based 256x128 graphic LCD and would like to display more than 32 characters per line, using the built in character generator.

It appears that normally the text box is 8 pixels wide, but the characters are only 5, meaning that there's an awful lot of space between characters. I can change the text box width and successfully display them, but I can't seem to get more than 32 characters per line. I've tried changing registers that seem like they might fix my problem, but they either do nothing or make the display do weird things.

Anyone have experience with this? I'd really like to use the built in character generator rather than drawing them in graphics mode.

login or register to reply

cb1

Platinum Boarder

2008/09/25 20:28

Re:Unrelated LCD question

SED1330/35:

The 1330 style Graphic Controller operates with byte "coarseness" - meaning one 5 bit wide text character image is stored in 1 byte of the 1330's frame buffer. Thus what you report is "normal" - and IS unattractive and wasteful of screen pixels.

Think about it for a second - "if" a 5 bit wide font was placed into just 6 pixels - you would at some point encounter 1 text row intruding into "2" adjacent screen bytes. And this demands a "read-modify-write" - which was never implemented w/in the 1330 class.

As you surmised - the cure is create your own character images - AND to enter them into the frame buffer via a "read-modify-write" method. Further - you have to do this across all 7 rows for a 5x7 character matrix - you will probably want larger characters and the effort will grow exponentially.

And there's more - the 1330's main task is to regularly, repetitively "unroll" its external sram frame buffer. This is how your Lcd screen gets "painted." Now if you come along with multiple, extensive reads or writes you fall victim to another 1330 class weakness, "collision detection" was not considered or was not implemented. Extensive reads/writes will cause the screen to exhibit "noise" at best - to become torn & distorted at worst.

My firm has developed methods/techniques to "cure" this - and to run hi pixel-count color TFTs with NO noise/disruption...

login or register to reply

cb1

Platinum Boarder

2008/09/26 05:08

Re:Unrelated LCD question

for others interested in 1330/35:

There IS a simple-minded solution to the "byte coarseness" of the 1330 IC. Simply rotate the Lcd through 90 degrees!
This enables "pixel, vertical stripes."

Now you can create 4, 5 or even variable width characters - without the complexity, code-bloat imposed by read-modify-write.

Of course a 128x256 will yield just 21 such characters - this explains why QVGA (320x240) has long "buried" lesser Lcds. Rotating a QVGA will yield 240/6=40 characters - and without the wasteful/ugly extra spaces.

You will certainly want larger fonts - this rotation eases that effort as well. Just be sure to "confine" your characters w/in 8 (or 8n) vertical pixels. (n=1,2,3,4 etc.) (otherwise you will have to r-m-w vertically)

A "proper" QVGA Lcd will look much better and greatly simplify your sw development.

Post edited by: cb1, at: 2008/09/26 05:11

login or register to reply

jrmymllr

Platinum Boarder

2008/09/27 19:03

Re:Unrelated LCD question

Thanks for clearing this up. I think I'm going to start writing a routine to write characters to the display using a font table.

login or register to reply

cb1

Platinum Boarder

2008/09/27 21:14

Re:Unrelated LCD question

Hope I was clear enough that a font table alone will not solve your desire for 40 chars/row.

login or register to reply

jrmymllr

Platinum Boarder

2008/09/29 05:37

Re:Unrelated LCD question

I don't see why I can't get 40 char/row using a font table. I'm writing to the display in graphics mode, so as long as it physically fits, it'll be possible. The font I'm using is 6 across/8 high, so that's about 42/row (I believe there's at least one empty column of pixels on each character for space).

login or register to reply
<< Start < Prev 1 2 Next > End >>