EEVblog #1306 (3 of 5) : How to program an STM32 using DFU Bootloader

EEVblog #1306 (3 of 5) : How to program an STM32 using DFU Bootloader

EEVblog

4 года назад

50,841 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

christopher békési
christopher békési - 21.07.2023 10:47

You could have just used the DFU utility provided by ST directly instead of fiddling with the WinUSB driver. The reason for the replaced driver is because the ST driver interface is not directly supported by the DFU tool you used. ST link Utility or STM32CubeProgrammer would be a much better option and you would get access to all the option bytes as well

Ответить
Alive and well in Israel
Alive and well in Israel - 14.12.2022 12:30

It was enjoyable to watch you figure out the Zadig thing. I've had to mess with that a few times, and it's always great when it finally works.

Ответить
limpqizbuit
limpqizbuit - 19.11.2022 02:43

I love how even with how advanced technology has gotten. We still have gems like you teaching the ground floor basics. Looking forward to building some of my first pcbs in the near future!

Ответить
Graham Daniel
Graham Daniel - 13.10.2022 10:27

Fantastic! I had been considering setting myself up to program and use some Padauk micros, saw your first vid a couple of nights ago. had a little look on your vids list but missed the follow ups. Last night was a 12 hour day at work and a midnight 2hour callout this morning. Had this interesting blast from the past, looking at STM32 and DFU on this vid which reminded me of the STM32F103 motherboard I designed up just over a decade ago and here was this vid, tackling 2 subjects in one! Thanks! ps Zadig was a BS circus when I used it too.

Ответить
MOHAMED ELSISY
MOHAMED ELSISY - 06.04.2022 23:36

Thank you very much, i did all steps even the dfu with the address of 0x0800 and all steps have been done, but even now when i am plugin the board, it can not give the recognized sound !. I have to use boot0 and nrst mode, i am using stm31f411 black bill board.

Ответить
木子
木子 - 02.10.2021 15:37

I got same problem with stm32f401 in platformio, when I replace driver use zadig, it can upload use dfu, but it has no virtual com,why?

Ответить
osman özdemir
osman özdemir - 03.05.2021 16:49

Can I upload code to the same processor over and over again this way? (no using TTL again)

Ответить
joakim
joakim - 16.03.2021 00:48

This is great, gave it a thumbs up. Question:

"--dfuse-adress" it says not applicable for .dfu downloads. Isn't that exactly the type of file the firmware is?

I couldn't get it to work, i actually skipped that command and just went straight to downloading the file onto the device. It completed the download, i'm not sure if it works as intended. Thoughts?


Any answers appreciated, thanks.

Ответить
DAVID GREGORY KERR
DAVID GREGORY KERR - 13.01.2021 17:08

Windows requires a reboot unlike Linux MInt but I reboot anyway.

Ответить
Paul Stoleriu
Paul Stoleriu - 07.12.2020 14:29

I've also used zadig to overwrite usb drivers for interfacing with smartphone bootloader. I think the windows driver stack is FUBAR and we should run the hell away from microsoft products

Ответить
Rafal Z
Rafal Z - 14.08.2020 04:09

So is that all mean that on the end you have programmer integrated on your flash ? And DFU from system memory is not in use anymore as not going anymore to boot mode? Is the driver going to flash, how much kB?

Ответить
Gacheru Mburu
Gacheru Mburu - 08.08.2020 20:30

👍

Ответить
christopher békési
christopher békési - 26.06.2020 01:51

Before watching any further; I've worked with STM32s a ton, and the Cortex M3 does not come with a built in DFU through USB. You'd have to tap into the UART1 headers and flash throgh a serial converter.

Ответить
Steve Tobias
Steve Tobias - 20.06.2020 07:18

I have a couple of STM32 development boards that I have come a gutza on. I might try this and see if I can get them working.
Thanks Dave!

Ответить
Erik Schiegg
Erik Schiegg - 09.06.2020 00:04

