LPCOpen Platform  v1.03
LPCOpen Platform for NXP LPC Microcontrollers
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
LPC17xx/40xx 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:
LPC17xx/40xx example quickstart for Keil uVision4
LPC17xx/40xx example quickstart for IAR EWARM
LPC17xx/40xx example quickstart for Code Red Xpresso

Supported boards and board setup:
Embedded Artists' LPC1788 Developer's Kit
Embedded Artists' LPC4088 Developer's Kit

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 63 of file lcd.c.

#define LCD_WIDTH   BOARD_LCD.PPL

Definition at line 62 of file lcd.c.

#define LOGO_HEIGHT   42

Definition at line 65 of file lcd.c.

#define LOGO_WIDTH   110

Definition at line 64 of file lcd.c.

Function Documentation

int main ( void  )

Main entry point.

Main program body.

Returns
Nothing

Definition at line 106 of file lcd.c.

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

Definition at line 83 of file lcd.c.

void SysTick_Handler ( void  )

SysTick Interrupt Handler.

SysTick 1mS tick handler.

Returns
Nothing

Definition at line 95 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 68 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 69 of file lcd.c.