LPCOpen Platform  v1.03
LPCOpen Platform for NXP LPC Microcontrollers
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
BOARD: Common board functions

Detailed Description

This file contains common board definitions that are shared across boards and devices. All of these functions do not need to be impemented for a specific board, but if they are implemented, they should use this API standard.

Macros

#define DEBUGINIT()
 
#define DEBUGOUT(...)
 
#define DEBUGSTR(str)
 
#define DEBUGIN()   (int) EOF
 

Typedefs

typedef void(* p_msDelay_func_t )(uint32_t)
 Function prototype for a MS delay function. Board layers or example code may define this function as needed.
 

Functions

void Board_Init (void)
 Set up and initialize all required blocks and functions related to the board hardware.
 
void Board_Debug_Init (void)
 Initializes board UART for output, required for printf redirection.
 
void Board_UARTPutChar (char ch)
 Sends a single character on the UART, required for printf redirection.
 
int Board_UARTGetChar (void)
 Get a single character from the UART, required for scanf input.
 
void Board_UARTPutSTR (char *str)
 Prints a string to the UART.
 
void Board_LED_Set (uint8_t LEDNumber, bool State)
 Sets the state of a board LED to on or off.
 
bool Board_LED_Test (uint8_t LEDNumber)
 Returns the current state of a board LED.
 
STATIC INLINE void Board_LED_Toggle (uint8_t LEDNumber)
 Toggles the current state of a board LED.
 
void SystemCoreClockUpdate (void)
 Update system core clock rate, should be called if the system has a clock rate change.
 
void Board_SetLCDBacklight (uint8_t Intensity)
 Turn on Board LCD Backlight.
 

Variables

uint32_t SystemCoreClock
 Current system clock rate, mainly used for sysTick.
 

Macro Definition Documentation

#define DEBUGIN ( )    (int) EOF

Definition at line 158 of file board_api.h.

#define DEBUGINIT ( )

Definition at line 155 of file board_api.h.

#define DEBUGOUT (   ...)

Definition at line 156 of file board_api.h.

#define DEBUGSTR (   str)

Definition at line 157 of file board_api.h.

Typedef Documentation

typedef void(* p_msDelay_func_t)(uint32_t)

Function prototype for a MS delay function. Board layers or example code may define this function as needed.

Definition at line 135 of file board_api.h.

Function Documentation

static Status Board_Audio_CodecInit ( int  micIn)
static

Definition at line 265 of file board_ngx_xplorer_18304330.c.

void Board_Audio_Init ( LPC_I2S_T pI2S,
int  micIn 
)

Sets up board specific I2S interface and UDA1380 CODEC.

Sets up board specific I2S interface and UDA1380.

Initialize I2S interface for the board and UDA1380.

Parameters
pI2S: I2S peripheral to use (Must be LPC_I2S)
micIn: If 1 MIC will be used as input device, if 0 LINE_IN will be used as input to Audio Codec.
Returns
Nothing

Definition at line 284 of file board_ngx_xplorer_18304330.c.

void Board_Buttons_Init ( void  )

Initialize buttons on the board.

Initializes board specific buttons.

Initialize button(s) interface on board.

Returns
Nothing

Definition at line 130 of file board_ngx_xplorer_18304330.c.

void Board_Debug_Init ( void  )

Initializes board UART for output, required for printf redirection.

Returns
None

Definition at line 94 of file board_nxp_xpresso_11c24.c.

void Board_ENET_GetMacADDR ( uint8_t *  mcaddr)

Returns the MAC address assigned to this board.

Parameters
mcaddr: Pointer to 6-byte character array to populate with MAC address
Returns
Nothing
Note
Returns the MAC address used by Ethernet

Definition at line 165 of file board_ngx_xplorer_18304330.c.

void Board_GPIO_Int_Init ( void  )

Initializes board specific GPIO Interrupt.

Returns
Nothing

Definition at line 221 of file board_ngx_xplorer_18304330.c.

void Board_I2C_Init ( I2C_ID_T  id)

Sets up board specific I2C interface.

Parameters
id: I2C peripheral ID (I2C0, I2C1 or I2C2)
Returns
Nothing

Sets up board specific I2C interface.

Parameters
id: Must be passed as I2C0
Returns
Nothing
Parameters
id: I2C peripheral ID (Must be I2C0)
Returns
Nothing

Definition at line 196 of file board_ngx_xplorer_18304330.c.

void Board_Init ( void  )

Set up and initialize all required blocks and functions related to the board hardware.

