2024-08-09 05:06 AM
Hello !
I am using DMA with pwm and working on unipolar SPWM.
i have configured DMA with an array of pwm and is working fine. i am trying to get the interrupt after either each DMA transfer or after the reload of ARR register. According to the documentation i tried using function
void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef *htim) {
if (htim->Instance == TIM1 && htim->Channel == HAL_TIM_ACTIVE_CHANNEL_1) {
HAL_TIM_PWM_Stop(&htim1, TIM_CHANNEL_1);
}
}
but it doesnt seems working.
I doubt i couldnt configure proper interrupt for it. here is the NVIC setting
Any guidance please...