STM32CubeProgrammer connection lost while updating firmware


 

Hi,

I have a NanoVNA H4 and before succeeded in uploading firmware 1.2.29
Now I try to do the same with v 1.2.40 but when the programmer starts after few seconds connection is lost (see file output log).
Results in a blanc screen when trying to switch the NanoVNA on...

--log--

10:17:14 : STM32CubeProgrammer API v2.17.0 | Windows-64Bits
10:17:20 : UR connection mode is defined with the HWrst reset mode
10:17:20 : USB speed : Full Speed (12MBit/s)
10:17:20 : Manuf. ID : STMicroelectronics
10:17:20 : Product ID : STM32 BOOTLOADER
10:17:20 : SN : 205430672033
10:17:20 : DFU protocol: 1.1
10:17:20 : Board : --
10:17:20 : Device ID : 0x0422
10:17:21 : UPLOADING OPTION BYTES DATA ...
10:17:21 : Bank : 0x00
10:17:21 : Address : 0x1ffff800
10:17:21 : Size : 16 Bytes
10:17:21 : UPLOADING ...
10:17:21 : Size : 1024 Bytes
10:17:21 : Address : 0x8000000
10:17:21 : Read progress:
10:17:21 : Data read successfully
10:17:21 : Time elapsed during the read operation is: 00:00:00.004
10:17:44 : Memory Programming ...
10:17:44 : Opening and parsing file: NanoVNA.H4.v1.2.29.hex
10:17:44 : File : NanoVNA.H4.v1.2.29.hex
10:17:44 : Size : 87.37 KB
10:17:44 : Address : 0x08000000
10:17:44 : Download in Progress:
10:17:45 : File download complete
10:17:45 : Time elapsed during download operation: 00:00:00.477
10:17:45 : Verifying ...
10:17:45 : Read progress:
10:17:45 : Error: Data mismatch found at address 0x0800523A (byte = 0x00 instead of 0xDF)
10:17:45 : Error: Download verification failed
10:17:45 : RUNNING Program ...
10:17:45 : Address: : 0x08000000
10:17:45 : Start operation achieved successfully
10:17:45 : Warning: Connection to device 0x422 is lost
10:17:45 : Disconnected from device.

Any ideas how to recover ...
Thanks, Phil ON4VP


 

Yes, it appears that you may have the "skip flash erase before programming" box checked. There are no lines in the log showing that it erased the flash first. So uncheck that box. Alternately, choose the "Full chip erase" button in the center panel before selecting the "Start Programming" button. Also, you have the wrong file selected: you are trying to load the v1.2.29.hex file; you need to use the v1.2.40.bin file. This programmer 'likes' the .bin files rather than the .hex or .dfu files.
Stan


 

Stan,

Thanks, that did the job !! new firmware installed

Phil


 

Did you already try the common things like using slower connection speed, different USB cable, different USB port etc?