LCDproc development and user support list

Text archives Help


[Lcdproc] Noritake Itron VFD display on FT245R (ftdi)


Chronological Thread 
  • From: han.hartgers AT gmail.com (Han Hartgers)
  • Subject: [Lcdproc] Noritake Itron VFD display on FT245R (ftdi)
  • Date: Sun Jun 29 09:12:01 2008

Dear Thomas,

I had time today to solve my problems with the initialisation of my VFD.

The problems seems to be that my VFD does not like the second nibble
during the switch from the 8bit mode to the 4bit mode after a reset.

In the original code was the configuration implemented with the 3x times:
ftdi_HD44780_senddata (p, 0, RS_INSTR, FUNCSET | IF_4BIT );

I do now this;
// first I write 0 to the screen
buf[0] = 0x00;
buf[1] = 0x00 | p->ftdi_line_EN;
buf[2] = 0x00;
// next is the 4 bit mode command
buf[3] = ((ch>>4) & 0x0F) | p->ftdi_line_EN;
buf[4] = ((ch>>4) & 0x0F) ;
f = ftdi_write_data(&p->ftdic, &buf, 5);
if (f < 0) {
p->hd44780_functions->drv_report(RPT_ERR, "failed to write: %d
(%s). Exiting",
f,
ftdi_get_error_string(&p->ftdic));
exit(-1);
}
usleep(4100);

Not so elegant, but it does work.

My LCD works also with this code.
I will try if it continues to works on both my PC's and with a couple
of displays before I make a patch of this change.

How should I send in a patch?

By the way it could also be nice to use a FT232R instead of the
FT245R. That chip can also be put into a bitbang parallel mode, butthe
4 cbus pins would give an option to add keys display. (I do not really
need that functionality for my project)

Greetings,

Han




Archive powered by MHonArc 2.6.18.

Top of page