MCU: S32K144
SDK: RTM3.0.0
project software environment: bare-metal
Questions:
We use both lpi2c and flexio_i2c in one system to communication different devices, but there may be some mistakes for flexio_i2c. We do some investcation for this issue, the result is flexio i2c communication is less robust than lpi2c.
So several test cases is made to find what make flexio so disturb sensitivity.
Case1:
Use flexio_i2c to communication with EEPROM, set the priority of FLEXIO_IRQn to 2, lower than Lpurat1,2 and system tick timer, and equel to flexcan.
we write data to EEPROM other read them to verify wether write process succeed. Totally test 35000, but 120 failed.
when we add log in flexio isr(FLEXIO_I2C_DRV_MasterCheckStatus()), it turned out both tx_shifter and rx_shifter error occurs when EEPROM write failed.
Case2:
Set the priority of FLEXIO_IRQn to highest in whole system, then do the some test above, Totally test 10000, only failed once.
Case3:
Use ipi2c do the same thing as case1, and set the priority of lpi2c master irq to 4(the lowest of whole software system), Totally test 6000, failed None!
It is too late to do any hardware changes at this moment for the project, so could you give some adivce for this issue.