The underlying "LinkServer" debug interface (used for CMSIS-DAP debug connections) has been considerably changed since the days of LPCXpresso IDE v7.7.2 (released back in March 2015). And the fact that you see CMSIS-DAP in one launch config, and LinkServer in the other doesn't actually tell you anything.
I would suggest doing the following:
- Start up MCUXpresso IDE with your project loaded into the workspace.
- Ensure that JP1 header on your LPC-Link2 is not fitted. This will allow the IDE to soft-load the latest probe firmware supplied with the IDE itself.
- Delete any launch configurations in your project directory.
- Power down your board and debug probe, then power them up again.
- Ensure your project is selected in the Project Explorer View, then click on the Debug button in the Quickstart Panel.
The IDE should now boot your LPC-Link2, allow you to select it, and start a debug session.
Now run to the line that is triggering your problem. Try stepping over it.
If you still see problems, then please send us the text from the Debug Log (messages) and the gdb traces from the Console view. See the MCUXpresso IDE v10.1.1 User Guide, section 16.8, "The Console View", for more details of how to do this.
It would also be useful to know if the problem is actually specific to this specific project. For instance, if you mass erase the flash, then program in a simple test project (for instance one of the LPCOpen examples for LPC407x_8x), do you still see issues.
Also, can you please provide more details of the board you are using, in particular related to how debug/reset signals are connected up (as per - Design Considerations for Debug )
Regards,
MCUXpresso IDE Support.