Hi
There's a example to Detecting and handling NACK when not in FIFO moden:
/ Wait for "XRDY" flag to transmit data or "ARDY" if we get NACKed while ( !(*I2C_STR & (ICSTR_ICXRDY|ICSTR_ARDY)) ); // If a NACK occurred then SCL is held low and STP bit cleared if ( *I2C_STR & ICSTR_NACK ) { *I2C_MDR |= ICMDR_STP; // send STP to end transfer *I2C_STR = ICSTR_NACK; // clear NACK bit return I2C_FAIL; }
But,When in FIFO mode(,I2caRegs.I2CFFTX.all = 0x6000;I2caRegs.I2CFFRX.all = 0x2040;how to detecting and handling NACK through polling?
Thank