2024-06-14 07:31 AM
Hi,
1. is there any tool (GUI) to update program using executable?
2. How to have different modes of programming? (UART/ USB/ sd card)
3. Bootloader mentions: USB OTG FS (PA11/12) in Device mode (DFU: device firmware upgrade). Can external HS phy in FS as a device be used to update program?
2024-06-14 07:41 AM - edited 2024-06-14 07:44 AM
Hello,
1. is there any tool (GUI) to update program using executable?
Using STM32CubeProgrammer tool
2. How to have different modes of programming? (UART/ USB/ sd card)
Read AN2606 STM32 microcontroller system memory boot mode / Read the table " configuration in system memory boot mode" that corresponds to your device. It describes the different resources and which interface is used for bootloader for that device. SD card is not a part of the ST bootloader you need to develop it yourself.
3. Bootloader mentions: USB OTG FS (PA11/12) in Device mode (DFU: device firmware upgrade). Can external HS phy in FS as a device be used to update program?
Same answer as 2.
2024-06-21 01:55 AM
Hi, reading on program update is ongoing.
I tried using STM32CubeProgrammer and was able to program using ST-Link.
but I tried USB FS device with DFU, and STM32CubeProgrammer was able to detect USB and when connect is pressed...the bottom bar keeps on searching and never finishes...this is with STM32F469 discovery kit.
I tried loading "DFU_standalone" also but could see same.
Please any suggestions?
2024-06-21 02:12 AM
What about boot pin? How you did manage it? & Reset?
2024-06-21 03:32 AM
on kit I see boot 0 and boot 1 are to GND through resistors, I was not able to change those.
Also I tried pressing RESET button, nothing happened
I didn't go for having USB FS connected and re-plugging ST-Link cable, since I read board should be powered before connecting USB.
Reading is on-going, if any suggestions from experts, can speed-up our understanding
2024-06-21 03:54 AM
The features and functions of the ROM will be limited. It's aimed at production programing or debricking in the field.
For a better, more tailored, user experience you code your own loader with the rich features you want. One that implements DFU, or MSC for a drag-n-drop update, does serial XMODEM from a terminal app, or checks an SD Card for an update image.
2024-06-21 05:38 AM - edited 2024-06-21 05:51 AM
I changed Boot0 to 3.3V and was able to do "Start Program" from CubeProgrammer, USB was detected and download looked complete. But it didn't boot to flash.
So changed again boot0 to GND, but don't see the program updated...
Is anything missed?
I used .elf files, 2 numbers, both having different LEDs to be toggled
2024-06-21 05:59 AM
So changed again boot0 to GND, but don't see the program updated...
Did you reset the MCU after changing boot0 to GND?
2024-06-21 06:06 AM
yes reset press tried, also USB cable re-insertion tried.
2024-06-21 06:20 AM
CubeProg logs for USB DFU, verify program is failing
18:47:37 : UR connection mode is defined with the HWrst reset mode
18:47:37 : USB speed : Full Speed (12MBit/s)
18:47:37 : Manuf. ID : STMicroelectronics
18:47:37 : Product ID : STM32 BOOTLOADER
18:47:37 : SN : 2057355C5231
18:47:37 : DFU protocol: 1.1
18:47:37 : Board : --
18:47:37 : Device ID : 0x0434
18:47:37 : UPLOADING OPTION BYTES DATA ...
18:47:37 : Bank : 0x00
18:47:37 : Address : 0x1fffc000
18:47:37 : Size : 16 Bytes
18:47:37 : Bank : 0x01
18:47:37 : Address : 0x1ffec008
18:47:37 : Size : 4 Bytes
18:47:37 : UPLOADING ...
18:47:37 : Size : 1024 Bytes
18:47:37 : Address : 0x8000000
18:47:37 : Read progress:
18:47:37 : Data read successfully
18:47:37 : Time elapsed during the read operation is: 00:00:00.003
18:47:58 : Memory Programming ...
18:47:58 : Opening and parsing file: usb_fs_update_test_01 - led1.elf
18:47:58 : File : usb_fs_update_test_01 - led1.elf
18:47:58 : Size : 27.00 KB
18:47:58 : Address : 0x08000000
18:47:58 : Erasing memory corresponding to segment 0:
18:47:58 : Erasing internal memory sectors [0 1]
18:47:58 : sector 0000 does not exist
18:47:58 : sector 0001 does not exist
18:47:58 : Download in Progress:
18:47:58 : File download complete
18:47:58 : Time elapsed during download operation: 00:00:00.240
18:47:58 : Verifying ...
18:47:58 : Read progress:
18:47:58 : Error: Data mismatch found at address 0x08000DD0 (byte = 0x00 instead of 0x40)
18:47:58 : Error: Download verification failed
18:48:13 : Disconnected from device.
whereas from ST Link its ok
18:45:48 : UR connection mode is defined with the HWrst reset mode
18:45:49 : ST-LINK SN : 066CFF575285514867153350
18:45:49 : ST-LINK FW : V2J44M29
18:45:49 : Board : 32F469IDISCOVERY
18:45:49 : Voltage : 3.25V
18:45:49 : SWD freq : 4000 KHz
18:45:49 : Connect mode: Normal
18:45:49 : Reset mode : Software reset
18:45:49 : Device ID : 0x434
18:45:49 : Revision ID : Rev A
18:45:49 : Debug in Low Power mode is not supported for this device.
18:45:49 : UPLOADING OPTION BYTES DATA ...
18:45:49 : Bank : 0x00
18:45:49 : Address : 0x40023c14
18:45:49 : Size : 8 Bytes
18:45:49 : UPLOADING ...
18:45:49 : Size : 1024 Bytes
18:45:49 : Address : 0x8000000
18:45:49 : Read progress:
18:45:49 : Data read successfully
18:45:49 : Time elapsed during the read operation is: 00:00:00.007
18:45:51 : Memory Programming ...
18:45:51 : Opening and parsing file: usb_fs_update_test_01 - led3.elf
18:45:51 : File : usb_fs_update_test_01 - led3.elf
18:45:51 : Size : 27.00 KB
18:45:51 : Address : 0x08000000
18:45:51 : Erasing memory corresponding to segment 0:
18:45:51 : Erasing internal memory sectors [0 1]
18:45:51 : Download in Progress:
18:45:52 : File download complete
18:45:52 : Time elapsed during download operation: 00:00:00.902
18:45:52 : Verifying ...
18:45:52 : Read progress:
18:45:52 : Download verified successfully
18:46:09 : Disconnected from device.