From 572c554931e811bd0d32e41cbf99ea1ca46148b7 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Sun, 3 Dec 2017 08:19:59 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@11113 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- .../multi/UART/cfg-stm32f091_nucleo64/halconf.h | 2 +- .../multi/UART/cfg-stm32f091_nucleo64/portab.c | 23 ++++++++++++++++++++++ .../multi/UART/cfg-stm32f303_discovery/halconf.h | 2 +- .../multi/UART/cfg-stm32f303_discovery/portab.c | 23 ++++++++++++++++++++++ .../multi/UART/cfg-stm32f407_discovery/halconf.h | 2 +- .../multi/UART/cfg-stm32f407_discovery/mcuconf.h | 12 +++++------ .../multi/UART/cfg-stm32f407_discovery/portab.c | 21 ++++++++++++++++++++ 7 files changed, 76 insertions(+), 9 deletions(-) diff --git a/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/halconf.h b/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/halconf.h index a4095ba96..a7f25ffab 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/halconf.h +++ b/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/halconf.h @@ -389,7 +389,7 @@ * @note Disabling this option saves both code and data space. */ #if !defined(UART_USE_WAIT) || defined(__DOXYGEN__) -#define UART_USE_WAIT FALSE +#define UART_USE_WAIT TRUE #endif /** diff --git a/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/portab.c b/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/portab.c index 1d42746d2..6c400ab4c 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/portab.c +++ b/testhal/STM32/multi/UART/cfg-stm32f091_nucleo64/portab.c @@ -34,6 +34,29 @@ /* Module exported variables. */ /*===========================================================================*/ +void txend1(UARTDriver *uartp); +void txend2(UARTDriver *uartp); +void rxend(UARTDriver *uartp); +void rxchar(UARTDriver *uartp, uint16_t c); +void rxerr(UARTDriver *uartp, uartflags_t e); + +/* + * UART driver configuration structure. + */ +UARTConfig uart_cfg_1 = { + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + 0, + 38400, + 0, + USART_CR2_LINEN, + 0 +}; + /*===========================================================================*/ /* Module local types. */ /*===========================================================================*/ diff --git a/testhal/STM32/multi/UART/cfg-stm32f303_discovery/halconf.h b/testhal/STM32/multi/UART/cfg-stm32f303_discovery/halconf.h index a4095ba96..a7f25ffab 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f303_discovery/halconf.h +++ b/testhal/STM32/multi/UART/cfg-stm32f303_discovery/halconf.h @@ -389,7 +389,7 @@ * @note Disabling this option saves both code and data space. */ #if !defined(UART_USE_WAIT) || defined(__DOXYGEN__) -#define UART_USE_WAIT FALSE +#define UART_USE_WAIT TRUE #endif /** diff --git a/testhal/STM32/multi/UART/cfg-stm32f303_discovery/portab.c b/testhal/STM32/multi/UART/cfg-stm32f303_discovery/portab.c index 4c54b2835..593439eb9 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f303_discovery/portab.c +++ b/testhal/STM32/multi/UART/cfg-stm32f303_discovery/portab.c @@ -33,6 +33,29 @@ /* Module exported variables. */ /*===========================================================================*/ +void txend1(UARTDriver *uartp); +void txend2(UARTDriver *uartp); +void rxend(UARTDriver *uartp); +void rxchar(UARTDriver *uartp, uint16_t c); +void rxerr(UARTDriver *uartp, uartflags_t e); + +/* + * UART driver configuration structure. + */ +UARTConfig uart_cfg_1 = { + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + 0, + 38400, + 0, + USART_CR2_LINEN, + 0 +}; + /*===========================================================================*/ /* Module local types. */ /*===========================================================================*/ diff --git a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/halconf.h b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/halconf.h index a4095ba96..a7f25ffab 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/halconf.h +++ b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/halconf.h @@ -389,7 +389,7 @@ * @note Disabling this option saves both code and data space. */ #if !defined(UART_USE_WAIT) || defined(__DOXYGEN__) -#define UART_USE_WAIT FALSE +#define UART_USE_WAIT TRUE #endif /** diff --git a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/mcuconf.h b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/mcuconf.h index 6cd1b89d3..2f6e98c83 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/mcuconf.h +++ b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/mcuconf.h @@ -289,12 +289,12 @@ /* * UART driver system settings. */ -#define STM32_UART_USE_USART1 FALSE -#define STM32_UART_USE_USART2 FALSE -#define STM32_UART_USE_USART3 FALSE -#define STM32_UART_USE_UART4 FALSE -#define STM32_UART_USE_UART5 FALSE -#define STM32_UART_USE_USART6 FALSE +#define STM32_UART_USE_USART1 TRUE +#define STM32_UART_USE_USART2 TRUE +#define STM32_UART_USE_USART3 TRUE +#define STM32_UART_USE_UART4 TRUE +#define STM32_UART_USE_UART5 TRUE +#define STM32_UART_USE_USART6 TRUE #define STM32_UART_USART1_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 5) #define STM32_UART_USART1_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 7) #define STM32_UART_USART2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 5) diff --git a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/portab.c b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/portab.c index 1d42746d2..b1b9c2a9d 100644 --- a/testhal/STM32/multi/UART/cfg-stm32f407_discovery/portab.c +++ b/testhal/STM32/multi/UART/cfg-stm32f407_discovery/portab.c @@ -34,6 +34,27 @@ /* Module exported variables. */ /*===========================================================================*/ +void txend1(UARTDriver *uartp); +void txend2(UARTDriver *uartp); +void rxend(UARTDriver *uartp); +void rxchar(UARTDriver *uartp, uint16_t c); +void rxerr(UARTDriver *uartp, uartflags_t e); + +/* + * UART driver configuration structure. + */ +UARTConfig uart_cfg_1 = { + NULL, + NULL, + NULL, + NULL, + NULL, + 38400, + 0, + USART_CR2_LINEN, + 0 +}; + /*===========================================================================*/ /* Module local types. */ /*===========================================================================*/ -- cgit v1.2.3