Here is the code
Code: Select all
#include <Arduino.h>
#include "esp_log.h"
#include "esp_app_trace.h"
void setup() {
esp_apptrace_init();
}
}
when I compile in vscode, the error log would be:
Code: Select all
Linking .pio\build\esp32doit-devkit-v1\firmware.elf
c:/users/vahid/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:\Users\vahid\.platformio\packages\framework-arduinoespressif32\tools\sdk\esp32\lib\libapp_trace.a(app_trace.c.obj):(.literal.esp_apptrace_init+0x10): undefined reference to `esp_apptrace_jtag_hw_get'
c:/users/vahid/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:\Users\vahid\.platformio\packages\framework-arduinoespressif32\tools\sdk\esp32\lib\libapp_trace.a(app_trace.c.obj):(.literal.esp_apptrace_init+0x14): undefined reference to `esp_apptrace_uart_hw_get'
c:/users/vahid/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:\Users\vahid\.platformio\packages\framework-arduinoespressif32\tools\sdk\esp32\lib\libapp_trace.a(app_trace.c.obj): in function `esp_apptrace_init':
/Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/app_trace/app_trace.c:37: undefined reference to `esp_apptrace_jtag_hw_get'
c:/users/vahid/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/app_trace/app_trace.c:43: undefined reference to `esp_apptrace_uart_hw_get'
collect2.exe: error: ld returned 1 exit status
*** [.pio\build\esp32doit-devkit-v1\firmware.elf] Error 1
Also please visit this one
https://community.platformio.org/t/how- ... 32/35816/6