Content originally posted in LPCWare by Rob65 on Fri Dec 30 05:43:57 MST 2011
Sharadanand,
most likely your previous program sets something that makes the controller non-functional. Things like switching to a PLL that is not running, or running at an invalid frequency and more of these issues.
Luckily the Boot ROM checks, before starting your user program, if a certain pin is pulled low. In that case the boot rom goes into in system programming mode allowing you to program the flash using uart0. This also makes the SWD debugger functional again.
So just pull down P2.10 during reset and then try to attach using your debugger. This does the trick in 98.9% of all cases.
Regards,
[INDENT]Rob
[/INDENT]