-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consecutive apptrace statements not output to the JTAG console without stepping through (IDFGH-4906) (OCD-319) #149
Comments
Thanks for reporting and sorry for the inconvenience, we will look into. |
Hi @TobiasBoeschMiele!
|
I start it in the In eclipse that looks like this: |
Ahh, sorry I see. Missed this. I will check the issue. |
@TobiasBoeschMiele I can reproduce your problem.
|
It seems to be OpenOCD issue. So moved it here. |
Thanks.
I've added that to the gdb init commands in eclipse, but I cannot test it since the debug session does not fully start anymore. Do you know why? Logs of the starting and not starting debug session below: Log not using gdb commands but
Log using gdb commands which ends in a NOT working debugging session:
The entry |
Any updates on this? |
@SimonPVS @TobiasBoeschMiele Sorry, not yet. I asked a guy to have a look at it. |
@SimonPVS @TobiasBoeschMiele you can try with the latest commit. Please make sure to wait host connection before sending data. while (!esp_apptrace_host_is_connected(ESP_APPTRACE_DEST_TRAX))
vTaskDelay(1); |
Waiting for something here is not what I would like to do. Can I also ask if a connection is established and then "print" the data? I'll try that and report back. |
Yes. Once you connect before sending the first data, it should stay connected until the stop condition is met. If you don't want to block your application |
I was able to test this with commit 1d7068e4be430edd92bb63f2d922036dcf5c3cc1.
in the hello-world example code mentioned above in this issue as the first statement:
That makes the task wait forever. Without the waiting statement the example code does what it did before updating to 1d7068e4be430edd92bb63f2d922036dcf5c3cc1: It only
|
Hi @TobiasBoeschMiele , Did you update your openocd? I have re-tested with the latest openocd commit and with the idf you mentioned. It is working as expected.
|
Not intentionally. I updated esp-idf to the mentioned commit (reset hard with all submodules) and then started the tools install again. (I use the eclipse plugin and used the GUI to start the tools install) I also use a different command for debugging, too I think. In the eclipse GUI I have a debug configuration with this command: [openocdExecutable] The huzzah configuration just lists the JTAG interface and adapter speed. |
@TobiasBoeschMiele
That fix in OpenOCD is not released yet. So you need to build OpenOCD from @erhankur Am I right? |
@TobiasBoeschMiele If you are not able to build OpenOCD yourself we can upload binaries for your OS for pre-release check |
@gerekon you are right. Build from master branch is needed to validate. @TobiasBoeschMiele Regarding openocd configuration before -c part can be different according to your board. For apptrace commands you can read details from https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/app_trace.html#openocd-application-level-tracing-commands |
That would be helpful. I don't know if I need special tools for building, but I don't have administrative rights on my machine. So it might take a while.
|
We come back to check that if there is the issue persists after using the correct openocd version. Thanks. |
You can try with this windows build. |
Using this build makes the issue dissapear.
|
Yes, it will not be stable without waiting the connection. That was the lucky case. |
Thanks for your help. |
Environment
git describe --tags
to find it):v4.4-dev-4-g73db14240
xtensa-esp32-elf-gcc --version
to find it):xtensa-esp32-elf-gcc (crosstool-NG esp-2020r3) 8.4.0
Problem Description
From two consecutive apptrace instruction only the last one gets output to the JTAG console unless one steps through each instruction manually.
I also tried to set the openocd command for tracing to blocking without success.
Expected Behavior
Running the program puts out all trace data each after another without halting the program.
Actual Behavior
Running the program only puts out the trace data of the last apptrace instruction
Steps to reproduce
Code to reproduce this issue
Debug Logs
Stepping through:
Running:
Other items if possible
hello_world flash Configuration.launch.txt
hello_world debug Configuration.launch.txt
esp-huzzah-32.cfg.txt (if interesting - nothing special here I think)
The text was updated successfully, but these errors were encountered: