AnsweredAssumed Answered

Clearing I2C bus hung condition with MQX drivers

Question asked by pmt on May 18, 2015
Latest reply on May 20, 2015 by pmt

I don't see anywhere in the MQX I2C driver or documentation about handling a bus hung condition. 

 

Sometimes after power up, my first operation:

 

// Set bit rate to 400K
param = 400000;
ret = ioctl(fd, IO_IOCTL_I2C_SET_BAUD, &param);

 

returns I2C_ERROR_DEVICE_BUSY

 

But I am the only bus master, so I suspect the bus needs to be clocked until it is released by whatever slave device is keeping it.  Is there a proper methodology to do this within the context of the MQX driver (i.e. not banging on the low level I2C registers)?

 

Thanks,

PMT

Outcomes