avikde / koduino

Arduino code for STM32 microcontrollers
http://avikde.me/koduino
Other
61 stars 25 forks source link

Serial Bootloader for STM32F303CCT6 and compatibility with Arduino #23

Open SandeepanSengupta opened 6 years ago

SandeepanSengupta commented 6 years ago

Wish to make a blue-pill like dev board, but feeling lost as I failed to find any maple-like bootloader for STM32F303CCT6 that can be uploaded via serial. Requesting your assistance/guidance to make such dev-board.. Please guide me to suitable Arduino Core repo for 303CC and most importantly, maple-like bootloader (if any) Regards.

rogerclarkmelbourne commented 6 years ago

I've done extensive searching about this in the past and AFIK.. there is no similar bootloader for any other STM32 device apart from the STM32F1.

There are other bootloaders for the F1, including the new HID bootloader written by @bootsector, but its written using the hardware CMSIS, porting would require register level knowledge of the F3

SandeepanSengupta commented 6 years ago

@rogerclarkmelbourne, I've mailed you about this. So, apparently there is no way to have a generic board made using STM32F303 (32 or 48 pin variant). Also, while working on maple, I was not being able to compile this version from your source code. I suspect it's because of the GCC version. Do we still need to switch back to GCC 4.8 and if so, how ? A how to guide/youtube video or similar guide will help

bootsector commented 6 years ago

@rogerclarkmelbourne, I've checked the STM32F303 Reference Manual and it does use the same USB macrocell being used by the STM32F103. Assuming one replaces the CMSIS files with the F3 ones and adjust the code accordingly, it should be fairly easy to port the HID bootloader to the F3 series.

arpruss commented 6 years ago

You don't need to install a bootloader for the f303c: it comes with a USB DFU bootloader built-in. Just use BOOT0 to activate it, and you can use dfu-util to upload.