Hi Pommie:
Pretty much played with everything, changing oscillators, using internal vs external. Attached is a pic of your project running on Proteus with the defines changed to make it compatible with the EP4 development board. As you can see it works fine on Proteus but just won't work on a breadboard or the EP4.
Second pic is what is displayed when the pic is first programmed, as you can see there is problems in the display. Turning off/on the board's power and then nothing will display.
I know the display is fine because I can get it to work on a breadboard or EP4 with Richard.C assembler code for the KS0108
Have tried debugging with my PK2 and still can not get anything to display, or see where the problem is. Perhaps I am missing a config setting by using the 18f4520 instead of 18f4550.
My define's
#include <p18f4520.h>
#define GLCD_Data PORTD
#define b_GLCD_GCS1 LATBbits.LATB1
#define b_GLCD_GCS2 LATBbits.LATB0
#define b_GLCD_RS LATBbits.LATB2
#define b_GLCD_RW LATBbits.LATB3
#define b_GLCD_E LATBbits.LATB4
#define b_GLCD_ON LATBbits.LATB5
#define b_GLCD_BL LATBbits.LATB6
#define TRIS_Data TRISD
#define b_TRIS_GCS1 TRISBbits.TRISB1 //GCS1
#define b_TRIS_GCS2 TRISBbits.TRISB0 //GCS2
#define b_TRIS_RS TRISBbits.TRISB2 //RS
#define b_TRIS_RW TRISBbits.TRISB3 //RW
#define b_TRIS_E TRISBbits.TRISB4 //E
#define b_TRIS_ON TRISBbits.TRISB5 //RST
#define b_TRIS_BL TRISBbits.TRISB6 //backlight
Pretty much played with everything, changing oscillators, using internal vs external. Attached is a pic of your project running on Proteus with the defines changed to make it compatible with the EP4 development board. As you can see it works fine on Proteus but just won't work on a breadboard or the EP4.
Second pic is what is displayed when the pic is first programmed, as you can see there is problems in the display. Turning off/on the board's power and then nothing will display.
I know the display is fine because I can get it to work on a breadboard or EP4 with Richard.C assembler code for the KS0108
Have tried debugging with my PK2 and still can not get anything to display, or see where the problem is. Perhaps I am missing a config setting by using the 18f4520 instead of 18f4550.
My define's
#include <p18f4520.h>
#define GLCD_Data PORTD
#define b_GLCD_GCS1 LATBbits.LATB1
#define b_GLCD_GCS2 LATBbits.LATB0
#define b_GLCD_RS LATBbits.LATB2
#define b_GLCD_RW LATBbits.LATB3
#define b_GLCD_E LATBbits.LATB4
#define b_GLCD_ON LATBbits.LATB5
#define b_GLCD_BL LATBbits.LATB6
#define TRIS_Data TRISD
#define b_TRIS_GCS1 TRISBbits.TRISB1 //GCS1
#define b_TRIS_GCS2 TRISBbits.TRISB0 //GCS2
#define b_TRIS_RS TRISBbits.TRISB2 //RS
#define b_TRIS_RW TRISBbits.TRISB3 //RW
#define b_TRIS_E TRISBbits.TRISB4 //E
#define b_TRIS_ON TRISBbits.TRISB5 //RST
#define b_TRIS_BL TRISBbits.TRISB6 //backlight