Hello @nino
can you please confirm the query made in my previous comment regarding the SystemView version that seems to conflict with the FreeRTOS v10.4?
Hello @nino
can you please confirm the query made in my previous comment regarding the SystemView version that seems to conflict with the FreeRTOS v10.4?
Hello
Thanks for the response. Upon compiling, I see the following
external/freertos/source/tasks.c:4740:50: error: macro "traceTASK_NOTIFY_TAKE" passed 1 arguments, but takes just 0
8> In file included from ../../../../../../external/freertos/config/FreeRTOSConfig.h:213,8>
from
../../../../../../external/freertos/source/include/FreeRTOS.h:57,8> from /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/tasks.c:37:8> ../../../../../../external/freertos/config/SEGGER_SYSVIEW_FreeRTOS.h:195: note: macro "traceTASK_NOTIFY_TAKE" defined here8>
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/tasks.c:4740:13: error: 'traceTASK_NOTIFY_TAKE' undeclared (first use in this function)8> /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/tasks.c:4740:13: note: each undeclared identifier is reported only once for each function it appears in8> /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/tasks.c:4819:50: error: macro "traceTASK_NOTIFY_WAIT" passed 1 arguments, but takes just 0
8> In file included from ../../../../../../external/freertos/config/FreeRTOSConfig.h:213,
.......
In FreeRTOS.h, I see compiler thinks traceTASK_NOTIFY_TAKE isn't recognized (hence greyed out) even though in SEGGER_SYSVIEW_FreeRTOS.h, I see traceTASK_NOTIFY_TAKE is defined
#define traceTASK_NOTIFY_TAKE() SEGGER_SYSVIEW_RecordU32x2(apiID_OFFSET + apiID_ULTASKNOTIFYTAKE, xClearCountOnExit, xTicksToWait)
Also the project attached is for STM32 and I'm using a nordic uC
I have been trying to integrate Segger SystemView into my project but haven't had any luck so far.
After manually applying the patch and including a #include "SEGGER_SYSVIEW_FreeRTOS.h", I start seeing a lot of undefined reference errors. For instance, "SEGGER_SYSVIEW_RecordExitISR" is defined in SEGGER_SYSVIEW.c , and SEGGER_SYSVIEW.c is already included in the preprocessor of the Segger IDE project.
/app_timer_freertos.o: in function `app_timer_start':1> /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/components/libraries/timer/app_timer_freertos.c:194: undefined reference to `SEGGER_SYSVIEW_RecordExitISRToScheduler'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld:
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/components/libraries/timer/app_timer_freertos.c:194: undefined reference to `SEGGER_SYSVIEW_RecordExitISR'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: Output/Release/Obj/Init template - FreeRTOS/app_timer_freertos.o: in function `app_timer_stop':1>
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/components/libraries/timer/app_timer_freertos.c:230: undefined reference to `SEGGER_SYSVIEW_RecordExitISRToScheduler'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/components/libraries/timer/app_timer_freertos.c:230: undefined reference to `SEGGER_SYSVIEW_RecordExitISR'1>
/Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: Output/Release/Obj/Init template - FreeRTOS/port_cmsis_systick.o: in function
`RTC1_IRQHandler':1>
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/portable/CMSIS/nrf52/port_cmsis_systick.c:128: undefined reference to `SEGGER_SYSVIEW_RecordEnterISR'1>
/Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/portable/CMSIS/nrf52/port_cmsis_systick.c:158: undefined reference to `SEGGER_SYSVIEW_RecordExitISRToScheduler'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld:
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/portable/CMSIS/nrf52/port_cmsis_systick.c:166: undefined reference to `SEGGER_SYSVIEW_RecordExitISR'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: Output/Release/Obj/Init template - FreeRTOS/queue.o: in function `prvInitialiseNewQueue':1>
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/queue.c:447: undefined reference to `SEGGER_SYSVIEW_RecordU32x3'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: Output/Release/Obj/Init template - FreeRTOS/queue.o: in function `xQueueGenericSend':1>
/Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/queue.c:755: undefined reference to `SEGGER_SYSVIEW_ShrinkId'1> /Applications/SEGGER Embedded Studio for ARM 5.42/gcc/arm-none-eabi/bin/ld: /Users/Projects/BLE/nRF5_SDK_17.0.2_d674dde/external/freertos/source/queue.c:755: undefined reference to `SEGGER_SYSVIEW_RecordU32x4'
I'm following this wiki to integrate SystemView into my application for tracing RTOS.
I put the patch file inside freertos/source directory, and running the patch command results in the following:
patch -p1 -r . < FreeRTOS_10_4_3.patch
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -rupN org/config/FreeRTOSConfig.h new/config/FreeRTOSConfig.h
|--- org/config/FreeRTOSConfig.h 2020-12-15 19:53:08.000000000 +0100
|+++ new/config/FreeRTOSConfig.h 2021-03-10 13:28:14.645130255 +0100
Also to confirm, the SystemView source files being referred to in the Wiki page include SEGGER_SYSVIEW_FreeRTOS.h & SEGGER_SYSVIEW_FreeRTOS.c, yes?