2015-11-26 06:50 PM
Please help,
I was programming my STM32F4-Discovery with an ''ADCInterleaved'' code (from template) using Keil and suddenly my board get disconnected from my PC. The program load was smooth though, but after i want to test it with ''Start/Stop Debug Session'', an error window popped up saying that my board has been disconnected, thus the debug session exit for itself.And after that my board always get ''USB Device not recognised'' error from Windows. And everytime I triy to load a program or start a debug session, it ended up with ''No ST-LINK detected'' error.Is there anything I can do? I've tried connecting to different PC but no help. All I know is the indicator lamp still on, and I can guarantee that there is no short circuit (also my program is only ADC, there won't be any problem), so I guess there's nothing wrong with the hardware itself.Does anyone have a similar problem? Please, I'm stuck here. (and sorry for my english)2015-11-26 07:16 PM
Try connecting the BOOT pin to VDD, this will stop the code you loaded running on the board. If you get connectivity, erase the part using the ST-LINK Utilities.
2015-11-26 07:32 PM
Hi, clive1 thanks a bunch!
I've connected BOOT0 and VDD now the program stopped like you said, and voila the device is now recognised. But one thing, is there any problem if I load a program to STM (replacing the old ones) while connecting those pins? I'm being paranoid now. And by the way is it the same with ''erasing the part'' that you said earlier?Thanks again.2015-11-27 03:19 AM
The part continues to function normally, you can program and erase it, the BOOT pin just selects that it starts the System Loader, a safe harbour, instead of potentially broken user supplied code.
Take the jumper off, it will run your code again. You need to look at exactly what your code is doing to break the debugger, check what pins are being reconfigured, or if the device is put in a low power mode, etc.2015-11-29 02:58 AM
Thanks! I did those steps and it's been working normally from that time.