DEFINE OSC 10
DEFINE LCD_DREG PORTA
DEFINE LCD_DBIT 0
DEFINE LCD_RSREG PORTB
DEFINE LCD_RSBIT 0
DEFINE LCD_EREG PORTB
DEFINE LCD_EBIT 1
DEFINE LCD_BITS 4
DEFINE LCD_LINES 2
DEFINE LCD_COMMANDUS 2000
DEFINE LCD_DATAUS 50

' DATA LINES ON PORTA.0 - 3 for DB4 to DB7
' 4 BIT MODE
' E PIN ON PORTB.1
' RS PIN ON PORTB.0
' TRIED COMMANDUS UP TO 5000 and DATAUS UP TO 255

ADCON1 = 7
TRISA = %00000000
TRISB = %00000000



Pause 5000 ' Wait for LCD to startup

loop: Lcdout $fe, 1 ' Clear LCD screen
Lcdout "Hello" ' Display Hello
Pause 2000 ' Wait 2 seconds

Lcdout $fe, 1 ' Clear LCD screen
Lcdout "World"
Pause 2000 ' Wait 2 seconds

Goto loop ' Do it forever


Picture to follow after camera batteries have finished charging.