AnsweredAssumed Answered

interrupt based i2c transfer not working in i2c_17xx_40xx.c

Question asked by Micha Simon Spies on Feb 16, 2018
Latest reply on Jun 14, 2018 by Kerry Zhou

/* Chip event handler interrupt based */
void Chip_I2C_EventHandler(I2C_ID_T id, I2C_EVENT_T event)
    struct i2c_interface *iic = &i2c[id];
    volatile I2C_STATUS_T *stat;


    /* Only WAIT event needs to be handled */
    if (event != I2C_EVENT_WAIT) {


    stat = &iic->mXfer->status;
    /* Wait for the status to change */
    while (*stat == I2C_STATUS_BUSY) {}


I need help with the i2c routine's from the lpc_chip_175x_6x. The transfer's are sucessfull but the program wait's in the routine till the transfer is done... The means not interrupt based i think.

When I comment out the while loop it becomes a hard fault.