Here the initialization code i've used:
void initWiiCam(void)
{
u08 buf[16];
u08 p0,p1,p2,p3;
// Setup IR Sensivity
// p0=0x72; p1=0x20; p2=0x1F; p3=0x03; // Sensitivity 1
p0=0xC8; p1=0x36; p2=0x35; p3=0x03; // 2
// p0=0xAA; p1=0x64; p2=0x63; p3=0x03; // 3
// p0=0x96; p1=0xB4; p2=0xB3; p3=0x04; // 4
// p0=0x96; p1=0xFE; p3=0xFE; p3=0x05; // 5
buf[0]=0x30; buf[1]=0x01; // ??
i2cMasterSend(TARGET_ADDR, 2, buf);//if (== I2C_ERROR_NODEV)
buf[0]=0x00; buf[1]=0x02; buf[2]=0x00; buf[3]=0x00; buf[4]=0x71; buf[5]=0x01; buf[6]=0x00; buf[7]=p0;
i2cMasterSend(TARGET_ADDR, 8, buf);
timerPause(100);
buf[0]=0x07; buf[1]=0x00; buf[2]=p1;
i2cMasterSend(TARGET_ADDR, 3, buf);
timerPause(100);
buf[0]=0x1A; buf[1]=p2; buf[2]=p3;
i2cMasterSend(TARGET_ADDR, 3, buf);
timerPause(100);
buf[0]=0x33; buf[1]=0x03;
i2cMasterSend(TARGET_ADDR, 2, buf);
timerPause(100);
buf[0]=0x30; buf[1]=0x08; // ??
i2cMasterSend(TARGET_ADDR, 2, buf);
}
If you have to work with Slave Registers try to use buf[0] as Register Address and buf[1]... as Data Bytes.(I think you have done this already)
did you wait a view ms between the initialization steps?
If there is no point recognized by the cam all 12 Bytes received are 0xFF. If there's a Point the first 3 Bytes change.
Without initialization i get random values too. I think this results from a much to high sensitivity. I try to find some time next week to check out the data format.