Hello DS.4
A similar issue has been reported on GitHub for HAL_I2C_Mem_Read_DMA.
If you are encountering the same issue, you can adjust the priority of DMA and I2C interrupts by setting the DMA interrupt priority higher than the I2C interrupt priority. Here is an example of how you can configure the interrupt priorities.
/* NVIC configuration for DMA transfer complete interrupt (I2C1_TX) */
HAL_NVIC_SetPriority(I2Cx_DMA_TX_IRQn, 0, 0);
HAL_NVIC_EnableIRQ(I2Cx_DMA_TX_IRQn);
/* NVIC for I2Cx */
HAL_NVIC_SetPriority(I2Cx_ER_IRQn, 1, 0);
HAL_NVIC_EnableIRQ(I2Cx_ER_IRQn);
HAL_NVIC_SetPriority(I2Cx_EV_IRQn, 2, 0);
HAL_NVIC_EnableIRQ(I2Cx_EV_IRQn);
If your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Omar
In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Saket_Om