From 86e02ab475c5b278cb730012b6528738b0c6c6ee Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Mon, 17 Oct 2016 09:55:31 +0000 Subject: Fixed some timer-related definitions in the STM32F0 registry. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9864 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/ports/STM32/STM32F0xx/stm32_registry.h | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'os/hal') diff --git a/os/hal/ports/STM32/STM32F0xx/stm32_registry.h b/os/hal/ports/STM32/STM32F0xx/stm32_registry.h index eeb26b96d..8a2d3f111 100644 --- a/os/hal/ports/STM32/STM32F0xx/stm32_registry.h +++ b/os/hal/ports/STM32/STM32F0xx/stm32_registry.h @@ -197,30 +197,45 @@ #define STM32_TIM3_IS_32BITS FALSE #define STM32_TIM3_CHANNELS 4 +#if defined(STM32F030x8) || defined(STM32F030xC) #define STM32_HAS_TIM6 TRUE #define STM32_TIM6_IS_32BITS FALSE #define STM32_TIM6_CHANNELS 0 +#else +#define STM32_HAS_TIM6 FALSE +#endif + +#if defined(STM32F030xC) +#define STM32_HAS_TIM7 TRUE +#define STM32_TIM7_IS_32BITS FALSE +#define STM32_TIM7_CHANNELS 0 +#else +#define STM32_HAS_TIM7 FALSE +#endif #define STM32_HAS_TIM14 TRUE #define STM32_TIM14_IS_32BITS FALSE #define STM32_TIM14_CHANNELS 1 +#if defined(STM32F030x8) || defined(STM32F030xC) #define STM32_HAS_TIM15 TRUE #define STM32_TIM15_IS_32BITS FALSE #define STM32_TIM15_CHANNELS 2 +#else +#define STM32_HAS_TIM15 FALSE +#endif #define STM32_HAS_TIM16 TRUE #define STM32_TIM16_IS_32BITS FALSE -#define STM32_TIM16_CHANNELS 2 +#define STM32_TIM16_CHANNELS 1 #define STM32_HAS_TIM17 TRUE #define STM32_TIM17_IS_32BITS FALSE -#define STM32_TIM17_CHANNELS 2 +#define STM32_TIM17_CHANNELS 1 #define STM32_HAS_TIM2 FALSE #define STM32_HAS_TIM4 FALSE #define STM32_HAS_TIM5 FALSE -#define STM32_HAS_TIM7 FALSE #define STM32_HAS_TIM8 FALSE #define STM32_HAS_TIM9 FALSE #define STM32_HAS_TIM10 FALSE -- cgit v1.2.3