Power cycle required to enter DFU
I am working on a board containing two STM32F412, and I am having a hard time reaching the DFU bootloader:
- If I power off the board, pull the boot pin low, and then power on the board directly via USB, then cubeProgrammer is able to connect to the bootloader via DFU, completely as expected
- However, if I let the board be powered in run-mode, pull the boot pin low, and then reset the MCU via the nRST pin, then the cubeProgrammer is not able to connect the bootloader via DFU
- At this point I am able to keep the boot pin grounded, power cycle the board (by disconnect/reconnecting the USB cable), and then cubeprogrammer is able to connect to the bootloader again
The schematic is illustrated below:
- SW3 is a latching switch to select which of the two MCUs are connected to the USB connector
- USB1.D- and USB1.D+ goes to PA11 and PA12, respectively on the first MCU, and USB2.D- and USB2.D+ and similarly connected to the second MCU
- The design relies on the internal MCU pull-up resistors of the D+ line, as described on AN2606 (Table 72)

The reset and boot pin schematic is illustrated below:
- The NRST signal is jointly connected to the reset pin on both MCUs
- SW2 is switch that jointly asserts the boot pin on each MCU - Boot0_1 and Boot0_2 goes to Boot0 on MCU 1 and 2 respectively

The schematic is fully consistent with the design we usually use without issues, except for the details relating to having two MCUs instead of only one.
Any suggestions as to what might cause the issue we are seeing would be greatly appreciated.
