Closed
Description
Why i2c/wire library does not have any timeout fuses? Its known issue froam a years and still no solutions.
Its my 4th project where endTransmission or requestFrom hang my avr.
probably hanging code:
while(TWI_READY != twi_state){
continue;
}
or
while(TWI_MRX == twi_state){
continue;
}
or
while(TWI_READY != twi_state){
continue;
}
or
while(wait && (TWI_MTX == twi_state)){
continue;
}
or
while(TWCR & _BV(TWSTO)){
continue;
}
In worst case I should receive error or corrupted data so I can repeat operation. Haging whole avr beacuse some random noise on I2C line or damaged I2C device (in some situations) is not acceptet in my opinion. And as I said, many peoples complains on that form a years and still no solutions.