ESP32 "Logging to Host via JTAG" on C++ project

itsMeBrice
Posts: 3
Joined: Thu Mar 14, 2019 1:25 pm

ESP32 "Logging to Host via JTAG" on C++ project

Postby itsMeBrice » Fri Oct 25, 2019 12:00 pm

Good day,
I'm trying to reroute the ESP logging functionality through the JTAG interface. While trying to implement it in my own project I quickly defaulted to the "app_trace_to_host_example". This works just fine as long as i don't try to change it to C++.
The only changes i do is rename the file "app_trace_to_host_example_main.c" to "app_trace_to_host_example_main.cpp". Add the C guard to "app_main" as such (on line 88):
  1. extern "C" void app_main()
and to be able to compile the project I also need the C guards around the include of "esp_app_trace.h" as such:
  1. extern "C" {
  2.     #include "esp_app_trace.h"
  3. }
These changes suffice for me to no longer get any logging from JTAG.
Does anybody know how I can get this functionality in a C++ project?
Thanks in advance!
Brice

Who is online

Users browsing this forum: Google [Bot] and 139 guests