From 80e1037adf060c852c5d17b0dc581f24cd4f3ae8 Mon Sep 17 00:00:00 2001 From: "Kennedy Ho@Renesas" Date: Fri, 3 Apr 2026 11:25:44 +0900 Subject: [PATCH] Fix issue where FreeRTOS viewer hints are not showing - When configUSE_TRACE_FACILITY is 0, uxTCBNumber is not compiled causing it to be undefined. - Make uxTCBNumber optional so it does not cause a TypeError exception, and helpHtml will not be empty. --- CHANGELOG.md | 2 ++ src/rtos/rtos-freertos.ts | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7b880b2..c62facc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +- FreeRTOS: Fix the issue where hints are not showing at all when Thread ID is missing. + ## 0.0.15 - Mar 28, 2026 - Read stackTop for current running task with function contributed by @malsyned also in uc/OS-II. diff --git a/src/rtos/rtos-freertos.ts b/src/rtos/rtos-freertos.ts index ee7b083..c34a30d 100644 --- a/src/rtos/rtos-freertos.ts +++ b/src/rtos/rtos-freertos.ts @@ -249,7 +249,7 @@ export class RTOSFreeRTOS extends RTOSCommon.RTOSBase { this.helpHtml = ''; try { let ret = ''; - if (!thInfo['uxTCBNumber'].val) { + if (!thInfo['uxTCBNumber']?.val) { ret += `Thread ID missing......: Enable macro ${strong('configUSE_TRACE_FACILITY')} in FW
`; } if (!th.stackInfo.stackEnd) {