Need basic code to run a motor

Here is an example of how to use that hardware:
http://www.robot-electronics.co.uk/files/arduino_md25_i2c.ino

Note:

#define MD25ADDRESS         0x58                         // Address of the MD25
 Wire.beginTransmission(MD25ADDRESS);

Looks like you are using address 4 instead of 0x58.

To set the speed of motor1:

    Wire.beginTransmission(MD25ADDRESS);
    Wire.write(0);  // Motoe 1 speed register
    Wire.write(speed);
    Wire.endTransmission();