generated from hulk/gd32e23x_template_cmake_vscode
30 lines
964 B
C
30 lines
964 B
C
#ifndef BOARD_CONFIG_H
|
|
#define BOARD_CONFIG_H
|
|
|
|
/* >>>>>>>>>>>>>>>>>>>>[RS485 PHY DEFINE]<<<<<<<<<<<<<<<<<<<< */
|
|
|
|
// #define RS485_MAX13487 //RS485 PHY : MAX13487 (AutoDir)
|
|
#undef RS485_MAX13487 //RS485 PHY : SP3487 (no AutoDir)
|
|
|
|
/******************************************************************************/
|
|
|
|
#define LED_PORT GPIOA
|
|
#define LED_PIN GPIO_PIN_7
|
|
#define LED_RCU RCU_GPIOA
|
|
|
|
/******************************************************************************/
|
|
|
|
#define RS485_RCU RCU_USART0
|
|
#define RS485_GPIO_RCU RCU_GPIOA
|
|
#define RS485_GPIO_PORT GPIOA
|
|
#define RS485_TX_PIN GPIO_PIN_2
|
|
#define RS485_RX_PIN GPIO_PIN_3
|
|
#define RS485_PHY USART0
|
|
#define RS485_BAUDRATE 115200U
|
|
#define RS485_EN_PIN GPIO_PIN_1
|
|
#define RS485_IRQ USART0_IRQn
|
|
|
|
/******************************************************************************/
|
|
|
|
#endif //BOARD_CONFIG_H
|