After using this command ; dfu-util -a 0 --dfuse-address 0x08000000 -D firmware.bin ,
I don't have in USB DeviceTree STM32 Bootloader
MAC bootloader
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
MAC bootloader
- Attachments
-
- boot 2.png (120 KiB) Viewed 521 times
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
Did the firmware upload run successfully?
https://learn.adafruit.com/adafruit-stm ... 3045693-18
https://learn.adafruit.com/adafruit-stm ... 3045693-18
Upon success, reset the board without the BOOT0 jumper and you will see after a few seconds the CIRCUITPY disk drive appear
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
I did the first step
1. For Mac users, install dfu-util with brew = OK
The second step
2. Then upload the firmware with the command = = error = dfu-util: Could not open file firmware.bin for reading: No such file or directory
++++++++++++++++++++++++++++++++++++++++++++++++++++
dfu-util -a 0 --dfuse-address 0x08000000 -D firmware.bin
+++++++++++++++++++++++++++++++++++++++++++++++++++
xyz@xyzs-iMac ~ % sudo port install dfu-util
Password:
---> Computing dependencies for dfu-util
---> Cleaning dfu-util
---> Scanning binaries for linking errors
---> No broken files found.
---> No broken ports found.
xyz@xyzs-iMac ~ % dfu-util -a 0 --dfuse-address 0x08000000 -D firmware.bin
dfu-util 0.11
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2021 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/
dfu-util: Could not open file firmware.bin for reading: No such file or directory
xyz@xyzs-iMac ~ %
1. For Mac users, install dfu-util with brew = OK
The second step
2. Then upload the firmware with the command = = error = dfu-util: Could not open file firmware.bin for reading: No such file or directory
++++++++++++++++++++++++++++++++++++++++++++++++++++
dfu-util -a 0 --dfuse-address 0x08000000 -D firmware.bin
+++++++++++++++++++++++++++++++++++++++++++++++++++
xyz@xyzs-iMac ~ % sudo port install dfu-util
Password:
---> Computing dependencies for dfu-util
---> Cleaning dfu-util
---> Scanning binaries for linking errors
---> No broken files found.
---> No broken ports found.
xyz@xyzs-iMac ~ % dfu-util -a 0 --dfuse-address 0x08000000 -D firmware.bin
dfu-util 0.11
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2021 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/
dfu-util: Could not open file firmware.bin for reading: No such file or directory
xyz@xyzs-iMac ~ %
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
Okay, the error message you provided is very helpful.
It appears you are not in the same directory as the firmware.bin file?
Go ahead and download the CircuitPython 7.3.0 bin file to upload and either rename it firmware.bin or use it's default filename and replace the last dfu-util argument to:
https://downloads.circuitpython.org/bin ... -7.3.0.bin
It appears you are not in the same directory as the firmware.bin file?
Go ahead and download the CircuitPython 7.3.0 bin file to upload and either rename it firmware.bin or use it's default filename and replace the last dfu-util argument to:
Code: Select all
dfu-util -a 0 --dfuse-address 0x08000000 -D adafruit-circuitpython-feather_stm32f405_express-en_US-7.3.0.bin
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
I can't open CircuitPython to modify it
- Attachments
-
- Screen Shot 2022-06-19 at 9.01.31 PM.png (29.25 KiB) Viewed 474 times
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
I think the problem is in this error when I trying to upload using bootloader
On the top = I follow error path = maple upload is grey color, on the bottom I opened STM32 master and maple upload is in black color./Users/xyz/Documents/Arduino/hardware/Arduino_STM32-master copy/tools/macosx/maple_upload: line 34: /Users/xyz/Documents/Arduino/hardware/Arduino_STM32-master: No such file or directory
An error occurred while uploading the sketch
- Attachments
-
- Screen Shot 2022-06-19 at 9.17.10 PM.png (439.1 KiB) Viewed 474 times
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
You don't need to modify the CircuitPython file, just run the command-line program dfu-util with the arguments I gave you while in the same directory as the downloaded BIN file.
The upload error you found from the Arduino IDE is helpful. Not finding the maple_upload binary is helpful. It looks as if you downloaded the STM32 board manager code manually through github instead of using the recommended package through the Arduino IDE.
https://learn.adafruit.com/adafruit-stm ... -ide-setup
Can you re-install the STM32 board manager package using the above link directions?
The upload error you found from the Arduino IDE is helpful. Not finding the maple_upload binary is helpful. It looks as if you downloaded the STM32 board manager code manually through github instead of using the recommended package through the Arduino IDE.
https://learn.adafruit.com/adafruit-stm ... -ide-setup
Can you re-install the STM32 board manager package using the above link directions?
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
I started over, reset the MAC to factory settings, loaded the STM32 board manager from your link, reinstalled the CubeProgramer and follow this instruction for blink
and got this error:Time to Test:
Connect your STM32 to your USB to Serial:
USB to TTL - STM32
Ground - Ground
5 volts - 5V (make sure USB to TTL is set to 5v, or if 3.3 volt, then connect it to the 3.3 pin)
TX - A10
RX - A9
Move jumper BOOT0 to 1, press reset, load Blink in the Arduino IDE examples.
Under Tools set the following options:
* Board > Generic STM32F1 Series (or what ever you have)
* Board Part Number > BluePill F10C8
* U(S)ART support: Enabled (generic Serial)
* USB Support (if available): None
* Optimize: Smallest (-Os default)
* C Runtime Library: Newlib Nano(default)
* Upload method: STM32CubeProgrammer (Serial)
* Port: (select your USB to TTL serial port)
With everything connected, click upload and you should see a flashing LED.
-------------------------------------------------------------------
STM32CubeProgrammer v2.10.0
-------------------------------------------------------------------
Serial Port cu.usbserial-0001 is successfully opened.
Port configuration: parity = even, baudrate = 115200, data-bit = 8,
stop-bit = 1.0, flow-control = off
Timeout error occured while waiting for acknowledgement.
Timeout error occured while waiting for acknowledgement.
Error: Activating device: KO. Please, verify the boot mode configuration and check the serial port configuration. Reset your device then try again...
Error: Activating device: KO. Please, verify the boot mode configuration and check the serial port configuration. Reset your device then try again...
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
Thanks for resetting things and for this error output.
Just to confirm you did do the BOOT0 jumper and rest press just before pressing the upload button?
Just to confirm you did do the BOOT0 jumper and rest press just before pressing the upload button?
Move jumper BOOT0 to 1, press reset, load Blink in the Arduino IDE examples.
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
Oops, I reversed PB9 and PB10, now LED is blinking, naw i going to test serial monitor.
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
A strange things are happened. 1. Uploading blink program using serial method = Ok 2. Uploading binary code " hid_generic_pc13 " using ST Link = Ok 3. connecting bootloader cable to micro plug, uplowding blink program = Ok
4. I am changing delays in bling program and pressing upload ikon and got an error:
4. I am changing delays in bling program and pressing upload ikon and got an error:
So, I can use bootloar upload method only once, to use it again I have go trough steps 1 to 3 again+-----------------------------------------------------------------------+
| HID-Flash v2.2.1 - STM32 HID Bootloader Flash Tool |
| (c) 2018 - Bruno Freitas http://www.brunofreitas.com |
| (c) 2018-2019 - Vassilis Serasidis https://www.serasidis.gr |
| Customized for STM32duino ecosystem https://www.stm32duino.com |
+-----------------------------------------------------------------------+
> Trying to open the [cu.Bluetooth-Incoming-Port]...
> Toggling DTR...
> Searching for [1209:BEBA] device...
##########
An error occurred while uploading the sketch
Error - [1209:BEBA] device is not found :(> Searching for [cu.Bluetooth-Incoming-Port] ...
> [cu.Bluetooth-Incoming-Port] is found !
> Finish
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
Congratulations on getting the code to upload and a console.
You need to go back into boot mode (BOOT0 jumper) after an initial code upload to prepare the processor for receiving the next upload.
You need to go back into boot mode (BOOT0 jumper) after an initial code upload to prepare the processor for receiving the next upload.
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
With cable connected to usb micro socket ?
You mean like this ?
You mean like this ?
- Attachments
-
- Programming-STM32-(Blue-Pill)-Directly-Through-USB-Port.jpg (45.4 KiB) Viewed 402 times
-
- STM32-Operating-and-Programming-Mode.jpg (35.03 KiB) Viewed 402 times
- ted456
- Posts: 18
- Joined: Sat Jun 18, 2022 6:13 am
Re: MAC bootloader
I followed this instruction
https://www.youtube.com/watch?v=Myon8H111PQ
6:30 to 7:20
6:52 = Ok
7:06 = is not working
https://www.youtube.com/watch?v=Myon8H111PQ
6:30 to 7:20
6:52 = Ok
7:06 = is not working
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: MAC bootloader
Does the troubleshooting steps mentioned after 7:06 --> 7:49 resolve it?
re-upload bootloader, unplug USB, upload again (maybe an additional upload)
Can you please post a photo of your setup. 800x600 works best.
re-upload bootloader, unplug USB, upload again (maybe an additional upload)
Can you please post a photo of your setup. 800x600 works best.
Please be positive and constructive with your questions and comments.