Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

Re: IAP throwing Undefined Instruction on some units

2006-02-23 by Danish Ali

I think your crystal is faster than most of us use, so you might
be in uncharted territory.

Is it possible that you're giving the IAP call the wrong value for
the system clock frequency? The time of the flash write might be
process-dependent (and temperature and supply-voltage) so it
might vary from chip to chip. If the processor returns before
the flash is ready, who knows what instruction will be fetched.

Param3 should be 24000 or 48000 because it is in kHz.
Try boosting it by 20% to see if it is an extreme process corner.

(It is possible that such numbers are outside the range Philips
tested in their IAP delay routines. But the data sheet says
it should cope with up to 25000 kHz).

Another thing I would try is a longer delay between
"prepare for write" and "copy ram to flash".
ISP programming is likely to have a long delay between commands.

Hope this helps you get these chips working,
Danish

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.