2012-01-17 08:30 AM
I'm using the standard periphery library for this board. The DMA is working correctly in combination with DAC (memory to peripheral transfer) but I can't get the cpu to execute the interrupt handler for DMA1_Stream5 (transfer complete interrupt):
void DMA1_Stream5_IRQHandler(void) { DMA_ClearITPendingBit(DMA1_Stream5, DMA_FLAG_TCIF5); STM_EVAL_LEDToggle(LED3); } In main.c DMA interrupt is enabled using the stm32f4xx_dma.c function: DMA_ITConfig(DMA1_Stream5, DMA_IT_TC, ENABLE); Other interrupts work fine. EDIT: with DMA_GetITStatus(DMA1_Stream5, DMA_IT_TCIF5) I can see that the interrupt has occurred, but the interrupt handler is not executed.2012-01-24 03:40 AM
I just needed to enable the DMA1_Stream5 gloabal Interrupt:
NVIC_InitTypeDef NVIC_InitStructure; NVIC_InitStructure.NVIC_IRQChannel = DMA1_Stream5_IRQn; NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 0; NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1; NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE; NVIC_Init(&NVIC_InitStructure);