Fix for missing characters - Newhaven NHD-0216K3Z I2C 2 x 16 display

I have used several Newhaven displays on various Arduino projects. The 2 wire interface and the Wire library let you get results very quickly. I like a display for debugging if for no other reason. The current project display messages were missing something like to every other character. I tried shortening the wires and everything else I could think of or find in the forum to no avail. The display is supposed to handle a 100KHz clock but I became suspicious this one could not. After some thrashing I went into the Wire library and modified twi.c

TWBR = ((F_CPU / TWI_FREQ) - 16) / 2; TWBR = TWBR * 2; // added 2014-03-03 to reduce LCD clock rate

The upper statement is original. The lower I added to cut the clock rate in half. It fixed the problem. Maybe it might help somebody else.

I was experiencing the same behavior with NHD-0216K3Z in i2c mode.

Your patch did the trick, thanks !