May I propose the Atom Lite M5 Stack as a future topic? Are they any good? ESP32 inside.
PS: It's ok, Andreas Spiess made a video.

Ответить
Internaut
Internaut - 30.05.2020 12:57

thanks to this video I have a nice and healthy easy pdk programmer excellent!!!!.. but my chips did not arrived yet :-( feel great!

Ответить
PyroRob69
PyroRob69 - 28.05.2020 19:07

Haha, a Windows nightmare, as usual.

Ответить
Amaury Jacquot
Amaury Jacquot - 20.05.2020 23:07

you got problems just because you use windows. for us playing along at home with linux, no problems ;-)

Ответить
Qs Tech Service
Qs Tech Service - 20.05.2020 18:41

FlashCat programmer
works good for programming 😳👍 easy breezy beautiful cover girl 👧

Ответить
Chris
Chris - 19.05.2020 19:53

I've never tried it on Windows with an SMT32, but I remember Zadig from back when the RTLSDR fever started. Actually DFU looks more straightforward on linux if you have the precompiled (or can compile) the same dfu-util in the video. You just have to look up the correct USB VID/PID with lsusb. No driver replacement needed, the kernel handles this out-of-the-box. At least for an STM32. I came across some F103 boards where the USB dataline pullups were missing. If you don't have a debug probe for STM cortex-m devices there's an alternative UART way too using STM32-FLASHER.

Ответить
Ronnie Pirtle Jr
Ronnie Pirtle Jr - 18.05.2020 13:29

The aliens are shooting a laser beam on your screen Dave. You figured out their technology!

Ответить
Rémi Busseuil
Rémi Busseuil - 18.05.2020 13:09

What about the official stm32 DFU firmware?

Ответить
Klint Krossa
Klint Krossa - 18.05.2020 01:43

ask to list this video on the github wiki

Ответить
Steven Knudsen
Steven Knudsen - 18.05.2020 01:15

DFU gets it programmed, but does nothing to help with debugging. Just go straight to SWD since you will eventually anyway.

Ответить
migkillerphantom
migkillerphantom - 17.05.2020 22:49

If even windows can detect it you bet your ass linux will too.

Ответить
Bogdan Serban
Bogdan Serban - 17.05.2020 22:36

It's handy to have a linux machine for this kind of stuff. Windows is just a pain in the butt.

Ответить
blenderNOOb69
blenderNOOb69 - 17.05.2020 16:14

Moon on L1 - I like it...

Ответить
Necessaryevil 86
Necessaryevil 86 - 17.05.2020 14:18

The same the thing got me when I worked with Arduino... Good to see that it can happen to anyone, now I know I'm not loosing my sanity.

Ответить
Oleg Kutkov
Oleg Kutkov - 17.05.2020 13:51

Oh, it's WAY easier to do such things in Linux. Such problems just don't exist. Everything is working just out the box, probably one or two simple commands are required to install toolchain/programming utility.

Ответить
avi bank
avi bank - 17.05.2020 13:07

This was very useful. I've had to do similar things to make a Black Magic Probe out of an stm32 'Blue Pill'. Lots of trouble shooting...

Ответить
Vincent Fischer
Vincent Fischer - 17.05.2020 12:01

Atmel? DFU?

Ответить
MoosesValley
MoosesValley - 17.05.2020 06:28

Current stats: 16,255 views and only 894 LIKEs.
Come on people, if you watch something and like it, please click the THUMBS UP button and show your appreciation.

Ответить
MoosesValley
MoosesValley - 17.05.2020 04:31

