Loading...
 

System Workbench for STM32


From v2.5 debugging multiple targets no longer works (Windows)

Setup:

  1. Two identical boards (custom design) that each have an STM32F407VGT6 processor.
  2. Two ST-LINK/V2 programmers.
  3. Windows 10.


I’ve tested with Ac6 v2.4, v2.5 and v2.6. Only v2.4 works for me.


The attached zip contains two text files:

  1. Ac6 v2.4 - connecting multiple targets.txt - showing the openocd output for both targets with a successful connection.
  2. Ac6 v2.5 - connecting multiple targets.txt - showing the openocd output for both targets where only the first connection is successful.


The v2.4 log file shows the same output for both connections, apart from the “Error: libusb_open() failed with LIBUSB_ERROR_ACCESS” messages that appears when (I assume) the second connection tries to use the first debugger before moving on to the second one.

In the v2.5 log file, it can be seen that:

  1. The first device connection appears to be the same as in v2.4 (up until the second connection is opened).
  2. The second device openocd console shows it connects to the debugger (reads target voltage, number of breakpoints, etc.), but then nothing else occurs on that openocd console.
  3. The second device connection somehow adds the following lines to the first device’s openocd console:
    1. Info : accepting ‘telnet’ connection on tcp/4444
    2. Error: error during read: Bad file descriptor
    3. Info : dropped ‘telnet’ connection

Something perhaps noteworthy is that in a successful connection, the consoles show the following:

  1. Console 1
    • Info : accepting ‘gdb’ connection on tcp/3333
  2. Console 2
    • Info : accepting ‘gdb’ connection on tcp/4444


But for the unsuccessful attempt they show:

  1. Console 1
    • Info : accepting ‘gdb’ connection on tcp/3333
    • Info : accepting ‘telnet’ connection on tcp/4444
  2. Console 2


Why telnet suddenly?


The debugger configuration script contains the following:

source find interface/stlink.cfg

set WORKAREASIZE 0x20000
transport select “hla_swd”
set CHIPNAME STM32F407VGTx

set ENABLE_LOW_POWER 1

set STOP_WATCHDOG 1

set CLOCK_FREQ 4000

reset_config srst_only srst_nogate connect_assert_srst
set CONNECT_UNDER_RESET 1

source find target/stm32f4x.cfg


Is this a bug in Ac6, or did I somehow get away with a configuration that is no longer supported?

At the moment I’m just sticking to v2.4 and ignoring the “theres a new version” message that pops up every now and then...

Regards,
Dawid