• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2022 Talkweb Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *    http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef _HAL_USART_H_
17 #define _HAL_USART_H_
18 
19 #include "stm32f4xx_ll_usart.h"
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
25 #if defined (USART1) || defined (USART2) || defined (USART3) || defined (USART6) \
26     || defined (UART4) || defined (UART5)
27 
28 #if defined(USE_FULL_LL_DRIVER)
29 
30 uint32_t USART_TxData(USART_TypeDef * UART, uint8_t *p_data, uint32_t size);
31 uint32_t USART_RxData(uint8_t num, uint8_t *p_data, uint32_t size, BOOL isBlock);
32 
33 void UART_IRQ_INIT(USART_TypeDef * UART, uint8_t num, uint32_t irqNum, BOOL isBlock);
34 void UART_IRQ_DEINIT(USART_TypeDef * UART, uint32_t irqNum);
35 
36 #endif /* USE_FULL_LL_DRIVER */
37 
38 #endif /* USART1 || USART2 || USART3 || USART6 || UART4 || UART5 || UART7 || UART8 || UART9 || UART10 */
39 
40 #ifdef __cplusplus
41 }
42 #endif
43 
44 #endif /* _HAL_USART_H_ */
45