add Ethernet config for xidatong from Wang_weigen

it is OK
This commit is contained in:
xuedongliang 2022-03-30 13:22:46 +08:00
commit 5951468186
2 changed files with 11 additions and 1 deletions

View File

@ -77,6 +77,10 @@ extern int ExtSramInit(void);
#endif #endif
#endif #endif
#ifdef BSP_USING_LWIP
extern int ETH_BSP_Config();
#endif
void BOARD_SD_Pin_Config(uint32_t speed, uint32_t strength) void BOARD_SD_Pin_Config(uint32_t speed, uint32_t strength)
{ {
IOMUXC_SetPinConfig(IOMUXC_GPIO_SD_B0_00_USDHC1_CMD, IOMUXC_SetPinConfig(IOMUXC_GPIO_SD_B0_00_USDHC1_CMD,
@ -296,8 +300,10 @@ void InitBoardHardware()
BOARD_InitPins(); BOARD_InitPins();
BOARD_BootClockRUN(); BOARD_BootClockRUN();
#ifndef BSP_USING_LWIP
NVIC_SetPriorityGrouping(NVIC_PRIORITYGROUP_4); NVIC_SetPriorityGrouping(NVIC_PRIORITYGROUP_4);
SysTick_Config(SystemCoreClock / TICK_PER_SECOND); SysTick_Config(SystemCoreClock / TICK_PER_SECOND);
#endif
#ifdef BSP_USING_GPIO #ifdef BSP_USING_GPIO
Imxrt1052HwGpioInit(); Imxrt1052HwGpioInit();
@ -325,6 +331,10 @@ void InitBoardHardware()
#endif #endif
#endif #endif
#ifdef BSP_USING_LWIP
ETH_BSP_Config();
#endif
#ifdef BSP_USING_LPUART #ifdef BSP_USING_LPUART
Imxrt1052HwUartInit(); Imxrt1052HwUartInit();
#endif #endif

View File

@ -62,7 +62,7 @@ void InitBoardHardware(void);
#define NVIC_PRIORITYGROUP_4 0x00000003U /*!< 4 bits for pre-emption priority*/ #define NVIC_PRIORITYGROUP_4 0x00000003U /*!< 4 bits for pre-emption priority*/
/*! @brief The ENET PHY address. */ /*! @brief The ENET PHY address. */
#define BOARD_ENET0_PHY_ADDRESS (0x02U) /* Phy address of enet port 0. */ #define BOARD_ENET0_PHY_ADDRESS (0x0U) /* Phy address of enet port 0. */
/* USB PHY condfiguration */ /* USB PHY condfiguration */
#define BOARD_USB_PHY_D_CAL (0x0CU) #define BOARD_USB_PHY_D_CAL (0x0CU)