Having stepped further in my IAP firmware update project I now want to flash sectors on a LPC1343. I decided to use the flash source code delivered with the KEIL MDK V4.23 (C:\Keil\ARM\Flash\LPC_IAP\FlashPrg.c). I'm wondering about a function 'Init()' which switches the processors clock to the internal oscillator. As my bootloader app has already executed its startup code, my processsor is running from an external oscillator. So, why to switch to the internal osc before flashing? Best regards, Juergen.
Projects in Keil\ARM\Flash folder are made for uVision Flash programmer. They contain functions required for programming/erasing (including "Init") required by the toolchain.
The same code can be used also for IAP but sometimes requires minor modifications to fit the standalone projects.