Hi Dave, I saw yesterday's post about how dissappointed you are with the "low" 10,000+ per day view counts for your Padauk microcontroller series videos ...
Two points:
(1). Don't worry, it's a great project to do a series of videos on, viewers will come, it's a slow burn.
(2). You are very lucky, I have well over 100 "learn to program in Java" videos (and many others on my channel, my channel is over 8 years old, and I'm lucky to see 100 views a day. I've got 230+ students in my course this term, and the vast majority download the videos directly - so no view counts, no comments, bugger all subscribers, no likes ... it's like a ghost town in my channel. I create all of my videos in my time (not paid to do it), like creating the videos, and absolutely love programming (have done for 4+ decades now), so more than happy to share what I know. 10,000 views a day for me would be astounding. Even 1,000+ views would be awesome.
You produce great content. I'm a software guy, and I'm watching all of your videos (mostly watch on LIBRARY now), and clicking LIKE on every video. Anyway, just my 0.02 LBC. Hope this helps. Moose

Ответить
Vitor Moreno
Vitor Moreno - 17.05.2020 03:43

You could just used the STM32CubeProgrammer software

Ответить
Adrian Levi
Adrian Levi - 17.05.2020 01:40

Please keep these series up Dave!

Ответить
nico nico
nico nico - 17.05.2020 00:45

"it's a found device" .... i love that :D

Ответить
Eng. Simoes
Eng. Simoes - 17.05.2020 00:38

Please anyone guide me here. In the opening Dave says he is going to program an ATMEL processor without an ATMEL programmer, then proceeds to program an STM32. What am I missing?

Ответить
beartastic
beartastic - 16.05.2020 23:28

Such a shame they didn't take the oppurtinity to go with "I'm sorry Dave I can't do that" as an error message.

Ответить
Tim S
Tim S - 16.05.2020 22:39

Command line shortcut: click once in the File Explorer window with the thing you want to run (the background, not any file in the window), hold shift, right click mouse. You'll get a context menu and one option will be "Open Command Window Here". If your default command interpreter has been set to Power Shell on your system, this option will be replaced with "Open Powershell Window Here"

Ответить
Tricky Rat
Tricky Rat - 16.05.2020 20:45

Dang, several days in and we still don't have a single flashing LED.. :)

Ответить
gd2329j
gd2329j - 16.05.2020 20:22

A good interface is a simple one & stand-alone if possible .
A one click operation or data file drag & drop .

Program file *****.bin or hex Yes or No !
Simple ….........

No installing of special drivers needed just a readme , the data , exe . tar or apk .

We need programmers not script kids compiling code that needs three libraries , seven linkers a working online server & three hail marys .

Ответить
Internaut
Internaut - 16.05.2020 20:01

Is interesting! I have ordered all the thingies nut some are yet out of stock! Hahaha, i have bought some different kinds of SOP8 Padukas. Thanks Dave. I am waiting like a child to see if i can translate some of my old projects....

Ответить
kruppin
kruppin - 16.05.2020 19:51

If you had used another DFU software which expects the STTub driver instead of WinUSB it would've worked straight away. For example STM's Cube Programmer. Also the migrated message in device manager is pretty common the first message until it's installed correct drivers. And yeah, I agree it's wierd the oldest is at the top, but thats windows for you. :D

Ответить
Jonathan Wilhelm
Jonathan Wilhelm - 16.05.2020 19:16

Thank you for this video. I have been trying to figure out dfu for awhile now

Ответить
Jerry Ericsson
Jerry Ericsson - 16.05.2020 18:13

Having messed with ZADIG many times in the past using SDR devices, I found that for the first time ever, I screamed at the screen SHOW ALL DEVICES DAVE! Ah well we all have bad days and when your mind is as full of electronic knowledge, some small software glitch catching you for a few seconds can indeed be excused as, "anybody could do that!" Thanks for the wonderful videos, I am a constant watcher, I have learned a lot, however there is much that goes way over my old head.

Ответить
RonsonDenmark
RonsonDenmark - 16.05.2020 17:09

Heh.. Hopes the HW doesn't work so he can troubleshoot. But as soon as the software doesn't work OOTB ...

Ответить
Gregg Jaskiewicz
Gregg Jaskiewicz - 16.05.2020 17:01

Basically - this is an episode that shows why you shouldn’t use windows for these things /-)

Ответить