You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by gi...@apache.org on 2023/05/25 00:15:16 UTC
[nuttx-website] branch asf-site updated: Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 50d1de93ed9d0f69b2b8be98fdcd4d80d26953ac
This is an automated email from the ASF dual-hosted git repository.
github-bot pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git
The following commit(s) were added to refs/heads/asf-site by this push:
new 4c4c2d7d Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 50d1de93ed9d0f69b2b8be98fdcd4d80d26953ac
4c4c2d7d is described below
commit 4c4c2d7d4ed87cefbbd84e34b32abe3101c66245
Author: Brennan Ashton <ba...@brennanashton.com>
AuthorDate: Thu May 25 00:12:35 2023 +0000
Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 50d1de93ed9d0f69b2b8be98fdcd4d80d26953ac
---
content/docs/10.0.0/index.html | 2 +-
content/docs/10.0.0/searchindex.js | 2 +-
content/docs/10.0.1/index.html | 2 +-
content/docs/10.0.1/searchindex.js | 2 +-
content/docs/10.1.0/index.html | 2 +-
content/docs/10.1.0/searchindex.js | 2 +-
content/docs/10.2.0/index.html | 2 +-
content/docs/10.2.0/searchindex.js | 2 +-
content/docs/10.3.0/index.html | 2 +-
content/docs/10.3.0/searchindex.js | 2 +-
content/docs/11.0.0/index.html | 2 +-
content/docs/11.0.0/searchindex.js | 2 +-
content/docs/12.0.0/index.html | 2 +-
content/docs/12.0.0/searchindex.js | 2 +-
content/docs/12.1.0/index.html | 2 +-
content/docs/12.1.0/searchindex.js | 2 +-
.../_sources/guides/cortexmhardfaults.rst.txt | 203 +++++++++++
content/docs/latest/_sources/guides/index.rst.txt | 1 +
.../_sources/reference/os/time_clock.rst.txt | 69 ++--
content/docs/latest/glossary.html | 4 +-
content/docs/latest/guides/cortexmhardfaults.html | 370 +++++++++++++++++++++
content/docs/latest/guides/cpp_cmake.html | 1 +
content/docs/latest/guides/customapps.html | 1 +
content/docs/latest/guides/customboards.html | 1 +
content/docs/latest/guides/drivers.html | 1 +
content/docs/latest/guides/index.html | 12 +
content/docs/latest/guides/nestedinterrupts.html | 5 +-
content/docs/latest/guides/nfs.html | 1 +
content/docs/latest/guides/pysimcoder.html | 1 +
content/docs/latest/guides/qemugdb.html | 1 +
content/docs/latest/guides/rndis.html | 1 +
content/docs/latest/guides/simulator.html | 1 +
content/docs/latest/guides/tasktrace.html | 1 +
content/docs/latest/guides/tasktraceinternal.html | 1 +
content/docs/latest/guides/tasktraceuser.html | 1 +
content/docs/latest/guides/usbtrace.html | 1 +
.../docs/latest/guides/zerolatencyinterrupts.html | 1 +
content/docs/latest/index.html | 3 +-
content/docs/latest/objects.inv | Bin 46587 -> 46803 bytes
content/docs/latest/reference/os/time_clock.html | 68 ++--
content/docs/latest/reference/user/07_signals.html | 4 +-
content/docs/latest/reference/user/structures.html | 2 +-
content/docs/latest/searchindex.js | 2 +-
content/feed.xml | 4 +-
44 files changed, 702 insertions(+), 91 deletions(-)
diff --git a/content/docs/10.0.0/index.html b/content/docs/10.0.0/index.html
index ed311493..f372d912 100644
--- a/content/docs/10.0.0/index.html
+++ b/content/docs/10.0.0/index.html
@@ -131,7 +131,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller environments, the primary governing standards in NuttX are Posix and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:09</p>
+<p>Last Updated: 25 May 23 at 00:09</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/10.0.0/searchindex.js b/content/docs/10.0.0/searchindex.js
index 3a0fdb1f..c41954f2 100644
--- a/content/docs/10.0.0/searchindex.js
+++ b/content/docs/10.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "boards/index", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/index", "components/drivers/character/keypad", "components/drivers/character/pwm", "components/drivers/character/quadrature", "components/drivers/character/rtc", "components/drivers/character/serial", "components/drivers/character/timer", "components/drivers/chara [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "boards/index", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/index", "components/drivers/character/keypad", "components/drivers/character/pwm", "components/drivers/character/quadrature", "components/drivers/character/rtc", "components/drivers/character/serial", "components/drivers/character/timer", "components/drivers/chara [...]
\ No newline at end of file
diff --git a/content/docs/10.0.1/index.html b/content/docs/10.0.1/index.html
index 98651091..b71469dc 100644
--- a/content/docs/10.0.1/index.html
+++ b/content/docs/10.0.1/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller environments, the primary governing standards in NuttX are Posix and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:09</p>
+<p>Last Updated: 25 May 23 at 00:10</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/10.0.1/searchindex.js b/content/docs/10.0.1/searchindex.js
index c1080462..1b6359f4 100644
--- a/content/docs/10.0.1/searchindex.js
+++ b/content/docs/10.0.1/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "boards/index", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/index", "components/drivers/character/keypad", "components/drivers/character/pwm", "components/drivers/character/quadrature", "components/drivers/character/rtc", "components/drivers/character/serial", "components/drivers/character/timer", "components/drivers/chara [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "boards/index", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/index", "components/drivers/character/keypad", "components/drivers/character/pwm", "components/drivers/character/quadrature", "components/drivers/character/rtc", "components/drivers/character/serial", "components/drivers/character/timer", "components/drivers/chara [...]
\ No newline at end of file
diff --git a/content/docs/10.1.0/index.html b/content/docs/10.1.0/index.html
index 1d8b06d7..f13bc24f 100644
--- a/content/docs/10.1.0/index.html
+++ b/content/docs/10.1.0/index.html
@@ -146,7 +146,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:09</p>
+<p>Last Updated: 25 May 23 at 00:10</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/10.1.0/searchindex.js b/content/docs/10.1.0/searchindex.js
index 5f0833b6..716bdfbd 100644
--- a/content/docs/10.1.0/searchindex.js
+++ b/content/docs/10.1.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/10.2.0/index.html b/content/docs/10.2.0/index.html
index 196959ac..cec8ffe2 100644
--- a/content/docs/10.2.0/index.html
+++ b/content/docs/10.2.0/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:10</p>
+<p>Last Updated: 25 May 23 at 00:10</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/10.2.0/searchindex.js b/content/docs/10.2.0/searchindex.js
index a7364653..2cb70c86 100644
--- a/content/docs/10.2.0/searchindex.js
+++ b/content/docs/10.2.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/10.3.0/index.html b/content/docs/10.3.0/index.html
index 196959ac..cec8ffe2 100644
--- a/content/docs/10.3.0/index.html
+++ b/content/docs/10.3.0/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:10</p>
+<p>Last Updated: 25 May 23 at 00:10</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/10.3.0/searchindex.js b/content/docs/10.3.0/searchindex.js
index c65c1b87..738f3c68 100644
--- a/content/docs/10.3.0/searchindex.js
+++ b/content/docs/10.3.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/11.0.0/index.html b/content/docs/11.0.0/index.html
index 196959ac..da7fb276 100644
--- a/content/docs/11.0.0/index.html
+++ b/content/docs/11.0.0/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:10</p>
+<p>Last Updated: 25 May 23 at 00:11</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/11.0.0/searchindex.js b/content/docs/11.0.0/searchindex.js
index c5513e8e..561b98dc 100644
--- a/content/docs/11.0.0/searchindex.js
+++ b/content/docs/11.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/12.0.0/index.html b/content/docs/12.0.0/index.html
index ff00b612..81f0fd98 100644
--- a/content/docs/12.0.0/index.html
+++ b/content/docs/12.0.0/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:10</p>
+<p>Last Updated: 25 May 23 at 00:11</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/12.0.0/searchindex.js b/content/docs/12.0.0/searchindex.js
index 2a87a12b..83d85994 100644
--- a/content/docs/12.0.0/searchindex.js
+++ b/content/docs/12.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/12.1.0/index.html b/content/docs/12.1.0/index.html
index d87244ec..192d4cf2 100644
--- a/content/docs/12.1.0/index.html
+++ b/content/docs/12.1.0/index.html
@@ -147,7 +147,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:11</p>
+<p>Last Updated: 25 May 23 at 00:11</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
diff --git a/content/docs/12.1.0/searchindex.js b/content/docs/12.1.0/searchindex.js
index 4782e91a..2e81be4f 100644
--- a/content/docs/12.1.0/searchindex.js
+++ b/content/docs/12.1.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can", "components/drivers/character/foc", "components/drivers/character/index", "components [...]
\ No newline at end of file
diff --git a/content/docs/latest/_sources/guides/cortexmhardfaults.rst.txt b/content/docs/latest/_sources/guides/cortexmhardfaults.rst.txt
new file mode 100644
index 00000000..86fa3c8f
--- /dev/null
+++ b/content/docs/latest/_sources/guides/cortexmhardfaults.rst.txt
@@ -0,0 +1,203 @@
+=============================
+Analyzing Cortex-M Hardfaults
+=============================
+
+.. epigraph::
+
+ > I have a build of PX4 (NuttX 6.29 with some patches) with new
+ > lpc43xx chip files on 4337 chip running from FLASH (master
+ > vanilla NuttX has no such problem). This gives me a hardfault
+ > below if I stress NSH console (UART2) with some big output.
+ >
+ > I read some threads but can't get a clue how to analyze the
+ > dump and where to look first:
+ >
+ > 1bXXX and 1aXXX addresses are FLASH. 100XXX addresses are RAM
+
+.. code-block:: console
+
+ Assertion failed at file:armv7-m/up_hardfault.c line: 184 task: hpwork
+ sp: 10001eb4
+ IRQ stack:
+ base: 10001f00
+ size: 000003fc
+ 10001ea0: 1b02d961 1b03f07e 10001eb4 10005ed8 1a0312ab 1b03f600 000000b8 1b02d961
+ 10001ec0: 00000010 10001f40 00000003 00000000 1a03721d 1a037209 1b02d93b 00000000
+ 10001ee0: 1a0371f5 00000000 00000000 00000000 00000000 00000000 1a0314a5 10005d7c
+ sp: 10005e50
+ User stack:
+ base: 10005ed8
+ size: 00000f9c
+ 10005e40: 00000000 00000000 00000000 1b02d587 10004900 00000000 005b8d7f 00000000
+ 10005e60: 1a030f2e 00000000 00000000 00001388 00000000 00000005 10001994 00000000
+ 10005e80: 00000000 00000000 00000000 1b02c359 00000000 00000000 00000000 004c4b40
+ 10005ea0: 000002ff 00000000 00000000 1a030f2f 00000000 00000000 00000000 00000000
+ 10005ec0: 00000000 1a030f41 00000000 1b02c2a5 00000000 00000000 ffffffff 00bdeb39
+ R0: ffffffff 00000000 00000016 00000000 00000000 00000000 00000000 00000000
+ R8: 100036d8 00000000 00000000 004c4b40 10001370 10005e50 1b02b20b 1b02d596
+ xPSR: 41000000 BASEPRI: 00000000 CONTROL: 00000000
+ EXC_RETURN: ffffffe9
+
+This question was asked in the old Yahoo! Group for NuttX, before the
+project joined the Apache Software Foundation. The old forum no longer
+exists, but the thread has been archived at
+`Narkive <https://nuttx.yahoogroups.narkive.com/QNbG3r5l/hardfault-help-analysing-where-to-start>`_
+(third party external link).
+
+Analyzing the Register Dump
+===========================
+
+First, in the register dump:
+
+.. code-block:: console
+
+ R0: ffffffff 00000000 00000016 00000000 00000000 00000000 00000000 00000000
+ R8: 100036d8 00000000 00000000 004c4b40 10001370 10005e50 1b02b20b 1b02d596
+ xPSR: 41000000 BASEPRI: 00000000 CONTROL: 00000000
+
+``R15`` is the PC at the time of the crash (``1b02d596``). In order to
+see where this is, I do this:
+
+.. code-block:: console
+
+ arm-none-eabi-objdump -d nuttx | vi -
+
+Of course, you can use any editor you prefer. In any case, this will
+provide a full assembly language listing of your FLASH content along
+with complete symbolic information.
+
+**TIP:** Not comfortable with ARM assembly language? Try the
+``objdump --source`` (or just ``-S``) option. That will intermix the C
+and the assembly language code so that you can see which C statements
+the assembly language is implementing.
+
+Once you have the FLASH image in the editor, it is then a simple thing
+to do the search in order to find the instruction at ``1b02d596``. The
+symbolic information will show you exactly which function the address
+is in and also the context of the instruction that can be used to
+associate it to the exact line of code in the original C source file.
+
+You also have all of the register contents so it is pretty easy to see
+what happened (assuming you have some basic knowledge of Thumb2
+assembly language and the ARM EABI). But it is usually not so easy to
+see why it happened.
+
+The rest of the instructions apply to finding out why the fault
+happened.
+
+``R14`` often contains the return address to the caller of the
+offending functions. Bit one is set in this return address, but ignore
+that (I.e., use ``1b02b20a`` instead of ``1b02b20b``). Use the objdump
+command above to see where that is.
+
+Sometimes, however, ``R14`` is not the caller of the offending
+function. If the offending functions calls some other function then
+``R14`` will be overwritten. But no problem, it will also then have
+pushed the return address on the stack where we can find it by
+analyzing the stack dump.
+
+Analyzing the Stack Dump
+========================
+
+The Task Stack
+--------------
+
+To go further back in the time, you have to analyze the stack. It is a
+push down stack so older events are at higher stack addresses; the
+most recent things that happened will be at lower stack addresses.
+
+Analyzing the stack is done in basically the same way:
+
+1. Start at the highest stack addresses (oldest) and work forward in
+ time (lower addresses)
+
+2. Find interesting addresses,
+
+3. Use ``arm-none-eabi-objdump`` to determine where those addresses
+ are in the code.
+
+An interesting address has these properties:
+
+1. It lies in FLASH in your architecture. In your case these are the
+ addresses that begin with ``0x1a`` and ``0x1b``. Other
+ architectures may have different FLASH addresses or even addresses
+ in RAM.
+
+2. The interesting addresses are all odd for Cortex-M, that is, bit 0
+ will be set. This is because as the code progresses, the return
+ address (``R14``) will be pushed on the stack. All of the return
+ addresses will lie in FLASH and will be odd.
+
+Even FLASH addresses in the stack dump usually are references to
+``.rodata`` in FLASH but are sometimes of interest as well. Below are
+examples of interesting addresses (in brackets):
+
+.. code-block:: console
+
+ sp: 10005e50
+ User stack:
+ base: 10005ed8
+ size: 00000f9c
+ 10005e40: 00000000 00000000 00000000 [1b02d587] 10004900 00000000 005b8d7f 00000000
+ 10005e60: 1a030f2e 00000000 00000000 00001388 00000000 00000005 10001994 00000000
+ 10005e80: 00000000 00000000 00000000 [1b02c359] 00000000 00000000 00000000 004c4b40
+ 10005ea0: 000002ff 00000000 00000000 [1a030f2f] 00000000 00000000 00000000 00000000
+ 10005ec0: 00000000 [1a030f41] 00000000 [1b02c2a5] 00000000 00000000 ffffffff 00bdeb39
+
+That will give the full backtrace up to the point of the failure.
+
+The Interrupt Stack
+-------------------
+
+Note that in some cases there are two stacks listed. The interrupt
+stack will be present if (1) the interrupt stack is enabled, and (2)
+you are in an interrupt handler at the time that the failure occurred:
+
+.. code-block:: console
+
+ Assertion failed at file:armv7-m/up_hardfault.c line: 184 task: hpwork
+ sp: 10001eb4
+ IRQ stack:
+ base: 10001f00
+ size: 000003fc
+ 10001ea0: [1b02d961] 1b03f07e 10001eb4 10005ed8 1a0312ab 1b03f600 000000b8 [1b02d961]
+ 10001ec0: 00000010 10001f40 00000003 00000000 [1a03721d] [1a037209] [1b02d93b] 00000000
+ 10001ee0: [1a0371f5] 00000000 00000000 00000000 00000000 00000000 [1a0314a5] 10005d7c
+
+(Interesting addresses again in brackets).
+
+The interrupt stack is sometimes interesting, for example when the
+interrupt was caused by logic operating at the interrupt level. In
+this case, it is probably not so interesting since fault was probably
+caused by normal task code and the interrupt stack probably just shows
+the normal operation of the interrupt handling logic.
+
+Full Stack Analysis
+-------------------
+
+What I have proposed here is just skimming through the stack, finding
+and interpreting interesting addresses. Sometimes you need more
+information and you need to analyze the stack in more detail. That is
+also possible because every word on the stack is there because of an
+explicit push instruction in the code (usually a push instruction on
+Cortex-M or an stmdb instruction in other ARM architectures). This is
+painstaking work but can also be done to provide a more detailed
+answer to "what happened?"
+
+Recovering State at the Time of the Hardfault
+=============================================
+
+Here is another tip from Mike Smith:
+
+.. epigraph::
+
+ "... for systems like NuttX where catching hardfaults is difficult,
+ you can recover the faulting PC, LR and SP (by examining the
+ exception stack), then write these values back into the appropriate
+ processor registers (adjust the PC as necessary for the fault).
+
+ "This will put you back in the application code at the point at
+ which the fault occurred. Some local variables will show as having
+ invalid values (because at the time of the fault they were live in
+ registers and have been overwritten by the exception handler), but
+ the stack frame, function arguments etc. should all show correctly."
diff --git a/content/docs/latest/_sources/guides/index.rst.txt b/content/docs/latest/_sources/guides/index.rst.txt
index 0539a05b..7340b6b8 100644
--- a/content/docs/latest/_sources/guides/index.rst.txt
+++ b/content/docs/latest/_sources/guides/index.rst.txt
@@ -18,3 +18,4 @@ Guides
customapps.rst
zerolatencyinterrupts.rst
nestedinterrupts.rst
+ cortexmhardfaults.rst
diff --git a/content/docs/latest/_sources/reference/os/time_clock.rst.txt b/content/docs/latest/_sources/reference/os/time_clock.rst.txt
index e47583ce..823db438 100644
--- a/content/docs/latest/_sources/reference/os/time_clock.rst.txt
+++ b/content/docs/latest/_sources/reference/os/time_clock.rst.txt
@@ -209,13 +209,13 @@ are, in increasing order of importance:
- **Overhead**: Although the CPU usage of the system timer
interrupt at 100Hz is really very low, it is still mostly
- wasted processing time. One most timer interrupts, there is
- really nothing that needs be done other than incrementing the
+ wasted processing time. On most timer interrupts, there is
+ really nothing that needs to be done other than incrementing the
counter.
- **Resolution**: Resolution of all system timing is also
- determined by ``CONFIG_USEC_PER_TICK``. So nothing that be time
- with resolution finer than 10 milliseconds be default. To
- increase this resolution, ``CONFIG_USEC_PER_TICK`` an be
+ determined by ``CONFIG_USEC_PER_TICK``. So nothing can be timed
+ with resolution finer than 10 milliseconds by default. To
+ increase this resolution, ``CONFIG_USEC_PER_TICK`` can be
reduced. However, then the system timer interrupts use more of
the CPU bandwidth processing useless interrupts.
- **Power Usage**: But the biggest issue is power usage. When the
@@ -226,7 +226,7 @@ are, in increasing order of importance:
greater power consumption.
**Tickless OS**. The so-called *Tickless OS* provides one solution
-to issue. The basic concept here is that the periodic, timer
+to this issue. The basic concept here is that the periodic, timer
interrupt is eliminated and replaced with a one-shot, interval
timer. It becomes event driven instead of polled: The default
system timer is a polled design. On each interrupt, the NuttX
@@ -255,18 +255,26 @@ Tickless Configuration Options
- ``CONFIG_ARCH_HAVE_TICKLESS``: If the platform provides
support for the *Tickless OS*, then this setting should be
- selected in the ``Kconfig`` file for the board. Here is what
- the selection looks in the ``arch/Kconfig`` file for the
+ selected in the ``Kconfig`` file for the architecture. Here is
+ what the selection looks in the ``arch/Kconfig`` file for the
simulated platform:
+ .. code-block:: console
+
+ config ARCH_SIM
+ bool "Simulation"
+ select ARCH_HAVE_TICKLESS
+ ---help---
+ Linux/Cywgin user-mode simulation.
+
When the simulation platform is selected,
``ARCH_HAVE_TICKLESS`` is automatically selected, informing the
configuration system that *Tickless OS* options can be
selected.
-- ``CONFIG_SCHED_TICKLESS``: If ``CONFIG_ARCH_HAVE_TICKLESS``
- is selected, then it will enable the Tickless OS features in
- NuttX.
+- ``CONFIG_SCHED_TICKLESS``: If ``CONFIG_ARCH_HAVE_TICKLESS`` is
+ selected, then you will be able to use this option to enable the
+ *Tickless OS* features in NuttX.
- ``CONFIG_SCHED_TICKLESS_ALARM``: The tickless option can be
supported either via a simple interval timer (plus elapsed
@@ -277,15 +285,15 @@ Tickless Configuration Options
The advantage of an alarm is that it avoids some small timing
errors; the advantage of the use of the interval timer is that
- the hardware requirement may be less.
+ the hardware requirement may be simpler.
- ``CONFIG_USEC_PER_TICK``: This option is not unique to
*Tickless OS* operation, but changes its relevance when the
- *Tickless OS* is selected. In the default configuration where
+ *Tickless OS* is selected. In the default configuration, where
system time is provided by a periodic timer interrupt, the
- default system timer is configure the timer for 100Hz or
+ default system timer is configured for 100Hz, that is,
``CONFIG_USEC_PER_TICK=10000``. If ``CONFIG_SCHED_TICKLESS`` is
- selected, then there are no system timer interrupt. In this
+ selected, then there are no system timer interrupts. In this
case, ``CONFIG_USEC_PER_TICK`` does not control any timer
rates. Rather, it only determines the resolution of time
reported by ``clock_systime_ticks()`` and the resolution of
@@ -342,26 +350,23 @@ platform code must provide the following verify similar functions:
- ``up_timer_start()``: Starts (or re-starts)
the interval timer.
-Note that a platform-specific implementation would probably
-require two hardware timers: (1) A interval timer to satisfy the
-requirements of ``up_timer_start()`` and
-``up_timer_cancel()``, and a (2) a counter to
-handle the requirement of
-``up_timer_gettime()``. Ideally, both timers
+Note that a platform-specific implementation would probably require two
+hardware timers: (1) A interval timer to satisfy the requirements of
+``up_timer_start()`` and ``up_timer_cancel()``, and (2) a counter to
+handle the requirement of ``up_timer_gettime()``. Ideally, both timers
would run at the rate determined by ``CONFIG_USEC_PER_TICK`` (and
certainly never slower than that rate).
-Since timers are a limited resource, the use of two timers could
-be an issue on some systems. The job could be done with a single
-timer if, for example, the single timer were kept in a
-free-running at all times. Some timer/counters have the capability
-to generate a compare interrupt when the timer matches a
-comparison value but also to continue counting without stopping.
-If your hardware supports such counters, one might used the
-``CONFIG_SCHED_TICKLESS_ALARM`` option and be able to simply set
-the comparison count at the value of the free running timer *PLUS*
-the desired delay. Then you could have both with a single timer:
-An alarm and a free-running counter with the same timer!
+Since timers are a limited resource, the use of two timers could be an
+issue on some systems. The job could be done with a single timer if, for
+example, the single timer were kept in a free-running mode at all times.
+Some timer/counters have the capability to generate a compare interrupt
+when the timer matches a comparison value but also to continue counting
+without stopping. If your hardware supports such counters, one might use
+the ``CONFIG_SCHED_TICKLESS_ALARM`` option and be able to simply set the
+comparison count at the value of the free running timer *PLUS* the
+desired delay. Then you could have both with a single timer: An alarm
+and a free-running counter with the same timer!
In addition to these imported interfaces, the RTOS will export the
following interfaces for use by the platform-specific interval
diff --git a/content/docs/latest/glossary.html b/content/docs/latest/glossary.html
index 9f34e5db..fbb740f6 100644
--- a/content/docs/latest/glossary.html
+++ b/content/docs/latest/glossary.html
@@ -44,7 +44,7 @@
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
- <link rel="prev" title="Nested Interrupts" href="guides/nestedinterrupts.html" />
+ <link rel="prev" title="Analyzing Cortex-M Hardfaults" href="guides/cortexmhardfaults.html" />
</head>
<body class="wy-body-for-nav">
@@ -387,7 +387,7 @@
</div>
</div>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
- <a href="guides/nestedinterrupts.html" class="btn btn-neutral float-left" title="Nested Interrupts" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
+ <a href="guides/cortexmhardfaults.html" class="btn btn-neutral float-left" title="Analyzing Cortex-M Hardfaults" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
</div>
<hr/>
diff --git a/content/docs/latest/guides/cortexmhardfaults.html b/content/docs/latest/guides/cortexmhardfaults.html
new file mode 100644
index 00000000..a70ccf4a
--- /dev/null
+++ b/content/docs/latest/guides/cortexmhardfaults.html
@@ -0,0 +1,370 @@
+<!--
+ Documentation/_templates/layout.html
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership. The
+ ASF licenses this file to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance with the
+ License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ License for the specific language governing permissions and limitations
+ under the License.
+-->
+
+<!DOCTYPE html>
+<html class="writer-html5" lang="en" >
+<head>
+ <meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />
+
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
+ <title>Analyzing Cortex-M Hardfaults — NuttX latest documentation</title>
+ <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
+ <link rel="stylesheet" href="../_static/css/theme.css" type="text/css" />
+ <link rel="stylesheet" href="../_static/copybutton.css" type="text/css" />
+ <link rel="stylesheet" href="../_static/tabs.css" type="text/css" />
+ <link rel="stylesheet" href="../_static/custom.css" type="text/css" />
+ <link rel="shortcut icon" href="../_static/favicon.ico"/>
+ <!--[if lt IE 9]>
+ <script src="../_static/js/html5shiv.min.js"></script>
+ <![endif]-->
+
+ <script src="../_static/jquery.js"></script>
+ <script src="../_static/_sphinx_javascript_frameworks_compat.js"></script>
+ <script data-url_root="../" id="documentation_options" src="../_static/documentation_options.js"></script>
+ <script src="../_static/doctools.js"></script>
+ <script src="../_static/sphinx_highlight.js"></script>
+ <script src="../_static/clipboard.min.js"></script>
+ <script src="../_static/copybutton.js"></script>
+ <script src="../_static/js/theme.js"></script>
+ <link rel="index" title="Index" href="../genindex.html" />
+ <link rel="search" title="Search" href="../search.html" />
+ <link rel="next" title="Glossary" href="../glossary.html" />
+ <link rel="prev" title="Nested Interrupts" href="nestedinterrupts.html" />
+</head>
+
+<body class="wy-body-for-nav">
+ <div class="wy-grid-for-nav">
+ <nav data-toggle="wy-nav-shift" class="wy-nav-side">
+ <div class="wy-side-scroll">
+ <div class="wy-side-nav-search" >
+
+ <a href="../index.html" class="icon icon-home"> NuttX
+
+
+
+ </a>
+
+ <!-- this version selector is quite ugly, should be probably replaced by something
+ more modern -->
+
+ <div class="version-selector">
+ <select onchange="javascript:location.href = this.value;">
+
+ <option value="../../latest" selected="selected">latest</option>
+
+ <option value="../../10.0.0" >10.0.0</option>
+
+ <option value="../../10.0.1" >10.0.1</option>
+
+ <option value="../../10.1.0" >10.1.0</option>
+
+ <option value="../../10.2.0" >10.2.0</option>
+
+ <option value="../../10.3.0" >10.3.0</option>
+
+ <option value="../../11.0.0" >11.0.0</option>
+
+ <option value="../../12.0.0" >12.0.0</option>
+
+ <option value="../../12.1.0" >12.1.0</option>
+
+ </select>
+ </div>
+
+
+<div role="search">
+ <form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
+ <input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
+ <input type="hidden" name="check_keywords" value="yes" />
+ <input type="hidden" name="area" value="default" />
+ </form>
+</div>
+
+ </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
+ <p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
+<ul class="current">
+<li class="toctree-l1"><a class="reference internal" href="../index.html">Home</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../introduction/index.html">Introduction</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../quickstart/index.html">Getting Started</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../contributing/index.html">Contributing</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../introduction/inviolables.html">The Inviolable Principles of NuttX</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../platforms/index.html">Supported Platforms</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../components/index.html">OS Components</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../applications/index.html">Applications</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../reference/index.html">API Reference</a></li>
+<li class="toctree-l1"><a class="reference internal" href="../faq/index.html">FAQ</a></li>
+<li class="toctree-l1 current"><a class="reference internal" href="index.html">Guides</a><ul class="current">
+<li class="toctree-l2"><a class="reference internal" href="nfs.html">NFS Client How-To</a></li>
+<li class="toctree-l2"><a class="reference internal" href="usbtrace.html">USB Device Trace</a></li>
+<li class="toctree-l2"><a class="reference internal" href="simulator.html">Simulator</a></li>
+<li class="toctree-l2"><a class="reference internal" href="qemugdb.html">How to debug NuttX using QEMU and GDB</a></li>
+<li class="toctree-l2"><a class="reference internal" href="rndis.html">How to use RNDIS</a></li>
+<li class="toctree-l2"><a class="reference internal" href="drivers.html">Drivers</a></li>
+<li class="toctree-l2"><a class="reference internal" href="tasktrace.html">Task Trace</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cpp_cmake.html">C++ Example using CMake</a></li>
+<li class="toctree-l2"><a class="reference internal" href="pysimcoder.html">pysimCoder integration with NuttX</a></li>
+<li class="toctree-l2"><a class="reference internal" href="customboards.html">Custom Boards How-To</a></li>
+<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
+<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2 current"><a class="current reference internal" href="#">Analyzing Cortex-M Hardfaults</a><ul>
+<li class="toctree-l3"><a class="reference internal" href="#analyzing-the-register-dump">Analyzing the Register Dump</a></li>
+<li class="toctree-l3"><a class="reference internal" href="#analyzing-the-stack-dump">Analyzing the Stack Dump</a><ul>
+<li class="toctree-l4"><a class="reference internal" href="#the-task-stack">The Task Stack</a></li>
+<li class="toctree-l4"><a class="reference internal" href="#the-interrupt-stack">The Interrupt Stack</a></li>
+<li class="toctree-l4"><a class="reference internal" href="#full-stack-analysis">Full Stack Analysis</a></li>
+</ul>
+</li>
+<li class="toctree-l3"><a class="reference internal" href="#recovering-state-at-the-time-of-the-hardfault">Recovering State at the Time of the Hardfault</a></li>
+</ul>
+</li>
+</ul>
+</li>
+<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
+</ul>
+
+ </div>
+ </div>
+ </nav>
+
+ <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
+ <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
+ <a href="../index.html">NuttX</a>
+ </nav>
+
+ <div class="wy-nav-content">
+ <div class="rst-content">
+ <div role="navigation" aria-label="Page navigation">
+ <ul class="wy-breadcrumbs">
+ <li><a href="../index.html" class="icon icon-home" aria-label="Home"></a></li>
+ <li class="breadcrumb-item"><a href="index.html">Guides</a></li>
+ <li class="breadcrumb-item active">Analyzing Cortex-M Hardfaults</li>
+ <li class="wy-breadcrumbs-aside">
+ <a href="../_sources/guides/cortexmhardfaults.rst.txt" rel="nofollow"> View page source</a>
+ </li>
+ </ul>
+ <hr/>
+</div>
+ <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
+ <div itemprop="articleBody">
+
+ <section id="analyzing-cortex-m-hardfaults">
+<h1>Analyzing Cortex-M Hardfaults<a class="headerlink" href="#analyzing-cortex-m-hardfaults" title="Permalink to this heading"></a></h1>
+<blockquote class="epigraph">
+<div><p>> I have a build of PX4 (NuttX 6.29 with some patches) with new
+> lpc43xx chip files on 4337 chip running from FLASH (master
+> vanilla NuttX has no such problem). This gives me a hardfault
+> below if I stress NSH console (UART2) with some big output.
+>
+> I read some threads but can’t get a clue how to analyze the
+> dump and where to look first:
+>
+> 1bXXX and 1aXXX addresses are FLASH. 100XXX addresses are RAM</p>
+</div></blockquote>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">Assertion failed at file:armv7-m/up_hardfault.c line: 184 task: hpwork</span>
+<span class="go">sp: 10001eb4</span>
+<span class="go">IRQ stack:</span>
+<span class="go"> base: 10001f00</span>
+<span class="go"> size: 000003fc</span>
+<span class="go">10001ea0: 1b02d961 1b03f07e 10001eb4 10005ed8 1a0312ab 1b03f600 000000b8 1b02d961</span>
+<span class="go">10001ec0: 00000010 10001f40 00000003 00000000 1a03721d 1a037209 1b02d93b 00000000</span>
+<span class="go">10001ee0: 1a0371f5 00000000 00000000 00000000 00000000 00000000 1a0314a5 10005d7c</span>
+<span class="go">sp: 10005e50</span>
+<span class="go">User stack:</span>
+<span class="go"> base: 10005ed8</span>
+<span class="go"> size: 00000f9c</span>
+<span class="go">10005e40: 00000000 00000000 00000000 1b02d587 10004900 00000000 005b8d7f 00000000</span>
+<span class="go">10005e60: 1a030f2e 00000000 00000000 00001388 00000000 00000005 10001994 00000000</span>
+<span class="go">10005e80: 00000000 00000000 00000000 1b02c359 00000000 00000000 00000000 004c4b40</span>
+<span class="go">10005ea0: 000002ff 00000000 00000000 1a030f2f 00000000 00000000 00000000 00000000</span>
+<span class="go">10005ec0: 00000000 1a030f41 00000000 1b02c2a5 00000000 00000000 ffffffff 00bdeb39</span>
+<span class="go">R0: ffffffff 00000000 00000016 00000000 00000000 00000000 00000000 00000000</span>
+<span class="go">R8: 100036d8 00000000 00000000 004c4b40 10001370 10005e50 1b02b20b 1b02d596</span>
+<span class="go">xPSR: 41000000 BASEPRI: 00000000 CONTROL: 00000000</span>
+<span class="go">EXC_RETURN: ffffffe9</span>
+</pre></div>
+</div>
+<p>This question was asked in the old Yahoo! Group for NuttX, before the
+project joined the Apache Software Foundation. The old forum no longer
+exists, but the thread has been archived at
+<a class="reference external" href="https://nuttx.yahoogroups.narkive.com/QNbG3r5l/hardfault-help-analysing-where-to-start">Narkive</a>
+(third party external link).</p>
+<section id="analyzing-the-register-dump">
+<h2>Analyzing the Register Dump<a class="headerlink" href="#analyzing-the-register-dump" title="Permalink to this heading"></a></h2>
+<p>First, in the register dump:</p>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">R0: ffffffff 00000000 00000016 00000000 00000000 00000000 00000000 00000000</span>
+<span class="go">R8: 100036d8 00000000 00000000 004c4b40 10001370 10005e50 1b02b20b 1b02d596</span>
+<span class="go">xPSR: 41000000 BASEPRI: 00000000 CONTROL: 00000000</span>
+</pre></div>
+</div>
+<p><code class="docutils literal notranslate"><span class="pre">R15</span></code> is the PC at the time of the crash (<code class="docutils literal notranslate"><span class="pre">1b02d596</span></code>). In order to
+see where this is, I do this:</p>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">arm-none-eabi-objdump -d nuttx | vi -</span>
+</pre></div>
+</div>
+<p>Of course, you can use any editor you prefer. In any case, this will
+provide a full assembly language listing of your FLASH content along
+with complete symbolic information.</p>
+<p><strong>TIP:</strong> Not comfortable with ARM assembly language? Try the
+<code class="docutils literal notranslate"><span class="pre">objdump</span> <span class="pre">--source</span></code> (or just <code class="docutils literal notranslate"><span class="pre">-S</span></code>) option. That will intermix the C
+and the assembly language code so that you can see which C statements
+the assembly language is implementing.</p>
+<p>Once you have the FLASH image in the editor, it is then a simple thing
+to do the search in order to find the instruction at <code class="docutils literal notranslate"><span class="pre">1b02d596</span></code>. The
+symbolic information will show you exactly which function the address
+is in and also the context of the instruction that can be used to
+associate it to the exact line of code in the original C source file.</p>
+<p>You also have all of the register contents so it is pretty easy to see
+what happened (assuming you have some basic knowledge of Thumb2
+assembly language and the ARM EABI). But it is usually not so easy to
+see why it happened.</p>
+<p>The rest of the instructions apply to finding out why the fault
+happened.</p>
+<p><code class="docutils literal notranslate"><span class="pre">R14</span></code> often contains the return address to the caller of the
+offending functions. Bit one is set in this return address, but ignore
+that (I.e., use <code class="docutils literal notranslate"><span class="pre">1b02b20a</span></code> instead of <code class="docutils literal notranslate"><span class="pre">1b02b20b</span></code>). Use the objdump
+command above to see where that is.</p>
+<p>Sometimes, however, <code class="docutils literal notranslate"><span class="pre">R14</span></code> is not the caller of the offending
+function. If the offending functions calls some other function then
+<code class="docutils literal notranslate"><span class="pre">R14</span></code> will be overwritten. But no problem, it will also then have
+pushed the return address on the stack where we can find it by
+analyzing the stack dump.</p>
+</section>
+<section id="analyzing-the-stack-dump">
+<h2>Analyzing the Stack Dump<a class="headerlink" href="#analyzing-the-stack-dump" title="Permalink to this heading"></a></h2>
+<section id="the-task-stack">
+<h3>The Task Stack<a class="headerlink" href="#the-task-stack" title="Permalink to this heading"></a></h3>
+<p>To go further back in the time, you have to analyze the stack. It is a
+push down stack so older events are at higher stack addresses; the
+most recent things that happened will be at lower stack addresses.</p>
+<p>Analyzing the stack is done in basically the same way:</p>
+<ol class="arabic simple">
+<li><p>Start at the highest stack addresses (oldest) and work forward in
+time (lower addresses)</p></li>
+<li><p>Find interesting addresses,</p></li>
+<li><p>Use <code class="docutils literal notranslate"><span class="pre">arm-none-eabi-objdump</span></code> to determine where those addresses
+are in the code.</p></li>
+</ol>
+<p>An interesting address has these properties:</p>
+<ol class="arabic simple">
+<li><p>It lies in FLASH in your architecture. In your case these are the
+addresses that begin with <code class="docutils literal notranslate"><span class="pre">0x1a</span></code> and <code class="docutils literal notranslate"><span class="pre">0x1b</span></code>. Other
+architectures may have different FLASH addresses or even addresses
+in RAM.</p></li>
+<li><p>The interesting addresses are all odd for Cortex-M, that is, bit 0
+will be set. This is because as the code progresses, the return
+address (<code class="docutils literal notranslate"><span class="pre">R14</span></code>) will be pushed on the stack. All of the return
+addresses will lie in FLASH and will be odd.</p></li>
+</ol>
+<p>Even FLASH addresses in the stack dump usually are references to
+<code class="docutils literal notranslate"><span class="pre">.rodata</span></code> in FLASH but are sometimes of interest as well. Below are
+examples of interesting addresses (in brackets):</p>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">sp: 10005e50</span>
+<span class="go">User stack:</span>
+<span class="go"> base: 10005ed8</span>
+<span class="go"> size: 00000f9c</span>
+<span class="go">10005e40: 00000000 00000000 00000000 [1b02d587] 10004900 00000000 005b8d7f 00000000</span>
+<span class="go">10005e60: 1a030f2e 00000000 00000000 00001388 00000000 00000005 10001994 00000000</span>
+<span class="go">10005e80: 00000000 00000000 00000000 [1b02c359] 00000000 00000000 00000000 004c4b40</span>
+<span class="go">10005ea0: 000002ff 00000000 00000000 [1a030f2f] 00000000 00000000 00000000 00000000</span>
+<span class="go">10005ec0: 00000000 [1a030f41] 00000000 [1b02c2a5] 00000000 00000000 ffffffff 00bdeb39</span>
+</pre></div>
+</div>
+<p>That will give the full backtrace up to the point of the failure.</p>
+</section>
+<section id="the-interrupt-stack">
+<h3>The Interrupt Stack<a class="headerlink" href="#the-interrupt-stack" title="Permalink to this heading"></a></h3>
+<p>Note that in some cases there are two stacks listed. The interrupt
+stack will be present if (1) the interrupt stack is enabled, and (2)
+you are in an interrupt handler at the time that the failure occurred:</p>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">Assertion failed at file:armv7-m/up_hardfault.c line: 184 task: hpwork</span>
+<span class="go">sp: 10001eb4</span>
+<span class="go">IRQ stack:</span>
+<span class="go"> base: 10001f00</span>
+<span class="go"> size: 000003fc</span>
+<span class="go">10001ea0: [1b02d961] 1b03f07e 10001eb4 10005ed8 1a0312ab 1b03f600 000000b8 [1b02d961]</span>
+<span class="go">10001ec0: 00000010 10001f40 00000003 00000000 [1a03721d] [1a037209] [1b02d93b] 00000000</span>
+<span class="go">10001ee0: [1a0371f5] 00000000 00000000 00000000 00000000 00000000 [1a0314a5] 10005d7c</span>
+</pre></div>
+</div>
+<p>(Interesting addresses again in brackets).</p>
+<p>The interrupt stack is sometimes interesting, for example when the
+interrupt was caused by logic operating at the interrupt level. In
+this case, it is probably not so interesting since fault was probably
+caused by normal task code and the interrupt stack probably just shows
+the normal operation of the interrupt handling logic.</p>
+</section>
+<section id="full-stack-analysis">
+<h3>Full Stack Analysis<a class="headerlink" href="#full-stack-analysis" title="Permalink to this heading"></a></h3>
+<p>What I have proposed here is just skimming through the stack, finding
+and interpreting interesting addresses. Sometimes you need more
+information and you need to analyze the stack in more detail. That is
+also possible because every word on the stack is there because of an
+explicit push instruction in the code (usually a push instruction on
+Cortex-M or an stmdb instruction in other ARM architectures). This is
+painstaking work but can also be done to provide a more detailed
+answer to “what happened?”</p>
+</section>
+</section>
+<section id="recovering-state-at-the-time-of-the-hardfault">
+<h2>Recovering State at the Time of the Hardfault<a class="headerlink" href="#recovering-state-at-the-time-of-the-hardfault" title="Permalink to this heading"></a></h2>
+<p>Here is another tip from Mike Smith:</p>
+<blockquote class="epigraph">
+<div><p>“… for systems like NuttX where catching hardfaults is difficult,
+you can recover the faulting PC, LR and SP (by examining the
+exception stack), then write these values back into the appropriate
+processor registers (adjust the PC as necessary for the fault).</p>
+<p>“This will put you back in the application code at the point at
+which the fault occurred. Some local variables will show as having
+invalid values (because at the time of the fault they were live in
+registers and have been overwritten by the exception handler), but
+the stack frame, function arguments etc. should all show correctly.”</p>
+</div></blockquote>
+</section>
+</section>
+
+
+ </div>
+ </div>
+ <footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
+ <a href="nestedinterrupts.html" class="btn btn-neutral float-left" title="Nested Interrupts" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
+ <a href="../glossary.html" class="btn btn-neutral float-right" title="Glossary" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
+ </div>
+
+ <hr/>
+
+ <div role="contentinfo">
+ <p>© Copyright 2020, The Apache Software Foundation.</p>
+ </div>
+
+
+
+</footer>
+ </div>
+ </div>
+ </section>
+ </div>
+ <script>
+ jQuery(function () {
+ SphinxRtdTheme.Navigation.enable(true);
+ });
+ </script>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/content/docs/latest/guides/cpp_cmake.html b/content/docs/latest/guides/cpp_cmake.html
index 212863c3..768bca62 100644
--- a/content/docs/latest/guides/cpp_cmake.html
+++ b/content/docs/latest/guides/cpp_cmake.html
@@ -128,6 +128,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/customapps.html b/content/docs/latest/guides/customapps.html
index 4b8d6554..b0f49baa 100644
--- a/content/docs/latest/guides/customapps.html
+++ b/content/docs/latest/guides/customapps.html
@@ -147,6 +147,7 @@
</li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/customboards.html b/content/docs/latest/guides/customboards.html
index 6aecff78..0f2db7ef 100644
--- a/content/docs/latest/guides/customboards.html
+++ b/content/docs/latest/guides/customboards.html
@@ -129,6 +129,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/drivers.html b/content/docs/latest/guides/drivers.html
index 5f6f406e..1b4d2f89 100644
--- a/content/docs/latest/guides/drivers.html
+++ b/content/docs/latest/guides/drivers.html
@@ -130,6 +130,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/index.html b/content/docs/latest/guides/index.html
index e8a87f6e..e794ada7 100644
--- a/content/docs/latest/guides/index.html
+++ b/content/docs/latest/guides/index.html
@@ -123,6 +123,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
@@ -309,6 +310,17 @@
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html#what-could-go-wrong">What Could Go Wrong?</a></li>
</ul>
</li>
+<li class="toctree-l1"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a><ul>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html#analyzing-the-register-dump">Analyzing the Register Dump</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html#analyzing-the-stack-dump">Analyzing the Stack Dump</a><ul>
+<li class="toctree-l3"><a class="reference internal" href="cortexmhardfaults.html#the-task-stack">The Task Stack</a></li>
+<li class="toctree-l3"><a class="reference internal" href="cortexmhardfaults.html#the-interrupt-stack">The Interrupt Stack</a></li>
+<li class="toctree-l3"><a class="reference internal" href="cortexmhardfaults.html#full-stack-analysis">Full Stack Analysis</a></li>
+</ul>
+</li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html#recovering-state-at-the-time-of-the-hardfault">Recovering State at the Time of the Hardfault</a></li>
+</ul>
+</li>
</ul>
</div>
</section>
diff --git a/content/docs/latest/guides/nestedinterrupts.html b/content/docs/latest/guides/nestedinterrupts.html
index 8ae9141b..3ae60548 100644
--- a/content/docs/latest/guides/nestedinterrupts.html
+++ b/content/docs/latest/guides/nestedinterrupts.html
@@ -44,7 +44,7 @@
<script src="../_static/js/theme.js"></script>
<link rel="index" title="Index" href="../genindex.html" />
<link rel="search" title="Search" href="../search.html" />
- <link rel="next" title="Glossary" href="../glossary.html" />
+ <link rel="next" title="Analyzing Cortex-M Hardfaults" href="cortexmhardfaults.html" />
<link rel="prev" title="High Performance, Zero Latency Interrupts" href="zerolatencyinterrupts.html" />
</head>
@@ -130,6 +130,7 @@
<li class="toctree-l3"><a class="reference internal" href="#what-could-go-wrong">What Could Go Wrong?</a></li>
</ul>
</li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
@@ -390,7 +391,7 @@ pretty low, but cannot be fully discounted.</p>
</div>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="zerolatencyinterrupts.html" class="btn btn-neutral float-left" title="High Performance, Zero Latency Interrupts" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
- <a href="../glossary.html" class="btn btn-neutral float-right" title="Glossary" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
+ <a href="cortexmhardfaults.html" class="btn btn-neutral float-right" title="Analyzing Cortex-M Hardfaults" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
diff --git a/content/docs/latest/guides/nfs.html b/content/docs/latest/guides/nfs.html
index 58860dd7..208975a1 100644
--- a/content/docs/latest/guides/nfs.html
+++ b/content/docs/latest/guides/nfs.html
@@ -129,6 +129,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/pysimcoder.html b/content/docs/latest/guides/pysimcoder.html
index 6fa5c5bf..9fe76c7d 100644
--- a/content/docs/latest/guides/pysimcoder.html
+++ b/content/docs/latest/guides/pysimcoder.html
@@ -128,6 +128,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/qemugdb.html b/content/docs/latest/guides/qemugdb.html
index 0f577ead..99204391 100644
--- a/content/docs/latest/guides/qemugdb.html
+++ b/content/docs/latest/guides/qemugdb.html
@@ -128,6 +128,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/rndis.html b/content/docs/latest/guides/rndis.html
index 089ff213..0bf546b5 100644
--- a/content/docs/latest/guides/rndis.html
+++ b/content/docs/latest/guides/rndis.html
@@ -128,6 +128,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/simulator.html b/content/docs/latest/guides/simulator.html
index 85b13d8e..a5fa642f 100644
--- a/content/docs/latest/guides/simulator.html
+++ b/content/docs/latest/guides/simulator.html
@@ -131,6 +131,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/tasktrace.html b/content/docs/latest/guides/tasktrace.html
index 087bbf8e..14525463 100644
--- a/content/docs/latest/guides/tasktrace.html
+++ b/content/docs/latest/guides/tasktrace.html
@@ -127,6 +127,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/tasktraceinternal.html b/content/docs/latest/guides/tasktraceinternal.html
index 85a8d8e6..624306c8 100644
--- a/content/docs/latest/guides/tasktraceinternal.html
+++ b/content/docs/latest/guides/tasktraceinternal.html
@@ -142,6 +142,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/tasktraceuser.html b/content/docs/latest/guides/tasktraceuser.html
index 9c4dc3e8..2fb24b01 100644
--- a/content/docs/latest/guides/tasktraceuser.html
+++ b/content/docs/latest/guides/tasktraceuser.html
@@ -148,6 +148,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/usbtrace.html b/content/docs/latest/guides/usbtrace.html
index 95acb75b..014e3f9c 100644
--- a/content/docs/latest/guides/usbtrace.html
+++ b/content/docs/latest/guides/usbtrace.html
@@ -123,6 +123,7 @@
<li class="toctree-l2"><a class="reference internal" href="customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/guides/zerolatencyinterrupts.html b/content/docs/latest/guides/zerolatencyinterrupts.html
index 9670ba49..78c442d5 100644
--- a/content/docs/latest/guides/zerolatencyinterrupts.html
+++ b/content/docs/latest/guides/zerolatencyinterrupts.html
@@ -137,6 +137,7 @@
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/index.html b/content/docs/latest/index.html
index ee6d425c..95e31c4b 100644
--- a/content/docs/latest/index.html
+++ b/content/docs/latest/index.html
@@ -150,7 +150,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<section id="nuttx-documentation">
<h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" title="Permalink to this heading"></a></h1>
<p>NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOS’s (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).</p>
-<p>Last Updated: 24 May 23 at 00:11</p>
+<p>Last Updated: 25 May 23 at 00:11</p>
<div class="toctree-wrapper compound">
<p class="caption" role="heading"><span class="caption-text">Table of Contents</span></p>
<ul class="current">
@@ -241,6 +241,7 @@ by following these <a class="reference internal" href="contributing/documentatio
<li class="toctree-l2"><a class="reference internal" href="guides/customapps.html">Custom Apps How-to</a></li>
<li class="toctree-l2"><a class="reference internal" href="guides/zerolatencyinterrupts.html">High Performance, Zero Latency Interrupts</a></li>
<li class="toctree-l2"><a class="reference internal" href="guides/nestedinterrupts.html">Nested Interrupts</a></li>
+<li class="toctree-l2"><a class="reference internal" href="guides/cortexmhardfaults.html">Analyzing Cortex-M Hardfaults</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="glossary.html">Glossary</a></li>
diff --git a/content/docs/latest/objects.inv b/content/docs/latest/objects.inv
index 4ef16814..25c57f9d 100644
Binary files a/content/docs/latest/objects.inv and b/content/docs/latest/objects.inv differ
diff --git a/content/docs/latest/reference/os/time_clock.html b/content/docs/latest/reference/os/time_clock.html
index 6795cb1a..984ca6e5 100644
--- a/content/docs/latest/reference/os/time_clock.html
+++ b/content/docs/latest/reference/os/time_clock.html
@@ -372,13 +372,13 @@ are, in increasing order of importance:</p>
<ul class="simple">
<li><p><strong>Overhead</strong>: Although the CPU usage of the system timer
interrupt at 100Hz is really very low, it is still mostly
-wasted processing time. One most timer interrupts, there is
-really nothing that needs be done other than incrementing the
+wasted processing time. On most timer interrupts, there is
+really nothing that needs to be done other than incrementing the
counter.</p></li>
<li><p><strong>Resolution</strong>: Resolution of all system timing is also
-determined by <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code>. So nothing that be time
-with resolution finer than 10 milliseconds be default. To
-increase this resolution, <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code> an be
+determined by <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code>. So nothing can be timed
+with resolution finer than 10 milliseconds by default. To
+increase this resolution, <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code> can be
reduced. However, then the system timer interrupts use more of
the CPU bandwidth processing useless interrupts.</p></li>
<li><p><strong>Power Usage</strong>: But the biggest issue is power usage. When the
@@ -389,7 +389,7 @@ low power mode. Therefore, higher rates of interrupts cause
greater power consumption.</p></li>
</ul>
<p><strong>Tickless OS</strong>. The so-called <em>Tickless OS</em> provides one solution
-to issue. The basic concept here is that the periodic, timer
+to this issue. The basic concept here is that the periodic, timer
interrupt is eliminated and replaced with a one-shot, interval
timer. It becomes event driven instead of polled: The default
system timer is a polled design. On each interrupt, the NuttX
@@ -415,17 +415,24 @@ explain how to provide the Tickless OS support to any platform.</p>
<ul>
<li><p><code class="docutils literal notranslate"><span class="pre">CONFIG_ARCH_HAVE_TICKLESS</span></code>: If the platform provides
support for the <em>Tickless OS</em>, then this setting should be
-selected in the <code class="docutils literal notranslate"><span class="pre">Kconfig</span></code> file for the board. Here is what
-the selection looks in the <code class="docutils literal notranslate"><span class="pre">arch/Kconfig</span></code> file for the
+selected in the <code class="docutils literal notranslate"><span class="pre">Kconfig</span></code> file for the architecture. Here is
+what the selection looks in the <code class="docutils literal notranslate"><span class="pre">arch/Kconfig</span></code> file for the
simulated platform:</p>
+<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="go">config ARCH_SIM</span>
+<span class="go"> bool "Simulation"</span>
+<span class="go"> select ARCH_HAVE_TICKLESS</span>
+<span class="go"> ---help---</span>
+<span class="go"> Linux/Cywgin user-mode simulation.</span>
+</pre></div>
+</div>
<p>When the simulation platform is selected,
<code class="docutils literal notranslate"><span class="pre">ARCH_HAVE_TICKLESS</span></code> is automatically selected, informing the
configuration system that <em>Tickless OS</em> options can be
selected.</p>
</li>
-<li><p><code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS</span></code>: If <code class="docutils literal notranslate"><span class="pre">CONFIG_ARCH_HAVE_TICKLESS</span></code>
-is selected, then it will enable the Tickless OS features in
-NuttX.</p></li>
+<li><p><code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS</span></code>: If <code class="docutils literal notranslate"><span class="pre">CONFIG_ARCH_HAVE_TICKLESS</span></code> is
+selected, then you will be able to use this option to enable the
+<em>Tickless OS</em> features in NuttX.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS_ALARM</span></code>: The tickless option can be
supported either via a simple interval timer (plus elapsed
time) or via an alarm. The interval timer allows programming
@@ -434,15 +441,15 @@ a time in the future and get an event when that alarm goes off.
This option selects the use of an alarm.</p>
<p>The advantage of an alarm is that it avoids some small timing
errors; the advantage of the use of the interval timer is that
-the hardware requirement may be less.</p>
+the hardware requirement may be simpler.</p>
</li>
<li><p><code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code>: This option is not unique to
<em>Tickless OS</em> operation, but changes its relevance when the
-<em>Tickless OS</em> is selected. In the default configuration where
+<em>Tickless OS</em> is selected. In the default configuration, where
system time is provided by a periodic timer interrupt, the
-default system timer is configure the timer for 100Hz or
+default system timer is configured for 100Hz, that is,
<code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK=10000</span></code>. If <code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS</span></code> is
-selected, then there are no system timer interrupt. In this
+selected, then there are no system timer interrupts. In this
case, <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code> does not control any timer
rates. Rather, it only determines the resolution of time
reported by <code class="docutils literal notranslate"><span class="pre">clock_systime_ticks()</span></code> and the resolution of
@@ -498,25 +505,22 @@ interval timer.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">up_timer_start()</span></code>: Starts (or re-starts)
the interval timer.</p></li>
</ul>
-<p>Note that a platform-specific implementation would probably
-require two hardware timers: (1) A interval timer to satisfy the
-requirements of <code class="docutils literal notranslate"><span class="pre">up_timer_start()</span></code> and
-<code class="docutils literal notranslate"><span class="pre">up_timer_cancel()</span></code>, and a (2) a counter to
-handle the requirement of
-<code class="docutils literal notranslate"><span class="pre">up_timer_gettime()</span></code>. Ideally, both timers
+<p>Note that a platform-specific implementation would probably require two
+hardware timers: (1) A interval timer to satisfy the requirements of
+<code class="docutils literal notranslate"><span class="pre">up_timer_start()</span></code> and <code class="docutils literal notranslate"><span class="pre">up_timer_cancel()</span></code>, and (2) a counter to
+handle the requirement of <code class="docutils literal notranslate"><span class="pre">up_timer_gettime()</span></code>. Ideally, both timers
would run at the rate determined by <code class="docutils literal notranslate"><span class="pre">CONFIG_USEC_PER_TICK</span></code> (and
certainly never slower than that rate).</p>
-<p>Since timers are a limited resource, the use of two timers could
-be an issue on some systems. The job could be done with a single
-timer if, for example, the single timer were kept in a
-free-running at all times. Some timer/counters have the capability
-to generate a compare interrupt when the timer matches a
-comparison value but also to continue counting without stopping.
-If your hardware supports such counters, one might used the
-<code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS_ALARM</span></code> option and be able to simply set
-the comparison count at the value of the free running timer <em>PLUS</em>
-the desired delay. Then you could have both with a single timer:
-An alarm and a free-running counter with the same timer!</p>
+<p>Since timers are a limited resource, the use of two timers could be an
+issue on some systems. The job could be done with a single timer if, for
+example, the single timer were kept in a free-running mode at all times.
+Some timer/counters have the capability to generate a compare interrupt
+when the timer matches a comparison value but also to continue counting
+without stopping. If your hardware supports such counters, one might use
+the <code class="docutils literal notranslate"><span class="pre">CONFIG_SCHED_TICKLESS_ALARM</span></code> option and be able to simply set the
+comparison count at the value of the free running timer <em>PLUS</em> the
+desired delay. Then you could have both with a single timer: An alarm
+and a free-running counter with the same timer!</p>
<p>In addition to these imported interfaces, the RTOS will export the
following interfaces for use by the platform-specific interval
timer implementation:</p>
diff --git a/content/docs/latest/reference/user/07_signals.html b/content/docs/latest/reference/user/07_signals.html
index f019b808..4160c841 100644
--- a/content/docs/latest/reference/user/07_signals.html
+++ b/content/docs/latest/reference/user/07_signals.html
@@ -280,7 +280,7 @@ provided by NuttX:</p>
<li><p><a class="reference internal" href="#c.sigaddset" title="sigaddset"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigaddset()</span></code></a></p></li>
<li><p><a class="reference internal" href="#c.sigdelset" title="sigdelset"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigdelset()</span></code></a></p></li>
<li><p><a class="reference internal" href="#c.sigismember" title="sigismember"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigismember()</span></code></a></p></li>
-<li><p><a class="reference internal" href="structures.html#c.sigaction" title="sigaction"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigaction()</span></code></a></p></li>
+<li><p><a class="reference internal" href="#c.sigaction" title="sigaction"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigaction()</span></code></a></p></li>
<li><p><a class="reference internal" href="#c.sigignore" title="sigignore"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigignore()</span></code></a></p></li>
<li><p><a class="reference internal" href="#c.sigset" title="sigset"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigset()</span></code></a></p></li>
<li><p><a class="reference internal" href="#c.sigprocmask" title="sigprocmask"><code class="xref c c-func docutils literal notranslate"><span class="pre">sigprocmask()</span></code></a></p></li>
@@ -402,7 +402,7 @@ name.</p>
<dl class="c function">
<dt class="sig sig-object c" id="c.sigaction">
-<span class="kt"><span class="pre">int</span></span><span class="w"> </span><span class="sig-name descname"><span class="n"><span class="pre">sigaction</span></span></span><span class="sig-paren">(</span><span class="kt"><span class="pre">int</span></span><span class="w"> </span><span class="n"><span class="pre">signo</span></span>, <span class="k"><span class="pre">const</span></span><span class="w"> </span><span class="k"><span class="pre">struct</span></span><span class="w"> </span><a [...]
+<span class="kt"><span class="pre">int</span></span><span class="w"> </span><span class="sig-name descname"><span class="n"><span class="pre">sigaction</span></span></span><span class="sig-paren">(</span><span class="kt"><span class="pre">int</span></span><span class="w"> </span><span class="n"><span class="pre">signo</span></span>, <span class="k"><span class="pre">const</span></span><span class="w"> </span><span class="k"><span class="pre">struct</span></span><span class="w"> </span><a [...]
<dd><p>Allows the calling task to examine and/or
specify the action to be associated with a specific signal.</p>
<p>The structure sigaction, used to describe an action to be taken, is
diff --git a/content/docs/latest/reference/user/structures.html b/content/docs/latest/reference/user/structures.html
index ad113101..52c9034b 100644
--- a/content/docs/latest/reference/user/structures.html
+++ b/content/docs/latest/reference/user/structures.html
@@ -310,7 +310,7 @@ NuttX and a MoBY application:</p>
</div>
<dl class="c struct">
<dt class="sig sig-object c" id="c.sigaction">
-<span class="k"><span class="pre">struct</span></span><span class="w"> </span><span class="sig-name descname"><span class="n"><span class="pre">sigaction</span></span></span><a class="headerlink" href="#c.sigaction" title="Permalink to this definition"></a><br /></dt>
+<span class="k"><span class="pre">struct</span></span><span class="w"> </span><span class="sig-name descname"><span class="n"><span class="pre">sigaction</span></span></span><br /></dt>
<dd></dd></dl>
<p>The following structure defines the action to take for given signal:</p>
diff --git a/content/docs/latest/searchindex.js b/content/docs/latest/searchindex.js
index b09c437c..be53d0b7 100644
--- a/content/docs/latest/searchindex.js
+++ b/content/docs/latest/searchindex.js
@@ -1 +1 @@
-Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "applications/wapi/commands", "applications/wapi/index", "applications/wapi/wireless", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can" [...]
\ No newline at end of file
+Search.setIndex({"docnames": ["applications/index", "applications/nsh/builtin", "applications/nsh/commands", "applications/nsh/config", "applications/nsh/customizing", "applications/nsh/index", "applications/nsh/installation", "applications/nsh/login", "applications/nsh/nsh", "applications/wapi/commands", "applications/wapi/index", "applications/wapi/wireless", "components/binfmt", "components/drivers/block/index", "components/drivers/character/analog", "components/drivers/character/can" [...]
\ No newline at end of file
diff --git a/content/feed.xml b/content/feed.xml
index 1e922413..4ee800af 100644
--- a/content/feed.xml
+++ b/content/feed.xml
@@ -5,8 +5,8 @@
<description></description>
<link>/</link>
<atom:link href="/feed.xml" rel="self" type="application/rss+xml"/>
- <pubDate>Wed, 24 May 2023 00:12:10 +0000</pubDate>
- <lastBuildDate>Wed, 24 May 2023 00:12:10 +0000</lastBuildDate>
+ <pubDate>Thu, 25 May 2023 00:12:32 +0000</pubDate>
+ <lastBuildDate>Thu, 25 May 2023 00:12:32 +0000</lastBuildDate>
<generator>Jekyll v4.3.2</generator>
<item>