Questions tagged [openocd]

OpenOCD stands for Open On Chip Debugger and is a program used to debug embedded platforms, mostly via JTAG.

286 questions
5
votes
3 answers

How to use OpenOCD to talk to two STM32 boards at once?

Let's say I've got two STM32's, and I'm using this programmer here. I want to connect to both of them and debug/reflash/itterate independently. So, the setup I have is as follows: HW PC |-> USB1 -> ST-LINK-Programmer1 -> STM32_Board1 |-> USB2…
testname123
  • 1,061
  • 3
  • 20
  • 43
5
votes
1 answer

OpenOCD debugging multiple devices at once

I am trying to debug multiple devices at once with openocd on eclipse. I have 2x STM32F303 discovery borards, I have set the hla_serial flag to a proper board, but still no luck. Separate boards are doing ok, but when trying to debug it's Eclipse…
Danijel
  • 817
  • 1
  • 17
  • 31
4
votes
1 answer

Eclipse GDB "init" and "run" settings for ARM LPC1768 using OpenOCD?

I finally figured out how to get code running on this LPC1768 mini board, however now I'm trying to get debugging working. The toolchain I'm using is: Yagarto + Eclipse (Indigo) (w/ GDB Hardware Debugger) + OpenOCD. My JTAG interface is: Bus Blaster…
Craig
  • 4,323
  • 2
  • 29
  • 32
4
votes
1 answer

why am I getting a communication failure when trying to connect with stlink-v2 using openocd

I'm trying to connect to an 'stm32' 'bluepill' using an stlink-v2 to write some code to it Whenever I run openocd, it fails to connect My openocd.cfg file looks like this source [find interface/stlink-v2.cfg] source [find target/stm32f3x.cfg] when…
Martin
  • 41
  • 1
  • 3
4
votes
1 answer

Using openOCD to extract ETB traces on Cortex-M (STM32F4)

STM32F4 discovery (Cortex-M4) has ETB, a buffer storing instruction traces. How can I use OpenOCD and on-chip st-link debugger to pull out the traces from ETB? I am little confused between SWO/SWD. What should I be using? Also, do I need any…
4
votes
1 answer

how to program the STM32 flash using openOCD and gdb

I'm using an Olimex ARM-USB-OCD dongle with openOCD and GDB to program and debug an stm32f103 micro. The IDE I'm using came from the Olimex dev-kit CD and makes use of eclipse ganymede. I can load a small program into the RAM and step through the…
mksuth
  • 1,999
  • 4
  • 17
  • 24
4
votes
1 answer

JTAG adapter ULINK-ME and openocd (on ArchLinux)

I installed Openocd from opfficial Arch Linux repositories today and am now trying to use it with my JTAG adapter ULINK-ME. I found out that ULINK-ME uses CMSIS-DAP debugging firmware. Openocd has CMSIS-DAP drivers and should therefore be able to…
71GA
  • 1,132
  • 6
  • 36
  • 69
4
votes
1 answer

Stm32f4discovery - OpenOCD - telnet uploading demo program

I have problem trying to upload demo program into fresh stm32f4discovery board, this is what i'm doing: Connect board to computer openocd -f board/stm32f4discovery.cfg telnet localhost 4444 Open On-Chip Debugger > reset init target state:…
mucka
  • 1,286
  • 3
  • 20
  • 36
4
votes
4 answers

Using OpenOCD for debugging STM32F1xx Discovery board (ST-Link)

I got some problems getting OpenOCD to communicate with my STM32F100RB Discovery board (it uses ST-Link). I am not used to working with open source tools, and therefore I've never had problems programming and debugging my embedded platforms. In the…
Jolle
  • 1,336
  • 5
  • 24
  • 36
3
votes
2 answers

GDB Disconnects when trying to debug via openocd

I'm on windows 10 trying to debug my bluepill (STM32f103C8) board using a stlink, openocd, and vscode. I get this pop up: "OpenOCD GDB Server Quit Unexpectedly. See gdb-server output for more details." And this message in the terminal: Open…
Ed Pizzella
  • 61
  • 1
  • 6
3
votes
5 answers

arm-none-eabi-gdb and openocd: Malformed response to offset query, qOffsets?

I am attempting to use GDB to debug a Stellaris LM3S8962 Evaluation board using OpenOCD and the GNU ARM toolchain (installed with MacPorts), whenever I set the remote target in GDB it always returns "Malfomred response to offset query, qOffsets". …
azurewraith
  • 378
  • 1
  • 3
  • 13
3
votes
1 answer

Do OpenOCD + STLINK-V3SET support debugging multiple controllers in daisy chain config?

I'd like to get a multi-core debugging running with my STLINK adapter. I've got experiences in debugging with other tools (e.g., uTrace/Trace32 from Lauterbach). Now, I'd like to setup a multi-core arrangement as a hobby project at home - where I…
HelpingHand
  • 1,294
  • 11
  • 27
3
votes
1 answer

ARM Cortex M detect if debugger is in Run or Debug mode

There is a proven way to detect whether a debugger is connected on Cortex-M, as seen here. I used to as a way to automatically set a breakpoint when I am in a debug session: void autobreak() { if (CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk) …
Ken Lin
  • 986
  • 1
  • 8
  • 22
3
votes
3 answers

Eclipse/GDB: How to set an automatic breakpoint after hardware reset?

I am using a self-built embedded IDE with Eclipse and GDB - pretty much what this website describes: https://gnu-mcu-eclipse.github.io/ When I use OpenOCD or any other Debug Config (like SEGGER JLink) to flash my STM32F407 hardware, it breaks at the…
3
votes
2 answers

Debug remotely on STM32CubeIDE with an STM32 eval board

I want to setup the following environment: I've got a STM32H753I-EVAL2 eval board, connected on a Windows PC. Until now I was developping and debugging locally on this PC with STM32CubeIDE. For several reasons my code source is on a Linux server…
Guillaume Petitjean
  • 2,408
  • 1
  • 21
  • 47
1
2
3
19 20