diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2010-11-14 13:29:09 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2010-11-14 13:29:09 +0000 |
commit | 7ab0cff418bf49fcf1671dd72667b81a85c1ac37 (patch) | |
tree | 9527dc092b8fc59f733b2a0353d579ceec8a72ff /os/hal/platforms/STM32/pwm_lld.h | |
parent | bf8592688860a61181b3f5a4c9b6d4d8856b8abb (diff) | |
download | ChibiOS-7ab0cff418bf49fcf1671dd72667b81a85c1ac37.tar.gz ChibiOS-7ab0cff418bf49fcf1671dd72667b81a85c1ac37.tar.bz2 ChibiOS-7ab0cff418bf49fcf1671dd72667b81a85c1ac37.zip |
Improved STM32 HAL support.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2363 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms/STM32/pwm_lld.h')
-rw-r--r-- | os/hal/platforms/STM32/pwm_lld.h | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/os/hal/platforms/STM32/pwm_lld.h b/os/hal/platforms/STM32/pwm_lld.h index d8440e361..fcd66bbda 100644 --- a/os/hal/platforms/STM32/pwm_lld.h +++ b/os/hal/platforms/STM32/pwm_lld.h @@ -111,13 +111,24 @@ /* Configuration checks. */
/*===========================================================================*/
-#if STM32_PWM_USE_TIM4 && defined(STM32F10X_LD)
-#error "TIM4 not present in low density STM32 devices"
+#if STM32_PWM_USE_TIM1 && !STM32_HAS_TIM1
+#error "TIM1 not present in the selected device"
#endif
-#if !STM32_SERIAL_USE_USART1 && !STM32_SERIAL_USE_USART2 && \
- !STM32_SERIAL_USE_USART3 && !STM32_SERIAL_USE_UART4 && \
- !STM32_SERIAL_USE_UART5
+#if STM32_PWM_USE_TIM2 && !STM32_HAS_TIM2
+#error "TIM2 not present in the selected device"
+#endif
+
+#if STM32_PWM_USE_TIM3 && !STM32_HAS_TIM3
+#error "TIM3 not present in the selected device"
+#endif
+
+#if STM32_PWM_USE_TIM4 && !STM32_HAS_TIM4
+#error "TIM4 not present in the selected device"
+#endif
+
+#if !STM32_PWM_USE_TIM1 && !STM32_PWM_USE_TIM2 && \
+ !STM32_PWM_USE_TIM3 && !STM32_PWM_USE_TIM4
#error "PWM driver activated but no TIM peripheral assigned"
#endif
|