Problem with STM32 when scheduler sleep is enabled

Situation: I enabled scheduler sleep by un-commenting the line (in sch_ttc.h): //#define SLEEP

After uploading the code, I cannot reprogram the controller using JTAG. Any work arrounds for this problem?

Would STM32 flash loader work?

Have you tried erasing the board with the STM32 Flash Loader?

Documents and files for family STM32

Dev

A possible solution: By

A possible solution: By putting the microcontroller into ISP mode (Boot0 High, Boot1 Low), you can try to upload new software into the chip. However, in my case, the ST’s Flash Loader was unable to connect to the board for the programming. Fortunately, with the chip in ISP mode, I was able to use the JTAG to program the controller.

Hope this helps.