This is an automated email from the ASF dual-hosted git repository.

GUIDINGLI pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
     new 39013a42733 Documentation/nxinit: describe wait
39013a42733 is described below

commit 39013a42733b10369269186ae4f0f95aadcf0de7
Author: wangjianyu3 <[email protected]>
AuthorDate: Wed Nov 25 14:50:35 2026 +0800

    Documentation/nxinit: describe wait
    
    NXInit now has the wait command.  Give its syntax and say that a
    timeout only warns and continues.
    
    Assisted-by: OpenCode:mimo-v2.6-pro
    Co-authored-by: multica-agent <[email protected]>
    Signed-off-by: wangjianyu3 <[email protected]>
---
 Documentation/applications/system/nxinit/index.rst | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/Documentation/applications/system/nxinit/index.rst 
b/Documentation/applications/system/nxinit/index.rst
index a92ad36e377..a351e62c810 100644
--- a/Documentation/applications/system/nxinit/index.rst
+++ b/Documentation/applications/system/nxinit/index.rst
@@ -233,6 +233,7 @@ These are the built-in commands of NXInit:
 - Service management: ``start``/``stop`` (start/stop a service),
   ``exec_start`` (start a service and wait until it exits),
   ``class_start``/``class_stop`` (start/stop all services of a class).
+- Waiting: ``wait`` (wait for a file, see below).
 - Programs: ``exec -- <program> [<argument>]*`` (run a program and wait until
   it exits).
 - Others: ``trigger`` (trigger an event), and ``netinit``, ``boot``,
@@ -284,6 +285,25 @@ arguments dumps the PM statistics; NXInit does not have 
that form, which
 init does not need. With ``CONFIG_PM`` disabled, NXInit has no
 ``pmconfig`` command.
 
+Waiting for a File
+------------------
+
+.. code-block::
+
+    wait <path> [<timeout>]
+
+``wait`` checks for the existence of ``<path>`` with stat() every 10 ms
+and returns when the file is found. ``<timeout>`` is in seconds and may
+be fractional; it defaults to 5. When the timeout is reached, the
+command only warns and continues, so the next command still runs.
+
+.. code-block::
+
+    on boot
+        start foo_driver
+        wait /dev/xxx 2
+        start bar
+
 Compound Commands
 ------------------
 

Reply via email to