Searching \ for 'Handling large tables for LCD display' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page:
Search entire site for: 'Handling large tables for LCD display'.

Truncated match.
PICList Thread
'Handling large tables for LCD display'
1999\05\04@111922 by Quentin

Hi Picsters
I am currently working on a project which display lots of text messages
and data on a LCD display.
I have about 20 text messages of up too 32 characters each to display.
Some messages will also incorporate variable data (readouts).
I use a 16C74 and 16x2 LCD and write in ASM.
Currently, I got all the messages in tables in page 1 of the memory and
use the standard PCLATH and CALL etc. method of calling them up when
The variable data I am going to read from register files using indirect
addressing. Still working on this.
As it is now, it works but I find using it and calling the tables very
tedious and the coding gets a bit long at stages. Also, the tables hogs
a lot of memory space.

Anybody got a easier or better way to handle many and long messages for
LCD display?


1999\05\04@113152 by Wagner Lipnharski

picon face
yup, use an external serial e2prom 24C256 (32k bytes), with all the
messages stored on it.
All you have to do is just address the message, retrieve it serially and
send to the LCD.
Easy, clean and cheap.


Quentin wrote:
{Quote hidden}

Wagner Lipnharski - UST Research Inc. - Orlando, Florida
Forum and microcontroller web site:
Microcontrollers Survey:

1999\05\04@122439 by Craig Lee

Terminate the strings with the \0 character and you only need the starting
address.  Then make a table of defined strings ie.

HELLO is the pointer to the string "Hello\0"  HELLO is only one byte, and
makes your code readable vs. 2 bytes per displayable character using in
16CXX type tables; A big mess vs:

movf LINE1,w    ;move cursor
call lcd_goto   ;to home

movf HELLO,w    ;display
call disp_str   ;hello string

call gets_i2c   ;get and
call lcd_puts   ;display

... and so on

Has anyone built a cheap easy serial memory programmer I can use with MPLAB?
It would sure be nice to dump a hex file out to memory device using ICSP.


> {Original Message removed}

1999\05\04@203053 by Eric Oliver

Hi Quentin,

To continue from Wagner's response, I'll tell you what I plan to do ( I
have the same problem ).  I already have a fairly large NVRAM as part of my
circuit, so it is not as big a deal for me.

I thought I would reserve a block of memory in the lower address space of
the RAM for text messages. Each text message will be allocated the same
amount of space ( wasteful, but simple .. also, I've got RAM to waste ).
Each text message will be terminated by a trailing zero. In your program,
you will need the base address plus an error number. Pseudo C code follows
(sorry,  don't speak ASM very well):

#define TEXTMSG1        0
#define TEXTMSG2        1
#define TEXTMSGN        N

#define baseAddress 0x00                        // Base memory address in RAM
#define msgSize 30                      // Number of chars in each message

void DisplayMessage( int msg )
long addr  = baseAddr + ( msg * msgSize );              // Requires 16 bit math
int l;
char c = 1;
int row = 1;
int col = 1;

for ( int l = 0; l < msgSize && c != 0; l++ )
       c = ReadRAM( addr + l );                                // Read a byte f
rom RAM

       // If c == 0, end of string
       if ( c != 0 )
       WriteCharToLCD( row, col, c );                  // Write to LCD

       // Handles wrap around
       if ( col > MAX_COL )
               col = 1;


int main()
       DisplayMessage( TEXTMSG1 );
       DisplayMessage( TEXTMSG2 );

       return 0;

{Original Message removed}

More... (looser matching)
- Last day of these posts
- In 1999 , 2000 only
- Today
- New search...