2021-02-09 01:30 AM
Hi everybody, I recently bought a STM32F103RBTx and it worked perfectly at the first run.
Today I tried to use it again and I meet a lot of problems.
When I launch the ST-Link Utility, I have a message saying " Can not read memory! Disable Read Out Protection and retry."
Then I go to Target > Option Bytes and I set "Read Out Protection" to "Disabled". When I press apply I have this error again: "Could not set Option bytes! Please reset the target and retry." I close the message and the following one appears: "Can not connect the device".
I really don't understand... I'm a beginner with STM32, I did a lot of researches but nothing helped me...
I would be grateful if you could help me...
Edgar
2021-02-09 02:32 AM
Hello @ESchu.2 and welcome to the STM32 Community =)
Check the USB cable and try to upgrade the ST-Link firwmare through ST-Link utility (go to ST-LINK>firmware update) or this Link STSW-LINK009.
Maybe you can try with the STM32CubeProgrammer and check if that recognizes it.
Please tell me if that solve the issue.
Imen
2021-02-09 02:48 AM
I already changed my cable et upgraded the firmware. The CubeIDE say this when I try to debug:
"Error in final launch sequence:
Failed to execute MI command:
target remote localhost:61234
Error message from debugger back end:
Remote failure reply: E31
Failed to execute MI command:
target remote localhost:61234
Error message from debugger back end:
Remote failure reply: E31
Remote failure reply: E31"
2021-02-09 04:20 AM
Some custom board? NRST connected to debugger?
Can you try with BOOT0 pulled high?
2021-02-09 04:22 AM
STM32 Cube Programmer, not CubeMX or CubeIDE
2021-02-09 04:30 AM
CubeProgrammer displays this:
13:29:01 : STM32CubeProgrammer API v 2.6.0
13:29:01 : ST-LINK error (DEV_CONNECT_ERR)
13:29:11 : ST-LINK SN : 066BFF555751836687031330
13:29:11 : ST-LINK FW : V2J37M26
13:29:11 : Board : NUCLEO-F103RB
13:29:11 : Voltage : 2.07V
13:29:11 : SWD freq : 4000 KHz
13:29:11 : Connect mode: Normal
13:29:11 : Reset mode : Software reset
13:29:11 : Device ID : 0x410
13:29:11 : Revision ID : Rev X
13:29:11 : UPLOADING OPTION BYTES DATA ...
13:29:11 : Bank : 0x00
13:29:11 : Address : 0x4002201c
13:29:11 : Size : 8 Bytes
13:29:11 : Bank : 0x01
13:29:11 : Address : 0x1ffff800
13:29:11 : Size : 16 Bytes
13:29:11 : UPLOADING ...
13:29:11 : Size : 1024 Bytes
13:29:11 : Address : 0x8000000
13:29:11 : Read progress:
13:29:11 : Error: Data read failed
2021-02-09 04:31 AM
Not a custom board and I don't know if NRST is connected to debugger...
I saw that a lot, what is BOOT0 pulled high and how do I do that ?
2021-02-18 07:28 AM
Hi @ESchu.2 ,
Do you have still this problem to solve?
Are you able to manipulate the option bytes from the ST-Link utility ? uncheck read protection byte ?
Imen