Part Number:CC3200MODLAUNCHXL
Tool/software: Code Composer Studio
Hello,
With the websock camera application we cant run trough the I2CBufferWrite in the i2cconfig file .
The first while loop the program runs through, but the seccond while loop in the for loop the program stays in this while loop. See below the code of this while loop and the whole code of the I2CBufferWrite in the i2cconfig file.
We are using the CC3200MODLAUNCHXL with a MT9D111 camera without a camera boosterpack. We have used the CC3200SDK_1.3.0 to get the software example.
while((MAP_I2CMasterIntStatusEx(I2CA0_BASE, false) & I2C_INT_MASTER) == 0)
unsigned long I2CBufferWrite(unsigned char ucDevAddr, unsigned char *ucBuffer, unsigned long ulSize,unsigned char ucFlags) { unsigned long ulNdx; Message("\t line 204: 12cbufferwrite :i2cconfig \n\r"); // Set I2C codec slave address MAP_I2CMasterSlaveAddrSet(I2CA0_BASE,ucDevAddr, false); // Write the first byte to the controller. MAP_I2CMasterDataPut(I2CA0_BASE,ucBuffer[0]); MAP_I2CMasterIntClearEx(I2CA0_BASE, I2C_INT_MASTER); if( ulSize == 1) { MAP_I2CMasterControl(I2CA0_BASE, I2C_MASTER_CMD_SINGLE_SEND); } else { // Continue the transfer. MAP_I2CMasterControl(I2CA0_BASE, I2C_MASTER_CMD_BURST_SEND_START); // Wait until the current byte has been transferred. while((MAP_I2CMasterIntStatusEx(I2CA0_BASE, false) & I2C_INT_MASTER) == 0) { } for(ulNdx=1; ulNdx < ulSize-1; ulNdx++) { // Write the next byte to the controller. MAP_I2CMasterDataPut(I2CA0_BASE,ucBuffer[ulNdx]); // Clear Master Interrupt MAP_I2CMasterIntClearEx(I2CA0_BASE, I2C_INT_MASTER); // Continue the transfer. MAP_I2CMasterControl(I2CA0_BASE, I2C_MASTER_CMD_BURST_SEND_CONT); // Wait until the current byte has been transferred. int abcd=0; while((MAP_I2CMasterIntStatusEx(I2CA0_BASE, true) & I2C_INT_MASTER) == 0) { } } // Write the last byte to the controller. MAP_I2CMasterDataPut(I2CA0_BASE, ucBuffer[ulSize-1]); MAP_I2CMasterIntClearEx(I2CA0_BASE, I2C_INT_MASTER); // End the transfer. MAP_I2CMasterControl(I2CA0_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH); } // Wait until the current byte has been transferred. while((MAP_I2CMasterIntStatusEx(I2CA0_BASE, false) & I2C_INT_MASTER) == 0) { } return 0; }