STM32F105 DFU Bootloader Grief
Hi all.
I'm new to STM, but have been designing and making embedded MCU products for over ten years.
I was drawn to the STM32F105 series because of the USB DFU, to allow for field updates for prospective customers to update a product we're developing. Outside of USB DFU functionality, we just need 3x UART's, one GPI, one GPO. That's it. We steer clear of USART1 because of it's overlap with OTG_FS pins. We have got our product working using a ST-Link programmer, but not as yet using the USB DFU.
Our USB connection just isn't enumerating. The wiring is correct when compared to off-the-shelf STM32 enabled boards with OTG USB interfaces.
I am across the date code bootloader issue as described in AN2606, our chips definitely come with bootloader 2.2. I have VBUS from the USB-C tied to PA9 (OTG_FS_VBUS). Yes, USB-C but with the 5.1K resistors between CC1, CC2 and GND. NRST is pulled to 3V3 with a 10K pull-up. Boot0 and Boot1 is pulled to GND via a 10K pull-down, Boot0 also runs to a tactile NO pushbutton that throws to 3V3. Holding the button down while applying power does successfully put the micro into bootloader mode (tested with J-Link), so the pattern is correct.
I have an external 8MHz crystal. I read somewhere that folks specifically had no luck with this and had to use 25MHz to get USB DFU. Is that correct? I assume the IOC in STM32CubeIDE is only relevant for my program and not for the stock bootloader? (Re Clock Configuration, Connectivity>USB_OTG_FS in particular)? When I put our code into a program I configured in STM32CubeIDE for the STM32F405 (Adafruit Feather STM32F405 Express) and uploaded it, the clock configuration and USB_OTG_FS settings didn't make any difference to how the board behaved in bootloader mode, its USB DFU worked fine.
Do I need any other pins connected? OTG_FS_ID? OTG_FS_SOF?
Many thanks in advance!
