include <LPC2103.H>
//#include "lpc21xx.h"
#define LEDCON 0x00002000 /* P0.17*/
//sbit IN=P0^3;
//sbit OUT=P0^17;
/****************************************************************************
* DelayNS()
****************************************************************************/
void DelayNS(unsigned int dly)
{ unsigned int i;
for(; dly>0; dly--)
for(i=0; i<50000; i++);
}
/****************************************************************************
*main()
****************************************************************************/
int main(void)
{ PINSEL0 = 0x00000000; // Enable GPIO
PINSEL1 = 0x00000000;
IODIR = LEDCON; // Enable LED4 Direction
while(1)
{
/*if(IOPIN&0x00000008)
IOSET =0x00002000;
else
IOPIN =0x00000000;*/
IOPIN = LEDCON;
DelayNS(30);
//IO0CLR = LEDCON;
//DelayNS(30);
}
return(0);
}