2024-06-25 11:45 AM - edited 2024-06-25 11:46 AM
Hi,
We found STM32 programmer CLI report -15872 error in VSCode terminal, but same command works perfectly okay in regular terminal. Can you check what causes the issue?
Here is the command we used in the terminal:
/Applications/STMicroelectronics/STM32Cube/STM32CubeProgrammer/STM32CubeProgrammer.app/Contents/MacOs/bin/STM32_Programmer_CLI -c port=SWD speed=fast per=e key=/Volumes/Work/workspace/Gen1-Product/Common/keys/key_1_root.pem cert=/Volumes/Work/workspace/Gen1-Product/Common/Certificates/cert_root.b64 pwd=/Volumes/Work/workspace/Gen1-Product/Common/Binary/password.bin debugauth=1
And the error message is (Note: the path is manually edited to remove sensitive info)
-------------------------------------------------------------------
STM32CubeProgrammer v2.16.0
-------------------------------------------------------------------
Permission request submitted : e
Key file path submitted : /Volumes/Work/workspace/Gen1-Product/Common/keys/key_1_root.pem
Certificate file path submitted : /Volumes/Work/workspace/Gen1-Product/Common/Certificates/cert_root.b64
Password file path submitted : /Volumes/Work/workspace/Gen1-Product/Common/Binary/password.bin
Start Debug Authentication Sequence
Open SDM Lib
SDMOpen : 609 : open : SDM API v1.0
SDMOpen : 610 : open : SDM Library version v1.1.0
open_comms : 501 : open : Asserting target reset
open_comms : 505 : open : Writing magic number
open_comms : 515 : open : De-asserting target reset
open_comms : 567 : open : Communication with the target established successfully
response_packet_lock
discovery: permission if authorised...........:(a) ==> Full Regression
discovery: permission if authorised...........:(b) ==> To TZ Regression
discovery: permission if authorised...........:(c) ==> Level 3 Intrusive Debug
discovery: permission if authorised...........:(d) ==> Level 2 Intrusive Debug
discovery: permission if authorised...........:(e) ==> Level 1 Intrusive Debug
discovery: permission if authorised...........:(f) ==> Level 3 Intrusive Non Secure Debug
discovery: permission if authorised...........:(g) ==> Level 2 Intrusive Non Secure Debug
discovery: permission if authorised...........:(h) ==> Level 1 Intrusive Non Secure Debug
SDMOpen : 609 : open : SDM API v1.0
SDMOpen : 610 : open : SDM Library version v1.1.0
open_comms : 501 : open : Asserting target reset
open_comms : 505 : open : Writing magic number
open_comms : 515 : open : De-asserting target reset
open_comms : 567 : open : Communication with the target established successfully
[00%] discovery command
[10%] sending discovery command
[20%] receiving discovery
response_packet_lock
[40%] loading credentials
/Volumes/Work/workspace/Gen1-Product/Common/keys/key_1_root.pem
/Volumes/Work/workspace/Gen1-Product/Common/Certificates/cert_root.b64
import_private_key : 129 : error : sdm : Error loading key file ' (error -15872)'
Error:
Debug Authentication Failed
Thank you.
2024-07-04 05:50 AM
Did you fix it? I'm having the same problem as you
2024-07-11 09:57 AM
No. I have not. Still waiting for ST's reply. This may be a VScode terminal implementation. But, I don't have enough information to tell.