Fixed USART4/5 support on STM32L07x.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10205 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
dd4239960c
commit
0d9f42c9d9
|
@ -168,8 +168,7 @@
|
|||
#define STM32_SERIAL_USE_LPUART1 FALSE
|
||||
#define STM32_SERIAL_USART1_PRIORITY 3
|
||||
#define STM32_SERIAL_USART2_PRIORITY 3
|
||||
#define STM32_SERIAL_UART4_PRIORITY 3
|
||||
#define STM32_SERIAL_UART5_PRIORITY 3
|
||||
#define STM32_SERIAL_USART3_8_PRIORITY 3
|
||||
#define STM32_SERIAL_LPUART1_PRIORITY 3
|
||||
|
||||
/*
|
||||
|
|
|
@ -99,6 +99,20 @@
|
|||
STM32_DMA_GETCHANNEL(STM32_UART_UART8_TX_DMA_STREAM, \
|
||||
STM32_UART8_TX_DMA_CHN)
|
||||
|
||||
/* Workarounds for those devices where UARTs are USARTs.*/
|
||||
#if defined(USART4)
|
||||
#define UART4 USART4
|
||||
#endif
|
||||
#if defined(USART5)
|
||||
#define UART5 USART5
|
||||
#endif
|
||||
#if defined(USART7)
|
||||
#define UART7 USART7
|
||||
#endif
|
||||
#if defined(USART8)
|
||||
#define UART8 USART8
|
||||
#endif
|
||||
|
||||
/*===========================================================================*/
|
||||
/* Driver exported variables. */
|
||||
/*===========================================================================*/
|
||||
|
|
|
@ -1048,6 +1048,16 @@
|
|||
#error "invalid source selected for USART2 clock"
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief USART4 frequency.
|
||||
*/
|
||||
#define STM32_UART4CLK STM32_PCLK1
|
||||
|
||||
/**
|
||||
* @brief USART5 frequency.
|
||||
*/
|
||||
#define STM32_UART5CLK STM32_PCLK1
|
||||
|
||||
/**
|
||||
* @brief LPUART1 frequency.
|
||||
*/
|
||||
|
|
|
@ -1472,9 +1472,10 @@
|
|||
STM32_DMA_STREAM_ID_MSK(1, 7))
|
||||
#define STM32_USART2_TX_DMA_CHN 0x04004000
|
||||
|
||||
#define STM32_USART3_8_HANDLER Vector78
|
||||
#define STM32_USART3_8_NUMBER 14
|
||||
|
||||
#define STM32_HAS_UART4 TRUE
|
||||
#define STM32_UART4_HANDLER Vector78
|
||||
#define STM32_UART4_NUMBER 14
|
||||
#define STM32_UART4_RX_DMA_MSK (STM32_DMA_STREAM_ID_MSK(1, 2) |\
|
||||
STM32_DMA_STREAM_ID_MSK(1, 6))
|
||||
#define STM32_UART4_RX_DMA_CHN 0x00C000C0
|
||||
|
@ -1483,8 +1484,6 @@
|
|||
#define STM32_UART4_TX_DMA_CHN 0x0C000C00
|
||||
|
||||
#define STM32_HAS_UART5 TRUE
|
||||
#define STM32_UART5_HANDLER Vector78
|
||||
#define STM32_UART5_NUMBER 14
|
||||
#define STM32_UART5_RX_DMA_MSK (STM32_DMA_STREAM_ID_MSK(1, 2) |\
|
||||
STM32_DMA_STREAM_ID_MSK(1, 6))
|
||||
#define STM32_UART5_RX_DMA_CHN 0x00D000D0
|
||||
|
|
Loading…
Reference in New Issue