Page 1 of 1

stm32duino bootloader

Posted: 17 Feb 2018, 18:17
by Flynn
So......following on from a previous conversation..... ;) It does work. My STM32F103C8T6's arrived today and after swapping out the 10k R10 for a 1K (should be a 1k5 but I didn't have any of those to hand) and flashing the stmduino bootloader onto the device it will accept sketch uploads via the USB without faffing with the boot()0 jumpers. The bootloader takes 8k of flash space. Upon connection the device goes into DFU mode for a second or two as the bootloader loads the USB-serial drivers and then it runs the loaded sketch.

However, I got some strange results when I uploaded the i2s_scanner_softwire sketch using the bootloader - it found an i2c device on every address (it correctly found none when the sketch is uploaded via a usb-serial adapter).. I am guessing it has something to do with the memory location the sketch is loaded into but i don't know enough to debug it successfully.

Also after loading a sketch via the USB-serial adapter the bootloader is corrupted, presumably some/all of the bootloader addresses are over-written by the sketch..

Another day filled with messing about with arduino!! :lol: