4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-02-25 01:47:06 +08:00
levizhxl 1d6347796d
Hc32 pr (#6003)
* HC32F460 supported

Co-authored-by: JamieTx <yangjp24@126.com>
Co-authored-by: Jamie <48308473+JamieTx@users.noreply.github.com>
2022-05-31 11:53:56 +08:00

55 lines
1.5 KiB
C

/*
* Copyright (c) 2006-2022, RT-Thread Development Team
* Copyright (c) 2022, Xiaohua Semiconductor Co., Ltd.
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2022-04-28 CDT first version
*/
#ifndef __BOARD_CONFIG_H__
#define __BOARD_CONFIG_H__
#include <rtconfig.h>
#include "hc32_ll.h"
#include "drv_config.h"
/************************ USART port **********************/
#if defined(BSP_USING_UART1)
#define USART1_RX_PORT (GPIO_PORT_C)
#define USART1_RX_PIN (GPIO_PIN_04)
#define USART1_TX_PORT (GPIO_PORT_A)
#define USART1_TX_PIN (GPIO_PIN_07)
#endif
#if defined(BSP_USING_UART2)
#define USART2_RX_PORT (GPIO_PORT_A)
#define USART2_RX_PIN (GPIO_PIN_04)
#define USART2_TX_PORT (GPIO_PORT_A)
#define USART2_TX_PIN (GPIO_PIN_02)
#endif
#if defined(BSP_USING_UART3)
#define USART3_RX_PORT (GPIO_PORT_C)
#define USART3_RX_PIN (GPIO_PIN_13)
#define USART3_TX_PORT (GPIO_PORT_H)
#define USART3_TX_PIN (GPIO_PIN_02)
#endif
#if defined(BSP_USING_UART4)
#define USART4_RX_PORT (GPIO_PORT_B)
#define USART4_RX_PIN (GPIO_PIN_09)
#define USART4_TX_PORT (GPIO_PORT_E)
#define USART4_TX_PIN (GPIO_PIN_06)
#endif
#endif