Pio run --target upload fail

Hi, I have problem when I upload my project on stm board.
I know its common error which is not solved yet and mentioned here, solution 3, and tried the solution provided in doc but still not working.

Here is my result:
Processing nucleo_l432kc (platform: ststm32; board: nucleo_l432kc; framework: stm32cube)

PackageManager: Installing tool-stm32duino @ ~1.0.1
Downloading [####################################] 100%
Unpacking [####################################] 100%
PackageManager: Installing toolchain-gccarmnoneeabi @ >=1.60301.0,<1.80000.0
Downloading [####################################] 100%
Unpacking [####################################] 100%
PackageManager: Installing tool-openocd @ ~2.1000.0
Downloading [####################################] 100%
Unpacking [##########################----------] 73% 00:00:02
Unpacking…
Warning! Package Mirror: [Errno 22] invalid mode (‘wb’) or filename: ‘C:\Users\fiest\.platformio\packages\_tmp_installing-k2frj6-package\scripts\target\1986\xd0\xb2\xd0\xb51\xd1\x82.cfg’
Looking for another mirror…
Downloading [####################################] 100%
Unpacking [##########################----------] 73% 00:00:02
Unpacking…
Warning! Package Mirror: [Errno 22] invalid mode (‘wb’) or filename: ‘C:\Users\fiest\.platformio\packages\_tmp_installing-rdiirh-package\scripts\target\1986\xd0\xb2\xd0\xb51\xd1\x82.cfg’
Looking for another mirror…
Error: Could not install ‘tool-openocd’ with version requirements ‘~2.1000.0’ for your system ‘windows_amd64’.

Please try this solution → Redirecting...

Practically the same problem as in OpenOCD installation Issue - #3 by mstsai. OpenOCD installation seem to be broken currently.

In the meantime, please use

platform = ststm32@5.4.2

or 5.4.1.

1 Like

Thanks for reply but still not working with same error message.
Tried both .1, .2
any idea please?

and I just tried ststm32 version as 5.1.0 and it works.
the version of openocd of this ststm32 version is ~1.1000.0.
anyway thanks for your help @maxgerhardt

1 Like