Hello,I am using I2C on S32K148. IDE is S32DS ARM2.2(version:1.0.0.202001161613)
The flow is:
(1) start a I2C transder by calling LPI2C_DRV_MasterSendDataBlocking, which is using DMA.
(2) transfer time out
(3) call: LPI2C_DRV_MasterAbortTransferData
(4) call: LPI2C_DRV_MasterDeinit
(5) the I2C dma transfer error interrupt(EDMA_DRV_ErrorIRQHandler) occured, and drop into the DEV_ASSERT for no available I2C instance.
Why did this happened? And how can I avoid this?
Hi @wengzhaojie,
Please refer to the documentation of the driver.
The blocking transfer is completed when the function returns (with error or success status), there is nothing to abort.
LPI2C_DRV_MasterAbortTransferData() can be used for non-blocking transfers.
Regards,
Daniel