View previous topic :: View next topic |
Author |
Message |
Boatdrinks Guest
|
Noritake VFD Trouble... |
Posted: Thu May 19, 2005 7:33 pm |
|
|
Does anyone have expierence with the Noritake 24x2 character VFD? I am having trouble initializing the unit i have. I am using the standard LCD init code provided in the lcd.c file. I keep getting garbled characters on the screen. If anyone has had any luck with this, i could use a little help.
thanks,
Boatdrinks
printf(lcd_putc,"\f");
printf(lcd_putc,"hello world");
or
lcd_putc("hello world");
don't seem to make a difference |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu May 19, 2005 8:14 pm |
|
|
Quote: |
I am having trouble initializing the unit i have. I am using the standard
LCD init code provided in the lcd.c file. I keep getting garbled characters
on the screen. |
I did a project several years that used one of the 16x2 Noritake units.
To make it work, I had to modify the CCS driver as shown below in bold.
void lcd_init() {
BYTE i;
set_tris_lcd(LCD_WRITE);
lcd.rs = 0;
lcd.rw = 0;
lcd.enable = 0;
delay_ms(15);
for(i=1;i<=3;++i) {
lcd_send_nibble(3);
delay_ms(5);
}
lcd_send_nibble(2);
delay_ms(5); // ADD THIS LINE.
for(i=0;i<=3;++i)
{
lcd_send_byte(0,LCD_INIT_STRING[i]);
delay_ms(5); // ADD THIS LINE AND THE BRACES.
}
}
//====================
void lcd_send_byte( BYTE address, BYTE n ) {
lcd.rs = 0;
delay_us(10); // ADD THIS LINE
while ( bit_test(lcd_read_byte(),7) ) ;
lcd.rs = address;
delay_cycles(1);
lcd.rw = 0;
delay_cycles(1);
lcd.enable = 0;
lcd_send_nibble(n >> 4);
lcd_send_nibble(n & 0xf);
} |
|
|
Mark
Joined: 07 Sep 2003 Posts: 2838 Location: Atlanta, GA
|
|
Posted: Thu May 19, 2005 8:30 pm |
|
|
I haven't used a 24X2 but about 7 years ago I tried the 20X4 display. The row offsets were different between the VFD and the standard 20X4 LCD displays. That was about all I had to change but my driver wasn't the CCS one but one I wrote from reading the datasheet. |
|
|
|