Skip to main content
NGajic
Associate III
July 27, 2020
Solved

CubeIDE v1.4.0 is not stopping on breakpoint

  • July 27, 2020
  • 2 replies
  • 1088 views

I'm trying to make FreeRTOS application which is involving ADC and sending messages via virtual UART to Cortex A7. So I began with example called OpenAMP_FreeRTOS_echo in the cube fw version 1.2.0. That example worked good. I saw echo on /dev/ttyRPMSG0. Then I tried to incorporate ADC into that code but without success (I made succes with ADC + virtual UART without using FreeRTOS, but I want to make FreeRTOS working). I had a lot of trouble using System Workbench in terms of ST-Link detection (I always had to change COM port in the Debug Configuration) and I read on this forum that there were troubles in using FreeRTOS and those troubles are solved in Cube IDE 1.2.1.

https://community.st.com/s/question/0D50X0000BI0vctSQB/freertos-does-not-run-on-stm32mp1-m4-core

So I recently switched to Cube IDE v1.4.0, but there I have trouble on stopping on breakpoint. I placed break point on lines after main which must be executed (i.e. HAL_Init), but the debug is not stopped.

Thanks in advance for the answer,

Nenad

This topic has been closed for replies.
Best answer by Olivier GALLIEN

Hi @NGajic​ 

In production mode, where M4 code is launched by A7, there is a delay between M4 core start and debugger attachment.

So all breakpoint set "too early" in the code are ignored.

Please confirm you can set breakpoint further in your code.

Usual tips to w/a this is either to add a sleep of few seconds at beginning of your main, or create while loop you can then bypass with debugger afterward.

Olivier

2 replies

Olivier GALLIEN
Olivier GALLIENBest answer
Technical Moderator
July 27, 2020

Hi @NGajic​ 

In production mode, where M4 code is launched by A7, there is a delay between M4 core start and debugger attachment.

So all breakpoint set "too early" in the code are ignored.

Please confirm you can set breakpoint further in your code.

Usual tips to w/a this is either to add a sleep of few seconds at beginning of your main, or create while loop you can then bypass with debugger afterward.

Olivier

Olivier GALLIEN In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
NGajic
NGajicAuthor
Associate III
July 27, 2020

Hi OlivierG(iroud), :)

Thanx for your fast answer. Yeah, debugger stops after some time and I guessed that there is something in debugger. I will add delay.

Nenad