Firmware uploading via USB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-07-31 4:43 PM
Hi there,
I'm migrating to STM32F103VC or similar from embedded Arduino/Teensy MCU's (Atmega328P and MK20DX256). My IDE (PlatformIO Atom) supports several ST Micro's out of the box, but I have a few questions around implementation that I haven't been able to answer from the documentation so far.
Here are my questions:
- I understand these MCU's can be firmware uploaded via USB (without an intermediate bootloader chip/interface). Do they ship ready for this, or do they need to be configured for this using a JTAG programmer first (If so, please explain how this is done or point me in the direction of the relevant application note).
- Is there a document with the recommended connection schematic for a direct USB connection to a STM32 MCU ?
- Perhaps I'm behind the times, but I used a bit of EEPROM on my Atmega/MK20DX256 embedded projects and most of these STM32 micro's don't appear to have that. Is there a new, non-volatile program writable memory with a different name I'm unaware of?
I'm attracted to these STM32 products because I understand they come with a bootloader onboard and can be programmed via USB directly, which jumps a few of the hurdles with other brand MCU's.
Many thanks in advance !
- Labels:
-
Bootloader
-
ST-Link
-
USB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-07-31 5:56 PM
- Per AN2606 [page 54], F103 does not have a built-in USB bootloader. Only UART is supported.
Bootloader in F105, 107 has the USB option.
2. Yes there's an appnote for h/w designs with USB. Hope someone can find it (I've lost the bookmark after the forum re-haul).
3. No new names, just flash and eeprom. Older chips have only flash, some newer STM32L have eeprom as well.
-- pa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-07-31 6:11 PM
AN3156 covers the USB DFU mode
https://www.st.com/en/development-tools/stsw-stm32080.html
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-08-01 6:36 AM
DFU is not to be confused with USB host/peripheral functionality, I see. I'll do some reading up on the code required to read/write flash - I'm very accustomed to the ease with which the Arduino framework reads/writes the onboard EEPROM.
Thanks, that's helpful.
A further question, if I may..
The models that support the DFU have a lot of other features I don't need, and are a lot more expensive (thinking production quantity here). Is there a simple USB programmer chip I could install (that you could recommend) to make it field programmable with only a USB lead but still able to talk to most IDE's ? Perhaps ironically, the chip ST Micro use for their ST-Link is the F103.. Do they publish the bootloader installed on that?
Thanks again !
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-08-01 11:42 AM
(2) The document is AN4879 "USB hardware and PCB guidelines using STM32 MCUs"
-- pa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-08-01 11:54 AM
> Is there a simple USB programmer chip I could install (that you could recommend) to make it field programmable with only a USB lead
Why do you insist on programming only with USB? ST-LINK or compatible debugger devices are cheap and reliable, great for field servicing (unless you have security concerns).
-- pa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-08-01 3:50 PM
Hi Pavel,
The reason I'm so keen on USB is that the end user will need to be able to update it too. I'm happy to use JTAG or any other programmer in the workshop, but that doesn't help my clients.
Many thanks..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-08-02 5:16 AM
Then the only option for F103 is custom USB updater, with DFU or virtual serial (CDC) interface.
-- pa
