Hi Jeremy Hsiao,
Actually, you don't need to read out the ISER and clear ICER, you can just do it like the lpcopen periph_flashiap project.
Before you do the IAP call, you disable the interrupt with this code:
__disable_irq();
After you finish the IAP function, you can enable the interrupt with this code:
__enable_irq();

Wish it helps you!
If you still have question about it, please kindly let me know.
Have a great day,
Kerry
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------