cancel
Showing results for 
Search instead for 
Did you mean: 

Prgramming another target (with STM32F405RGT6) board with SWD by STM32F4-Discovery

Posted on July 03, 2015 at 00:40

Hi. I'm trying to program another target board (our design) with SWD by F4-Discovery board. I'm connecting, erasing the target MCU with STLINK/v2 utility but when I want to debug it with Keil v5.15 Lite Version it doesn't start to run program, it sometimes start to run after immediately the download to flash operation, sometimes giving error like ''Cannot debug the target'' or ''target dll has been cancelled'' or ''change the connect settings to normal or under reset (I don't remember exact warning)'' so I can't debugging board. I've checked the voltages (all Vdd pins and Vcap pins) and they are normal. I've also remove the SB11 and SB12 on discovery board. I can run and debug the program with on board MCU on the discovery. Thanks for any help.

3 REPLIES 3
Posted on July 03, 2015 at 10:16

Keep the cable short (cca 10cm). Do you have reset connected?

JW

stm32forum
Associate II
Posted on July 03, 2015 at 10:50

Don't forget to connect GND between both boards.

Posted on July 06, 2015 at 02:52

I connected boards' GNDs, probably cable sizes because programming cables are standard hobby cables which are approximately 20cm (with min 3, max 6 cm connector to MCU) or bad PCB printing and track placement because after I've opened this subject, debugger connected to the target then started to debug but one time debugging more time erroring. I didn't design the latest board I've just checked that the tracks are connecting to the right pin. Now I'll design new board. Thanks for the answers.