mirror of
https://github.com/espressif/esp-idf.git
synced 2025-09-30 19:19:21 +00:00
app_trace: perform initialization using ESP_SYSTEM_INIT_FN
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#include "esp_log.h"
|
||||
#include "esp_app_trace.h"
|
||||
#include "esp_app_trace_port.h"
|
||||
#include "esp_private/startup_internal.h"
|
||||
|
||||
#ifdef CONFIG_APPTRACE_DEST_UART0
|
||||
#define ESP_APPTRACE_DEST_UART_NUM 0
|
||||
@@ -75,6 +76,11 @@ esp_err_t esp_apptrace_init(void)
|
||||
return ESP_OK;
|
||||
}
|
||||
|
||||
ESP_SYSTEM_INIT_FN(esp_apptrace_init, ESP_SYSTEM_INIT_ALL_CORES, 115)
|
||||
{
|
||||
return esp_apptrace_init();
|
||||
}
|
||||
|
||||
void esp_apptrace_down_buffer_config(uint8_t *buf, uint32_t size)
|
||||
{
|
||||
esp_apptrace_channel_t *ch;
|
||||
|
@@ -12,6 +12,7 @@
|
||||
|
||||
#include "esp_app_trace.h"
|
||||
#include "esp_log.h"
|
||||
#include "esp_private/startup_internal.h"
|
||||
|
||||
const static char *TAG = "segger_rtt";
|
||||
|
||||
@@ -288,4 +289,17 @@ int SEGGER_RTT_ConfigDownBuffer(unsigned BufferIndex, const char* sName, void* p
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*************************** Init hook ****************************
|
||||
*
|
||||
* This init function is placed here because this port file will be
|
||||
* linked whenever SystemView is used.
|
||||
*/
|
||||
|
||||
ESP_SYSTEM_INIT_FN(sysview_init, BIT(0), 120)
|
||||
{
|
||||
SEGGER_SYSVIEW_Conf();
|
||||
return ESP_OK;
|
||||
}
|
||||
|
||||
|
||||
/*************************** End of file ****************************/
|
||||
|
Reference in New Issue
Block a user