HMC5883

If you can,you can post your i2cRead_Address function how to achieve,also the i2cWrite_Data function.
here is the change of the code:

[code] //must read all six registers plus one to move the pointer back to 0x03
i2cSendStart();
i2cWaitForComplete();
i2cRead_Address(0x3D); //read from HMC
i2cWaitForComplete();
i2cReceiveByte(TRUE);

delay_ms(500);

//i2cWaitForComplete();
xh = i2cRead_Data(); //x high byte
i2cWaitForComplete();
[/code]

and you can try the 0x3D and 0x3C both.This is depanding on the function of the i2CRead_Address();if in the function you are already set the read bit “bit 0” to ‘1’,then use the ox3C,if not use the 0x3D.