On 11/7/2011 3:11 PM, Jean-Paul wrote: > The 44780 driver has a RS (register select) line that tells whether the byte > (or nibble) is a command or a data (0 = commands, 1 = data). Commands control > the internal working of the chip, data are to be written in (or read from) > data memory and displayed as characters. > > Your "lcd_command" looks like writing into internal registers > ("PORTB=cmd;//j;") and sending an E (enable) pulse. (By the way, 0.1s is a > very very looong duration for such a pulse.) > You should find somewhere a "lcd_data()" function to write data (something > like "PORTB=data;...), as I suppose that your PORTB drives the RS, R/W and E > lines of the display. > > Now the "lcd_command()" function will be used to set up the display (cursor, > blinking, character definition etc. (which seems to have been done in your > programme)), then "lcd_data()" will actually write on the screen.
I think you are completely missing the point. None of the above is an issue. Jason knows what he's doing, and it's not a 0.1s delay. IIRC, Jason got single char calls working, but the loop output does not work. I can't see anything wrong with the rest of the code. Might need to check the assembly version of puts_lcd(). -- Cheers, Kein-Hong Man (esq.) Kuala Lumpur, Malaysia ------------------------------------------------------------------------------ RSA(R) Conference 2012 Save $700 by Nov 18 Register now http://p.sf.net/sfu/rsa-sfdev2dev1 _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user