external/target/lpc4337/lpc_board_ngx_xplorer_4330/src/board.c
void Board_Init(void)
{
	/* Sets up DEBUG UART */
	DEBUGINIT();

	/* Initializes GPIO */
	Chip_GPIO_Init(LPC_GPIO_PORT);

	/* Setup GPIOs for USB demos */
	Chip_SCU_PinMuxSet(0x2, 6, (SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4));			/* P2_6 USB1_PWR_EN, USB1 VBus function */
	Chip_SCU_PinMuxSet(0x2, 5, (SCU_MODE_INACT | SCU_MODE_INBUFF_EN | SCU_MODE_ZIF_DIS | SCU_MODE_FUNC2));	/* P2_5 USB1_VBUS, MUST CONFIGURE THIS SIGNAL FOR USB1 NORMAL OPERATION */
	Chip_SCU_PinMuxSet(0x1, 7, (SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4));			/* P1_7 USB0_PWR_EN, USB0 VBus function Xplorer */
	Chip_GPIO_SetPinDIROutput(LPC_GPIO_PORT, 5, 6);							/* GPIO5[6] = USB1_PWR_EN */
	Chip_GPIO_SetPinState(LPC_GPIO_PORT, 5, 6, true);							/* GPIO5[6] output high */

	/* Initialize LEDs */
	Board_LED_Init();
#if defined(USE_RMII)
	Chip_ENET_RMIIEnable(LPC_ETHERNET);
#else
	Chip_ENET_MIIEnable(LPC_ETHERNET);
#endif
}
/* Set up and initialize all required blocks and functions related to the
   board hardware */
Set up and initialize all required blocks and functions related to the
board hardware
Set up and initialize all required blocks and functions related to the board hardware
void Board_Init(void)
{
	DEBUGINIT();
	Chip_GPIO_Init(LPC_GPIO_PORT);
	Chip_SCU_PinMuxSet(0x2, 6, (SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4));			
	Chip_SCU_PinMuxSet(0x2, 5, (SCU_MODE_INACT | SCU_MODE_INBUFF_EN | SCU_MODE_ZIF_DIS | SCU_MODE_FUNC2));	
	Chip_SCU_PinMuxSet(0x1, 7, (SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4));			
	Chip_GPIO_SetPinDIROutput(LPC_GPIO_PORT, 5, 6);							
	Chip_GPIO_SetPinState(LPC_GPIO_PORT, 5, 6, true);							
	Board_LED_Init();
#if defined(USE_RMII)
	Chip_ENET_RMIIEnable(LPC_ETHERNET);
#else
	Chip_ENET_MIIEnable(LPC_ETHERNET);
#endif
}
void Board_Init ( void ) { DEBUGINIT ( ) ; Chip_GPIO_Init ( LPC_GPIO_PORT ) ; Chip_SCU_PinMuxSet ( 0x2 , 6 , ( SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4 ) ) ; Chip_SCU_PinMuxSet ( 0x2 , 5 , ( SCU_MODE_INACT | SCU_MODE_INBUFF_EN | SCU_MODE_ZIF_DIS | SCU_MODE_FUNC2 ) ) ; Chip_SCU_PinMuxSet ( 0x1 , 7 , ( SCU_MODE_PULLUP | SCU_MODE_INBUFF_EN | SCU_MODE_FUNC4 ) ) ; Chip_GPIO_SetPinDIROutput ( LPC_GPIO_PORT , 5 , 6 ) ; Chip_GPIO_SetPinState ( LPC_GPIO_PORT , 5 , 6 , true ) ; Board_LED_Init ( ) ; #if defined ( USE_RMII ) Chip_ENET_RMIIEnable ( LPC_ETHERNET ) ; #else Chip_ENET_MIIEnable ( LPC_ETHERNET ) ; #endif }
Set up and initialize all required blocks and functions related to the
board hardware
Set up and initialize all required blocks and functions related to the board hardware
/* Sets up DEBUG UART */ /* Initializes GPIO */ /* Setup GPIOs for USB demos */ /* P2_6 USB1_PWR_EN, USB1 VBus function */ /* P2_5 USB1_VBUS, MUST CONFIGURE THIS SIGNAL FOR USB1 NORMAL OPERATION */ /* P1_7 USB0_PWR_EN, USB0 VBus function Xplorer */ /* GPIO5[6] = USB1_PWR_EN */ /* GPIO5[6] output high */ /* Initialize LEDs */