Skip to content

Conversation

@ghost
Copy link

@ghost ghost commented Sep 25, 2017

Fix issue #111

@ghost ghost requested a review from fpistm September 25, 2017 13:15
* @param None
* @retval None
*/
#if defined(STM32F0xx)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use TIM1_IRQHandler and define the proper one like the other (#define TIM1_IRQHandler TIM1_BRK_UP_TRG_COM_IRQHandler ...) in timer.h
in order to be homogeneous?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried but when timer 10 or 16 are present, there is an error about redefinition:
'error: redefinition of 'TIM1_UP_TIM16_IRQHandler'

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On which MCU ?

however, for TIM10 handler, it seems strange for STM32F1xx

+#elif defined(STM32F2xx) || defined(STM32F4xx) || defined(STM32F7xx)
 void TIM1_UP_TIM10_IRQHandler(void)

but

+#if defined(STM32F1xx) || defined(STM32F2xx) || defined(STM32F4xx) || defined(STM32F7xx)
   if(timer_handles[9] != NULL) {
     HAL_TIM_IRQHandler(timer_handles[9]);

HAL_TIM_IRQHandler(timer_handles[0]);
}

#if defined(STM32F1xx) || defined(STM32F2xx) || defined(STM32F4xx) || defined(STM32F7xx)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So this one could be removed as handle by TIM10_IRQHandler

}
#endif

#if defined(STM32F1xx) || defined(STM32F3xx) || defined(STM32L4xx)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So this one could be removed as handle by TIM16_IRQHandler

@ghost ghost requested a review from fpistm September 26, 2017 09:57
@fpistm fpistm merged commit 5f5b063 into stm32duino:master Sep 26, 2017
@ghost ghost deleted the issue_111 branch October 6, 2017 10:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant