AnsweredAssumed Answered

i2c slave无法进入中断

Question asked by yangzj208@qq.com on Mar 10, 2020
Latest reply on Mar 19, 2020 by Daniel Martynek

运行s32ds中的例子:lpi2c_slave_s32k144,无法进入中断,请问这个例子是否有问题,如何修改,谢谢!

波形如下,ACK已发出,SSR寄存器已有中断标记,但是中断处理函数没有被调用,以致数据没发出

配置如下:

lpi2c_slave_user_config_t lpi2c1_SlaveConfig0 = {
.slaveAddress = 104U,
.is10bitAddr = false,
.slaveListening = true,
.operatingMode = LPI2C_STANDARD_MODE,
.transferType = LPI2C_USING_INTERRUPTS,
.dmaChannel = 0U,
.slaveCallback = lpi2c1_SlaveCallback0,
.callbackParam = NULL,
};

lpi2c1_SlaveConfig0.callbackParam = (uint32_t *)INST_LPI2C1;

LPI2C_DRV_SlaveInit(INST_LPI2C1, &lpi2c1_SlaveConfig0, &lpi2c1SlaveState);

 

Outcomes