2019-05-27 08:00 PM
I am trying to debug with the STM32CubeIDE but it fails with message:
...
Verifying ...
Download verified successfully
Target unknown error 19
Error in initializing ST-LINK device.
Reason: Unknown. Please check power and cabling to target.
Failed to restart ST-LINK connection
Error in STM32CubeProgrammer
Target is not responding, retrying...
Target is not responding, retrying...
...
see full STM32CubeProgrammer.log attached.
I am using the STM32H753I-EVAL board and a Linux PC (Ubuntu 1604 LTS).
However, debugging is successful with Atollic TrueStudio so I think the hardware is ok and the problem is with the STM32CubeIDE.
I have also attached .launch and .prefs files from working and non working environments for comparison:
STM32CubeIDE (fails):
cube_ide_eval_board Debug.launch
org.eclipse.cdt.core.prj-cube_ide_eval_board.prefs
Atollic TrueStudio (succeeds):
eval_H7cube.elf.launch
com.atollic.truestudio.debug.hardware_device.prefs
I would like to get this running and use the latest tools.
However, I'm new to the STM32 hardware and IDE's and not sure what the benefits of STM32CubeIDE over Atollic TrueStudio are?
2019-05-30 04:26 AM
I'm facing a similar issue with the CubeIDE. I'm using a Nucleo F103RB board which gets flashed by the IDE but then GDB quits, so I'm unble to debug. I have tried reinstalling the CubeIDE but the problem stays as is. Really not the experience one expects from an officially supported tool. Hope ST resolves this soon.
2019-06-08 01:21 AM
Hi Ankit,
I'm new to STM32 and IDE. Are you able to program through CubeiDE?
2019-06-16 02:47 AM
Hi,
I'm also facing this problem. New H743 project with just"Trace Ansynchronous SW" enabled and no custom code. Debugging fails in CubeIDE whereas using CubeMX and TrueStudio works. Debugger is a ST-LINK/V2 (STM32F407 Discovery board) in my case.
2019-06-17 01:25 PM
Same issue here. Debugging in CubeIDE never works, with GDB quitting almost immediately, while the identical code debugs without issue in TrueStudio. It's a huge pain for the projects I've created new in CubeIDE when I have to recreate them in TrueStudio to debug them.
I was close to spinning up a Linux box with one of the "officially supported" distro/versions, but the OP is running into the same issue on one such distro.
2019-06-19 07:36 AM
Update: I installed CubeIDE 1.0.1 and had all sorts of trouble with the installers and dependencies on OpenSUSE. I didn't want to hack my way through making it work again, so I installed Fedora (30). The 1.0.1 update seems to have fixed the debugging issue I had, thought it's hard to be certain it was the update, and not my move to Fedora that fixed it.
2019-06-19 09:02 AM
Reading Kyle's response above, I updated to CubeIDE 1.0.1 on Windows 10 and it still doesn't work. This update was made from within the CubeIDE I'll try a clean install sometime. Here's the dump from the console:
STMicroelectronics ST-LINK GDB server. Version 5.2.3
Copyright (c) 2019, STMicroelectronics. All rights reserved.
Starting server with the following options:
Persistent Mode : Disabled
Logging Level : 1
Listen Port Number : 61234
Status Refresh Delay : 15s
Verbose Mode : Disabled
SWD Debug : Enabled
Waiting for debugger connection...
Debugger connected
-------------------------------------------------------------------
STM32CubeProgrammer v2.1.0
-------------------------------------------------------------------
Log output file: C:\Users\Ankit\AppData\Local\Temp\STM32CubeProgrammer_a15920.log
ST-Link Server is running on port : 7184
ST-LINK SN : 0670FF363732594D43214619
ST-LINK FW : V2J34M25
Voltage : 3.25V
SWD freq : 4000 KHz
Connect mode: Under Reset
Reset mode : Hardware reset
Device ID : 0x410
Device name : STM32F101/F102/F103 Medium-density
Flash size : 128 KBytes
Device type : MCU
Device CPU : Cortex-M3
Memory Programming ...
Opening and parsing file: ST-LINK_GDB_server_a15920.srec
File : ST-LINK_GDB_server_a15920.srec
Size : 96 Bytes
Address : 0x08000000
Erasing memory corresponding to segment 0:
Erasing internal memory sector 0
Download in Progress:
File download complete
Time elapsed during download operation: 00:00:00.442
Verifying ...
Download verified successfully
Error! Failed to read target status
Debugger connection lost.
Shutting down...
For now though I'm sticking with using the CubeMX and TrueStudio 9.3. I'm not sure what else could be broken internally and having to migrate to TrueStudio mid-way through a project is a pain that I can live without.
2019-06-19 04:15 PM
Updates:
I tried the latest CubeIDE 1.0.1 and it didn't fix anything for me.
However, I received a STM32H753I-EVAL2 board today and success!, seems to debug properly after a quick test. As far as I know the only significant difference between the boards is the upgrade from ST-LINK/V2-1 to ST-LINK/V3E debugger.
So it looks like the CubeIDE doesn't support the V2-1 debugger.
2019-06-21 11:51 AM
Well, I spoke too soon. Debugger is still broken for me too. I've successfully launched and run the debug session several times, but today I'm facing the same error as I did with 1.0.0. Once again, identical code debugs fine in TrueStudio.
Edit: I never made it clear in my earlier posts that the error I'm facing is a little different than the OP. See below. Forgive me if I've diverted the thread -- but the big picture is the same: Broken debug.
New UI allocated
GNU gdb (GNU Tools for STM32 7-2018-q2-update.20190328-1800) 8.1.0.20180315-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-linux-gnu --target=arm-none-eabi".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
(gdb)
Program stopped.
Reset_Handler () at ../Startup/startup_stm32f412ceux.s:78
78 ldr sp, =_estack /* set stack pointer */
2019-07-12 10:14 AM
Hello,
Seems that issue is linked to the ST-Link firmware version for the ST-Link v 2-1 helped firmware version V2J33M25