Hello ALIARIF93, unfortunately I don't use MPLAB C18 and therefore I can't help you. Normal in the modules that communicate via I2C, is to see the command sequence in the datasheet for the device, and transfer this information to the programming language you are using. Anyway, for someone else can help, you would post the site where to find the datasheet of the IMU module you are using, because it appears many different IMU modules searching in Google.
Greetings!