aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/uart_lld.h
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-08-08 07:57:28 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-08-08 07:57:28 +0000
commita2cfd2054ad5da4dbf8b583a7eaf164d9dac6006 (patch)
treefcc2f570a92b65a714b7ca3b38ab700918aeb816 /os/hal/platforms/STM32/uart_lld.h
parentbb27a7d32a5b35a41f6e736540a689fd30d0854c (diff)
downloadChibiOS-a2cfd2054ad5da4dbf8b583a7eaf164d9dac6006.tar.gz
ChibiOS-a2cfd2054ad5da4dbf8b583a7eaf164d9dac6006.tar.bz2
ChibiOS-a2cfd2054ad5da4dbf8b583a7eaf164d9dac6006.zip
Fixed bug 3041414. Various improvements to the STM32 HAL.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2119 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms/STM32/uart_lld.h')
-rw-r--r--os/hal/platforms/STM32/uart_lld.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/os/hal/platforms/STM32/uart_lld.h b/os/hal/platforms/STM32/uart_lld.h
index 1e294e212..e0d0851d6 100644
--- a/os/hal/platforms/STM32/uart_lld.h
+++ b/os/hal/platforms/STM32/uart_lld.h
@@ -146,6 +146,16 @@
/* Derived constants and error checks. */
/*===========================================================================*/
+#if STM32_UART_USE_UART4 && \
+ !(defined(STM32F10X_HD) || defined(STM32F10X_CL))
+#error "UART4 only present in HD and CL devices"
+#endif
+
+#if !STM32_UART_USE_USART1 && !STM32_UART_USE_USART2 && \
+ !STM32_UART_USE_USART3 && !STM32_UART_USE_UART4
+#error "UART driver activated but no USART/UART peripheral assigned"
+#endif
+
/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/