Hi to all...
I am using Keil Microvision 4, and am using the microcontroller LPC2103 - NXP make with 12MHz Crystal Oscillator in my hardware. I am trying to built a code for LED Blinking, but the converted hex file is not working in the hardware
Pls suggest me...
This is my code
===============================================================================================
#include <LPC2103.H>
void wait (void) { int d; for (d = 0; d < 10000; d++); }
void PLLInit(void) { PLLCFG = 0x24; PLLCON = 0x01; PLLFEED = 0xAA; PLLFEED = 0x55; while(!(PLLSTAT & 0x0724)) ; PLLCON = 0x03; PLLFEED = 0xAA; PLLFEED = 0x55; APBDIV = 0x02; }
void MAMInit(void) { MAMCR = 0x02; MAMTIM = 0x03; MEMMAP = 0xFD; }
void SYSCONTROLInit(void) { IODIR = 0x04000000; PINSEL0 = 0x00000000; PINSEL1 = 0x00000000; }
int main (void) { PLLInit(); MAMInit(); SYSCONTROLInit();
while (1) { IOCLR = 0x04000000; wait(); IOSET = 0x04000000; wait();
} }
Waiting for Reply.,.,.,.,
Thanks & Regards
Gunasekaran TP
Don't just sit there waiting - do some Debugging!