Saturday, February 17th 2018, 8:22pm UTC+1

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Maxime

Beginner

Date of registration: Jul 24th 2017

Posts: 5

1

Tuesday, July 25th 2017, 9:30am

[SOLVED] Get values and adresses from ETM

Hi,


I need to do specifics experiments on MCUs. This implies modifying, by an external mean the data processed by the MCU.

So I want to know the actual values and addresses executed in the core, by using a J-Trace probe.
I saw in ETM architecture specification that you can can enable both value tracing and address tracing simultaneously.

Does J-Link tools allow controlling the type of tracing performed by the ETM and getting the linked raw data?
Secondly, can we configure the filtering, to cover the targeted instructions?

My setup:
Probes: J-Trace for ARM cortex M
Target: STM32F417

Regards,
Maxime

SEGGER - Nino

Super Moderator

Date of registration: Jan 2nd 2017

Posts: 693

2

Tuesday, July 25th 2017, 10:46am

Hello Maxime,

Thank you for your inquiry.

Quoted

Does J-Link tools allow controlling the type of tracing performed by the ETM and getting the linked raw data?

Our J-Trace tools configure ETM to output all trace data possible. Whatever the MCU then outputs gets analyzed by our software.
So whatever and whenever something happens on the target MCU you can see it in the raw trace.

Quoted

Secondly, can we configure the filtering, to cover the targeted instructions?

When using our debugging software Ozone you can simply right click on the instruction trace window and export its content to a text file and analyze it from there.
We have a example project ready for your target device that should run out of the box so you can use it to get a feeling for tracing possibilities.
You can download it here: https://wiki.segger.com/Tracing_on_ST_ST…eference_Board)

Keep in mind that if you are using "only" a J-Trace for Cortex-M and no J-Trace PRO you miss out on some interesting features like streaming trace, adjustable trace sampling times etc.
So when using a "regular" J-Trace you have to pause your debugging to be able to analyze the current trace data stored in the J-Trace. That way you can only capture a couple of seconds at a time.
For "infinite live" trace you will have to use a J-Trace PRO.

Best regards,
Nino

Maxime

Beginner

Date of registration: Jul 24th 2017

Posts: 5

3

Tuesday, July 25th 2017, 1:58pm

Thank you for your answer.

In trace exported file,from Ozone, what is the mean of the "Encoding" column?

In a second time, I need to do the trace acquisitions using a external script.
Is it possible to automatize the trace acquisition with ozone or an other software?

Best regards,
Maxime

SEGGER - Nino

Super Moderator

Date of registration: Jan 2nd 2017

Posts: 693

4

Tuesday, July 25th 2017, 2:14pm

Hello Maxime,

Quoted

In trace exported file,from Ozone, what is the mean of the "Encoding" column?

This is the encoded Opcode and Operands that gets output by the ETM.
In the columns "Opcode" and "Operands" you will see what instruction it is.

Quoted

In a second time, I need to do the trace acquisitions using a external script.
Is it possible to automatize the trace acquisition with ozone or an other software?

Currently an automated process is not possible over JLink scripts or Ozone commands.
For the J-Trace PRO there is currently a feature in work that you can directly dump the live streaming trace data onto your hard drive.
This is currently under internal testing and will be released soon.

Best regards,
Nino

Maxime

Beginner

Date of registration: Jul 24th 2017

Posts: 5

5

Tuesday, July 25th 2017, 4:57pm

Tank you Nino,

Does the J-Link SDK support tracing?

Regards,
Maxime

SEGGER - Nino

Super Moderator

Date of registration: Jan 2nd 2017

Posts: 693

6

Tuesday, July 25th 2017, 5:13pm

Hello Maxime,

Yes the J-Link SDK does support tracing. You also get our simplified trace analyzer with it.
For more advanced trace analyzing you will need to write your own trace analyzing software or wait until Ozone supports automatic instruction trace exporting.
Please note that with the J-Trace no continuous tracing is possible so you will have to pause the application, flush the trace buffer, save trace data, run application again, rinse and repeat.
To get continuous tracing you will have to use a J-Trace PRO.

Best regards,
Nino

Maxime

Beginner

Date of registration: Jul 24th 2017

Posts: 5

7

Wednesday, July 26th 2017, 3:13pm

Hello,

To resolve my problem of automation I tried the gdb server.
What kind of traces can i get with gdb server.
I tested the "qSeggerSTRACE" commands and I only received the instructions addresses.
How can I configure the traces with the command "qSeggerSTRACE:config". I don't have acces to UM08002.

Regards,
Maxime

SEGGER - Nino

Super Moderator

Date of registration: Jan 2nd 2017

Posts: 693

8

Wednesday, July 26th 2017, 5:17pm

Hello Maxime,

Quoted

How can I configure the traces with the command "qSeggerSTRACE:config". I don't have acces to UM08002.


To use this feature you will have to have access to the J-Link SDK.
I talked to our marketing department and we would like to make the SDK available to your university.
Would it be ok for you if we contact you on the email you have entered in your forum profile?

Best regards,
Nino

Maxime

Beginner

Date of registration: Jul 24th 2017

Posts: 5

9

Thursday, July 27th 2017, 9:56am

Hello,

Yes, you can contact me by email.

Best regards,
Maxime