Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions tools/Kconfig
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
menu "tools packages"

source "$PKGS_DIR/packages/tools/CmBacktrace/Kconfig"
source "$PKGS_DIR/packages/tools/MCoreDump/Kconfig"
source "$PKGS_DIR/packages/tools/EasyFlash/Kconfig"
source "$PKGS_DIR/packages/tools/EasyLogger/Kconfig"
source "$PKGS_DIR/packages/tools/SystemView/Kconfig"
Expand Down
85 changes: 85 additions & 0 deletions tools/MCoreDump/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@

menuconfig PKG_USING_MCOREDUMP
bool "MCoreDump: Advanced fault backtrace library for ARM Cortex-M series MCU."
default n

if PKG_USING_MCOREDUMP

if PKG_USING_MCOREDUMP

choice
prompt "Select the arch"
default PKG_USING_MCOREDUMP_ARCH_ARMV7M
help
Select the arch

config PKG_USING_MCOREDUMP_ARCH_ARMV7M
bool "armv7m"

config PKG_USING_MCOREDUMP_ARCH_ARMV8M
bool "armv8m"
endchoice

config PKG_USING_MCOREDUMP_EXAMPLE
bool "Using coredump example"
default y
help
Enable MCoreDump example code

config PKG_MCOREDUMP_MEMORY_SIZE
int "Coredump memory buffer size (bytes)"
default 8192
range 1024 65536
help
Size of the static memory buffer for coredump storage.
This buffer is placed in .noinit section and persists across resets.
Minimum: 1KB, Default: 8KB

config PKG_USING_MCOREDUMP_FILESYSTEM
bool "Using filesystem for coredump storage"
default n
depends on RT_USING_DFS
help
Enable filesystem support for saving coredumps to files.
Requires DFS (Device File System) to be enabled.
If not enabled, filesystem-related functions will be disabled.

if PKG_USING_MCOREDUMP_FILESYSTEM

config PKG_MCOREDUMP_FILESYSTEM_DIR
string "Coredump directory path"
default "/sdcard"
help
Directory path where coredump files will be saved.

config PKG_MCOREDUMP_FILESYSTEM_PREFIX
string "Coredump file prefix"
default "core_"
help
Prefix for coredump filenames.
endif
endif

config PKG_MCOREDUMP_PATH
string
default "/packages/tools/MCoreDump"

choice
prompt "Version"
default PKG_USING_MCOREDUMP_LATEST_VERSION
help
Select the this package version

config PKG_USING_MCOREDUMP_LATEST_VERSION
bool "latest"
endchoice

config PKG_MCOREDUMP_VER
string
default "latest" if PKG_USING_MCOREDUMP_LATEST_VERSION

config PKG_MCOREDUMP_VER_NUM
hex
default 0x99999 if PKG_USING_MCOREDUMP_LATEST_VERSION
Copy link

Copilot AI Aug 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The condition references 'PKG_USING_MCOREDUMP_LATEST_VERSION' but the actual config name defined above is 'PKG_USING_MCORE_DUMP_LATEST_VERSION'. This will cause the default value to never be applied.

Suggested change
default 0x99999 if PKG_USING_MCOREDUMP_LATEST_VERSION
default "latest" if PKG_USING_MCORE_DUMP_LATEST_VERSION
config PKG_MCOREDUMP_VER_NUM
hex
default 0x99999 if PKG_USING_MCORE_DUMP_LATEST_VERSION

Copilot uses AI. Check for mistakes.
Copy link

Copilot AI Aug 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The condition references 'PKG_USING_MCOREDUMP_LATEST_VERSION' but the actual config name defined above is 'PKG_USING_MCORE_DUMP_LATEST_VERSION'. This will cause the default value to never be applied.

Suggested change
default 0x99999 if PKG_USING_MCOREDUMP_LATEST_VERSION
default "latest" if PKG_USING_MCORE_DUMP_LATEST_VERSION
config PKG_MCOREDUMP_VER_NUM
hex
default 0x99999 if PKG_USING_MCORE_DUMP_LATEST_VERSION

Copilot uses AI. Check for mistakes.

endif
34 changes: 34 additions & 0 deletions tools/MCoreDump/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"name": "MCoreDump",
"description": "MCoreDump (mini-coredump) is a fault dump (CoreDump) component designed specifically for embedded systems. It automatically generates standard ELF format core dump files when the system encounters a hard fault, assertion failure, or other abnormal conditions, which can be used for offline debugging and fault analysis.",
"description_zh": "MCoreDump(mini-coredump) 是专为嵌入式系统设计的故障转储(CoreDump)组件,能够在系统发生硬故障(Hard Fault)、断言失败或其他异常情况时,自动生成标准 ELF 格式的核心转储文件,用于离线调试和故障分析。",
"enable": "PKG_USING_MCOREDUMP",
"keywords": [
"ARM",
"Cortex-M",
"Cortex",
"coredump",
"backtrace",
"callstack",
"hardfault"
],
"category": "tools",
"author": {
"name": "Rbb666",
"email": "[email protected]",
"github": "Rbb666"
},
"license": "Apache-2.0",
"repository": "https://github.com/Rbb666/MCoreDump",
"homepage": "https://github.com/Rbb666/MCoreDump#readme",
"doc": "https://github.com/Rbb666/MCoreDump/blob/master/README.md",
"readme": "MCoreDump (mini-coredump) is a fault dump (CoreDump) component designed specifically for embedded systems. It automatically generates standard ELF format core dump files when the system encounters a hard fault, assertion failure, or other abnormal conditions, which can be used for offline debugging and fault analysis.",
"site": [
{
"version": "latest",
"URL": "https://github.com/Rbb666/MCoreDump.git",
"filename": "MCoreDump.zip",
"VER_SHA": "master"
}
]
}
Loading