I was trying to replicate the stm32h747 Disco DCMI_Snapshot example. The code goes into overflow interrupt management.
Debug findings: During debug the value of isr_value was found to be 25 but when running my code the value is 26.
uint32_t isr_value = READ_REG(hdcmi->Instance->MISR);
/* Overflow interrupt management ********************************************/
if ((isr_value & DCMI_FLAG_OVRRI) == DCMI_FLAG_OVRRI)
{
/* Clear the Overflow flag */
__HAL_DCMI_CLEAR_FLAG(hdcmi, DCMI_FLAG_OVRRI);
/* Update error code */
hdcmi->ErrorCode |= HAL_DCMI_ERROR_OVR;
/* Change DCMI state */
hdcmi->State = HAL_DCMI_STATE_ERROR;
/* Set the overflow callback */
hdcmi->DMA_Handle->XferAbortCallback = DCMI_DMAError;
/* Abort the DMA Transfer */
(void)HAL_DMA_Abort_IT(hdcmi->DMA_Handle);
}
Tried toggling the interrupts in the ioc file, enabled all the interrupts and changed byte width(default set to byte).