I had a variation of the same problem. My error message was the same. I post the following to help those in the same shape. I was setting up my FSMC memory controller bus to talk to an external LCD and set the latency of the flash to 0 instead of 1 (to see if it would speed up access to the LCD). Turned out this "wing it" idea would cost me 6 hours. p.FSMC_DataSetupTime = 1; moved to xxxx = 0; After executing this line of code and debugging - the JLINK refused to connect (IAR 5.2, Jlink driver 4…