Hi Team,
Good day. I am posting this inquiry on behalf of the customer.
I am using CC1312 Launchpad and trying to interface it with the OV7670 camera. I would need help with the coding part.
I have written the code, but I am having trouble interfacing it with CC1312.
It works fine with MSP430.
void ov7670_set(uint8_t addr, uint8_t val)
{
i2c_start();
i2c_write8(OV7670_ADDR);
i2c_write8(addr);
i2c_write8(val);
i2c_stop();
}
uint8_t ov7670_get(uint8_t addr)
{
uint8_t retval;
i2c_start();
i2c_write8(OV7670_ADDR);
i2c_write8(addr);
i2c_stop();
__delay_cycles(16 * 1000);
i2c_start();
i2c_write8(OV7670_ADDR + 1);
retval = i2c_read8(0xFF);
i2c_stop();
return retval;
}
Please help to advise. Thank you for extending your support.
Kind regards,
Marvin