Content originally posted in LPCWare by capiman on Thu Jan 09 01:47:50 MST 2014
Hello,
sorry, I don't understand your description of the error. Can you give more details,
which sector, addresses and parameter you use exactly?
Have you taken into account, that IAP needs some memory during operation?
Have a look into IAP/ISP section of UserManual to see where and how big this memory area is exactly.
With "Copy RAM to Flash" some boundary conditions are mentioned, do you have them right:
Param0(DST): Destination flash address where data bytes are to be written. This
address should be a 256 byte boundary.
Param1(SRC): Source RAM address from which data bytes are to be read. This
address should be a word boundary.
Param2: Number of bytes to be written. Should be 256 | 512 | 1024 | 4096.
Another topic is, when you mention first sector, have you taken into account
where your program is located? In the beginning of Flash there is also the interrupt vector table.
Best regards,
Martin