Returns
None

Definition at line 138 of file board_nxp_xpresso_11c24.c.

void Board_Joystick_Init ( void  )

Initialize Joystick.

Initializes board specific joystick.

Initialize joystick interface on board.

Returns
Nothing

Definition at line 145 of file board_ngx_xplorer_18304330.c.

static void Board_LED_Init ( void  )
static

Definition at line 95 of file board_ngx_xplorer_18304330.c.

void Board_LED_Set ( uint8_t  LEDNumber,
bool  State 
)

Sets the state of a board LED to on or off.

Parameters
LEDNumber: LED number to set state for
State: true for on, false for off
Returns
None

Definition at line 116 of file board_nxp_xpresso_11c24.c.

bool Board_LED_Test ( uint8_t  LEDNumber)

Returns the current state of a board LED.

Parameters
LEDNumber: LED number to set state for
Returns
true if the LED is on, otherwise false

Definition at line 123 of file board_nxp_xpresso_11c24.c.

STATIC INLINE void Board_LED_Toggle ( uint8_t  LEDNumber)

Toggles the current state of a board LED.

Parameters
LEDNumber: LED number to change state for
Returns
None

Definition at line 103 of file board_api.h.

void Board_SDMMC_Init ( void  )

Initialize pin muxing for SDMMC interface.

Sets up board specific SDMMC interface.

Returns
Nothing

Definition at line 233 of file board_ngx_xplorer_18304330.c.

void Board_SetLCDBacklight ( uint8_t  Intensity)

Turn on Board LCD Backlight.

Parameters
Intensity: Backlight intensity (0 = off, >=1 = on)
Returns
None
Note
On boards where a GPIO is used to control backlight on/off state, a '0' or '1' value will turn off or on the backlight. On some boards, a non-0 value will control backlight intensity via a PWN. For PWM systems, the intensity value is a percentage value between 0 and 100%.

Definition at line 710 of file board_ea_devkit_17884088.c.

void Board_SSP_Init ( LPC_SSP_T pSSP)

Initialize pin muxing for SSP interface.

Sets up board specific SSP interface.

Parameters
pSSP: Pointer to SSP interface to initialize
Returns
Nothing

Definition at line 244 of file board_ngx_xplorer_18304330.c.

void Board_UART_Init ( LPC_USART_T pUART)

Initialize pin muxing for a UART.

Initialize pin muxing for UART interface.

Parameters
pUART: Pointer to UART register block for UART pins to init
Returns
Nothing

Definition at line 37 of file board_ngx_xplorer_18304330.c.

int Board_UARTGetChar ( void  )

Get a single character from the UART, required for scanf input.

Returns
EOF if not character was received, or character value

Definition at line 73 of file board_nxp_xpresso_11c24.c.

void Board_UARTPutChar ( char  ch)

Sends a single character on the UART, required for printf redirection.

Parameters
ch: character to send
Returns
None

Definition at line 63 of file board_nxp_xpresso_11c24.c.

void Board_UARTPutSTR ( char *  str)

Prints a string to the UART.

Parameters
str: Terminated string to output
Returns
None

Definition at line 84 of file board_nxp_xpresso_11c24.c.

uint32_t Buttons_GetStatus ( void  )

Get button status.

Returns button(s) state on board.

Returns
status of button

Definition at line 136 of file board_ngx_xplorer_18304330.c.

static void delay ( uint32_t  i)
static

Definition at line 260 of file board_ngx_xplorer_18304330.c.

void GPIO0_IRQHandler ( void  )

Definition at line 210 of file board_ngx_xplorer_18304330.c.

uint8_t Joystick_GetStatus ( void  )

Get Joystick status.

Initialize joystick interface on board.

Returns joystick states on board.

System Clock Frequency (Core Clock)

Definition at line 148 of file board_ngx_xplorer_18304330.c.

void Serial_CreateStream ( void *  Stream)

Create Serial Stream.

FIXME.

Parameters
Stream: Pointer to stream
Returns
Nothing

Definition at line 299 of file board_ngx_xplorer_18304330.c.

void SystemCoreClockUpdate ( void  )

Update system core clock rate, should be called if the system has a clock rate change.

Returns
None

Definition at line 130 of file board_nxp_xpresso_11c24.c.

Variable Documentation

uint32_t SystemCoreClock

Current system clock rate, mainly used for sysTick.

< System Clock Frequency (Core Clock)

System Clock Frequency (Core Clock)

Definition at line 47 of file board_nxp_xpresso_11c24.c.