You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2024/09/08 13:43:53 UTC
(nuttx) branch master updated: Documentation: Add usage guide for the debugpoint command
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push:
new 9d5b9b7c05 Documentation: Add usage guide for the debugpoint command
9d5b9b7c05 is described below
commit 9d5b9b7c056e59c2fcc81e7029c95a995140063c
Author: Huang Qi <hu...@xiaomi.com>
AuthorDate: Sun Sep 8 17:07:26 2024 +0800
Documentation: Add usage guide for the debugpoint command
See https://github.com/apache/nuttx-apps/pull/2549
Signed-off-by: Huang Qi <hu...@xiaomi.com>
---
.../applications/system/debugpoint/index.rst | 57 ++++++++++++++++++++++
1 file changed, 57 insertions(+)
diff --git a/Documentation/applications/system/debugpoint/index.rst b/Documentation/applications/system/debugpoint/index.rst
new file mode 100644
index 0000000000..8909374d10
--- /dev/null
+++ b/Documentation/applications/system/debugpoint/index.rst
@@ -0,0 +1,57 @@
+=====================================
+``debugpoint`` Debug Utility
+=====================================
+
+``CONFIG_SYSTEM_DEBUGPOINT=y``
+
+The ``debugpoint`` utility is a tool for testing and managing debug points (breakpoints and watchpoints) in the system. It allows users to set, remove, and test various types of debug points.
+
+Usage::
+
+ debugpoint [options]
+
+Options::
+
+ -r addr Set a read watchpoint at address
+ -w addr Set a write watchpoint at address
+ -b addr Set a breakpoint at address
+ -x addr Set a read/write watchpoint at address
+ -c Cancel the watchpoint or breakpoint (must be used with -r, -w, -b, or -x)
+ -l len Set the watch length (must be used with -r, -w, -b, or -x)
+
+Examples::
+
+ # Set a read watchpoint at address 0x1000
+ debugpoint -r 0x1000
+
+ # Set a write watchpoint at address 0x2000
+ debugpoint -w 0x2000
+
+ # Set a breakpoint at address 0x3000
+ debugpoint -b 0x3000
+
+ # Set a read/write watchpoint at address 0x4000
+ debugpoint -x 0x4000
+
+ # Cancel the read watchpoint at address 0x1000
+ debugpoint -r 0x1000 -c
+
+ # Cancel the write watchpoint at address 0x2000
+ debugpoint -w 0x2000 -c
+
+ # Cancel the breakpoint at address 0x3000
+ debugpoint -b 0x3000 -c
+
+ # Cancel the read/write watchpoint at address 0x4000
+ debugpoint -x 0x4000 -c
+
+ # Set the watch length to 8 bytes for a read watchpoint at address 0x1000
+ debugpoint -r 0x1000 -l 8
+
+ # Set the watch length to 8 bytes for a write watchpoint at address 0x2000
+ debugpoint -w 0x2000 -l 8
+
+ # Set the watch length to 8 bytes for a breakpoint at address 0x3000
+ debugpoint -b 0x3000 -l 8
+
+The ``debug`` utility also includes automated tests for breakpoints and watchpoints. When run without any options, it will execute these tests to verify the functionality of the debug points.