You are on page 1of 2

Blink LEDs

1.) AIM: To blink LEDs at a port-x using Keil tool in Embedded-c


for LPC -2148

2.) EQUIPMENT REQUIRED:

SOFTWARE USED: Keil µvision-4

3.) EMBEDDED-C PROGRAM:


// LEDs blink at port-1 (P1.31-P1.16)

#include<lpc214x.h>

int i;

delay()

for (i=0;i<1000000;i++);

main()

IODIR1 = 0xFFFF0000;

while(1)

IOSET1=0xFFFF0000;

delay();

IOCLR1=0xFFFF0000;

delay();

}
}

4.) RESULT : The working of a port-x was verified with the blink of LEDs
using Keil tool in Embedded-c for LPC- 2148

You might also like