Porting Tracelyser to AWS Free RTOS Kernel

Hello,

I’m trying to use the Tracelyser in AWS-Kernel

I use idf version 4.2 on my Esp32.

When I build my project,
I can see the following screen. As you can see in the highlighted section of 3rd party libraries,
How to include tracelyser.

Regards,
Surender Sampath

The Percepio website contains a lot of documentation, including quick start guides.

Hello Surender. We have support for ESP32 since Tracealyzer v4.5. Make sure to read Section 2 in the user manual (under help) and there is also a special section about the ESP32 support. Search for ESP32 in the user manual viewer and it should be easy to find.

Hi @johankraft ,

I did get in touch with the technical staff at Perceptio and turns out the user manual doesn’t give us directions in a straight forward way to use Tracelyser in the AWS version of FreeRTOS.
Its meant for either a ESP Project or a standard FreeRTOS Kernel.

If you are talking about just the kernel then the “AWS version” of FreeRTOS is the standard version - that is - it is the one in the FreeRTOS org in github. The WinSim demo in the FreeRTOS download demonstrates the Percepio trace.

@rtel , @johankraft

Thank you for the reply. The user manuals focus on the ESP32 is for a IDF-FreeRTOS project and clearly doesn’t work with the AFR kernel. There are instructions on the missing configuration and it needs to be updated.

Also, the third party library of Tracelyser withing the afr free rtos project is outdated and is never included in the cmakelists for it to actually build that as a component. I could not find any instructions on how to build a 3rd party component into my project.

The Tracelyser asks me to include “TraceRecorder.h” in the freertos config.
But the error is that of missing TraceRecorder.h file as I’m not able to tell the linker how to include them.

These are my steps below.

  1. Copied the all the files from the FreeRTOS/TraceRecorder into freertos\libraries\3rdparty\tracealyzer_recorder

  2. Modified the freertos\libraries\3rdparty\CMakeLists.txt as below :

  3. Modified the freertos\libraries\Cmakelists.txt
    image

  4. Changed freertos\libraries\3rdparty\tracealyzer_recorder\config\trcConfig.h as below

  5. TRC_CFG_HARDWARE_PORT TRC_HARDWARE_PORT_XTensa_LX6

  6. Removed the “Include processor header file” line in trcConfig.h and “include sdkconfig.h”

  7. Modified freertos\libraries\3rdparty\tracealyzer_recorder\config\trcKernelPortConfig.h as below

  8. #define TRC_CFG_RECORDER_MODE TRC_RECORDER_MODE_SNAPSHOT

  9. Disabled Application Level Tracing. (No instructions to disable this for ESP32 AWS Kernel)

  10. Enabled Trace Facility in the Free Rtos Config.

  11. Included “trcRecorder.h” in the end of FreeRTOSconfig.h

  12. Added vTraceEnable(TRC_START); in the main()

I’m getting an error below.

My cmakelists looks like this as per AFR get started guide.

image

Could someone help how to include the trcrecorder before freertos config?

We are working on updated instructions for CMake.
Have you been in contact with Percepio support? (support@percepio.com)