ADI TWI driver problems with device not connected

I have usually three devices connected on I2C bus but sometimes the last is not connected.

With this setup

ADI_DEV_CMD_VALUE_PAIR config[]={ // configuration table for the TWI driver
{ADI_TWI_CMD_SET_FIFO,(void *)0x0000},
{ADI_TWI_CMD_SET_RATE,(void *)(&rate)},
{ADI_TWI_CMD_SET_ANAK,(void *)1},
{ADI_TWI_CMD_SET_DNAK,(void *)0},

I am able to detect when the component is missing with the ADI_TWI_EVENT_ANAK event but subsequently i

am not able to read the device present and everything got in stuck.

Should I initialize again everything or is there a adi_dev_Control i can use to reset.

Best Regards

Parents Reply Children
No Data