cancel
Showing results for 
Search instead for 
Did you mean: 

Read I2C on interrupt with DMA

JBond.1
Senior

Hi, I am trying to read I2C on interrupt (HAL_GPIO_EXTI_Callback) using HAL_I2C_Mem_Read_DMA function. How ever I get into HardFault_Handler. I suspect its because HAL_I2C_Mem_Read_DMA function uses HAL_GetTick() which causes crash?

Is there any way around this?

1 REPLY 1
TDK
Guru

Include your chip number, there are thousands of different chips.

Find an example in the repository that uses HAL_I2C_Mem_Read_DMA and follow that.

HAL_GetTick is probably not causing the crash.

Within the HardFault_Handler, find out why things are crashing by looking at relevant SCB registers.

If you feel a post has answered your question, please click "Accept as Solution".