pic24fj128ga010 input capture
The LCD controller data sheets have a specification for initialization, obviously your keeping neither the timing specification (required delays) nor the recommended method to set the interface reliably to 8-bit mode (sending 0x38 three times).
There may be other errors, too, but I suggest to correct these points first.
When using a full us interface, it's more effective to check the busy flag rather than using long delays required for some instructions, I think.