KS0108 Graphic LCD specific Declares.
Declare LCD_DTPort = Port Assign the port that will output the 8-bit data to the graphic LCD.
If the Declare is not used, then the default port is PORTB.
Declare LCD_RWPin = Port.Pin Assigns the Port and Pin that the graphic LCD's RW line will attach to.
If the Declare is not used in the program, then the default Port and Pin is PORTC.0.
Declare LCD_CS1Pin = Port.Pin Assigns the Port and Pin that the graphic LCD's CS1 line will attach to.
If the Declare is not used in the program, then the default Port and Pin is PORTC.0.
Declare LCD_CS2Pin = Port.Pin Assigns the Port and Pin that the graphic LCD's CS2 line will attach to.
If the Declare is not used in the program, then the default Port and Pin is PORTC.0.
Declare Internal_Font = On - Off, 1 or 0 The graphic LCD's that are compatible with compiler’s built-in library routines are non-intelligent types, therefore, a separate character set is required. This may be in one of two places, either externally, in an I2C EEPROM, or internally in a Cdata table.
If an external font is chosen, the I2C EEPROM must be connected to the specified SDA and SCL pins (as dictated by Declare SDA_Pin and Declare SCL_Pin).
If an internal font is chosen, it must be on a PICmicro™ device that has self modifying code features, such as the 16F87X, or 18F range.
The Cdata table that contains the font must have a label, named Font_Table: preceding it. For example: -
Font_Table: Cdata $7E, $11, $11, $11, $7E, $0,_ ' Chr "A"
$7F, $49, $49, $49, $36, $0 ' Chr "B"
{ rest of font table }
The font table may be anywhere in memory, however, it is best placed after the main program code.
If the Declare is omitted from the program, then an external font is the default setting.
Declare Font_Addr = 0 to 7 Set the slave address for the I2C EEPROM that contains the font.
When an external source for the font is chosen, it may be on any one of 8 eeproms attached to the I2C bus. So as not to interfere with any other eeproms attached, the slave address of the EEPROM carrying the font code may be chosen.
If the Declare is omitted from the program, then address 0 is the default slave address of the font EEPROM.
Declare GLCD_CS_Invert = On - Off, 1 or 0 Some graphic LCD types have inverters on their CS lines. Which means that the LCD displays left hand data on the right side, and vice-versa. The GLCD_CS_Invert Declare, adjusts the library LCD handling library subroutines to take this into account.
Declare GLCD_Strobe_Delay = 0 to 65535 us (microseconds). Create a delay of n microseconds between strobing the EN line of the graphic LCD. This can help noisy, or badly decoupled circuits overcome random bits appearing on the LCD. The default if the Declare is not used in the BASIC program is a delay of 0.

