dear dun han you wrote I had NOT enabled MAM before. I enabled it and the system works correctly now. Thank you for your useful advices.
same problem we have our led is 2-3 mhz.and we know we must see 30 mhz around.
which is correct about pll and MAM?
2 milli-hertz is not much. 500 seconds period.
2 mega-hertz is fast for a LED. Is it a communications link?
IOSET1=0XFFFF0000;
IOCLR1=0XFFFF0000;
my program is this.if system works 60 mhz i must see 30 mhz.(around).but i see 2-3 mhz somebody says mam control but not explained it.what is pll and mam be .(i changed it but outpu frequency not changed)
please help
Sorry, but the LPC21xx series has very slow I/O. It takes many cycles to toggle a pin since the pin is not on a local bus.
You have to use a LPC23xx to get the newer I/O interface. But even then, you would get into troubles if you _need_ 1 cycle/operation.
MAM will just speed up your instruction processing by caching memory accesses. But it can't help out with the slow transfers of I/O commands from the ARM core to the I/O module.
Once more: You have to learn that m = milli = 0.001. M = mega = 1000000. Hz = hertz = periods/second.
So mega-hertz is MHz not mhz. Small m is a difference of 1000000000 compared to M and that is a quite big difference...
Also LPC214x has a Fast GPIO Interface which should be used in order to achieve the best performance. The interface is enabled in SCS register and uses similar registers like legacy GPIO. Details are in the User Manual.
Frequencies up to 15MHz can be achieved with proper code (CPU @ 60MHz).
Me bad. Yes, the LPC21xx can select between legacy and fast accessing modes for the two ports but will default to the legacy access mode.
i will look to SCS registers.thanks robert rostohar