LPCOpen Platform  v1.03
LPCOpen Platform for NXP LPC Microcontrollers
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
LPC18xx/43xx LCD (colorbars and cursor) example

Detailed Description

Example description
This example shows how to configure the LCD. It renders colorbars, shows an image, and allows control of a pointer.

Special connection requirements
There are no special connection requirements for this example.

Build procedures:
LPC18xx/43xx example quickstart for Keil uVision4
LPC18xx/43xx example quickstart for IAR EWARM
LPC18xx/43xx example quickstart for Code Red Xpresso

Supported boards and board setup:
Hitex 1850 evaluation boards
Hitex 4350 evaluation boards
Keil 1857 evaluation boards
Keil 4357 evaluation boards

Submitting LPCOpen issues:
Community support for LPCOpen

Macros

#define LCD_WIDTH   BOARD_LCD.PPL
 
#define LCD_HEIGHT   BOARD_LCD.LPP
 
#define LOGO_WIDTH   110
 
#define LOGO_HEIGHT   42
 

Functions

static void putpixel (uint32_t x, uint32_t y, uint16_t val)
 
void SysTick_Handler (void)
 SysTick Interrupt Handler.
 
int main (void)
 Main entry point.
 

Variables

static uint16_t * framebuffer = (uint16_t *) FRAMEBUFFER_ADDR
 
static volatile uint32_t msec
 
const unsigned short image []
 NXP logo image data.
 

Macro Definition Documentation

#define CURSOR_H_OFS   (10)

'Pointer' cursor image horizontal offset

Definition at line 56 of file Cursor.h.

#define CURSOR_H_SIZE   32

'Pointer' cursor image horizontal size

Definition at line 46 of file Cursor.h.

#define CURSOR_V_OFS   (6)

'Pointer' cursor image vertical offset

Definition at line 61 of file Cursor.h.

#define CURSOR_V_SIZE   32

'Pointer' cursor image vertical size

Definition at line 51 of file Cursor.h.

#define LCD_HEIGHT   BOARD_LCD.LPP

Definition at line 65 of file lcd.c.

#define LCD_WIDTH   BOARD_LCD.PPL

Definition at line 64 of file lcd.c.

#define LOGO_HEIGHT   42

Definition at line 67 of file lcd.c.

#define LOGO_WIDTH   110

Definition at line 66 of file lcd.c.

Function Documentation

int main ( void  )

Main entry point.

Main program body.

Returns
Nothing

Definition at line 108 of file lcd.c.

static void putpixel ( uint32_t  x,
uint32_t  y,
uint16_t  val 
)
static

Definition at line 85 of file lcd.c.

void SysTick_Handler ( void  )

SysTick Interrupt Handler.

SysTick 1mS tick handler.

Returns
Nothing

Definition at line 97 of file lcd.c.

Variable Documentation

const unsigned char Cursor[(CURSOR_H_SIZE/4)*CURSOR_V_SIZE]

'Pointer' cursor image data

uint16_t* framebuffer = (uint16_t *) FRAMEBUFFER_ADDR
static

Definition at line 70 of file lcd.c.

const unsigned short image[]

NXP logo image data.

Definition at line 50 of file image.c.

const unsigned short image[4620]

NXP logo image data.

Definition at line 50 of file image.c.

volatile uint32_t msec
static

Definition at line 71 of file lcd.c.