diff options
Diffstat (limited to 'nuttx')
-rw-r--r-- | nuttx/ChangeLog | 7 | ||||
-rw-r--r-- | nuttx/Documentation/NuttX.html | 9 | ||||
-rw-r--r-- | nuttx/examples/nsh/nsh_main.c | 12 |
3 files changed, 24 insertions, 4 deletions
diff --git a/nuttx/ChangeLog b/nuttx/ChangeLog index 5ad653a30..0306a28de 100644 --- a/nuttx/ChangeLog +++ b/nuttx/ChangeLog @@ -1535,3 +1535,10 @@ * drivers/uart_16550.c and include/nuttx/uart_16550.h - Support for a generic 16550 UART. * configure/qemu-i486/nsh - QEMU NSH example. + * ../apps - The apps directory add-on was created by Uros Platise. It + supports a set of end-user applications than can be executed on top of + NSH. Think of it this way: In a buckled-up embedded application, your + end-user programs will probably have their own dedicated start-up logic. + But, during development, you might want to have you applications + available and executable from the NSH command line. This apps/ addon + (and NSH hooks) was contributed by Uros to accomplish just that. diff --git a/nuttx/Documentation/NuttX.html b/nuttx/Documentation/NuttX.html index 38e62ec95..a3763dcef 100644 --- a/nuttx/Documentation/NuttX.html +++ b/nuttx/Documentation/NuttX.html @@ -8,7 +8,7 @@ <tr align="center" bgcolor="#e4e4e4"> <td> <h1><big><font color="#3c34ec"><i>NuttX RTOS</i></font></big></h1> - <p>Last Updated: March 9, 2011</p> + <p>Last Updated: March 11, 2011</p> </td> </tr> </table> @@ -2159,6 +2159,13 @@ nuttx-5.19 2011-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr> * drivers/uart_16550.c and include/nuttx/uart_16550.h - Support for a generic 16550 UART. * configure/qemu-i486/nsh - QEMU NSH example. + * ../apps - The apps directory add-on was created by Uros Platise. It + supports a set of end-user applications than can be executed on top of + NSH. Think of it this way: In a buckled-up embedded application, your + end-user programs will probably have their own dedicated start-up logic. + But, during development, you might want to have you applications + available and executable from the NSH command line. This apps/ addon + (and NSH hooks) was contributed by Uros to accomplish just that. pascal-2.1 2011-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr> diff --git a/nuttx/examples/nsh/nsh_main.c b/nuttx/examples/nsh/nsh_main.c index 680267e43..f9a34f0a1 100644 --- a/nuttx/examples/nsh/nsh_main.c +++ b/nuttx/examples/nsh/nsh_main.c @@ -492,12 +492,18 @@ static int nsh_execute(FAR struct nsh_vtbl_s *vtbl, int argc, char *argv[]) } } + /* If the command was not found, then try to execute the command from + * a list of pre-built applications. + */ + #ifdef CONFIG_EXAMPLES_NSH_BUILTIN_APPS - if (handler == cmd_unrecognized) + if (handler == cmd_unrecognized && nsh_execapp(vtbl, cmd, argv) == OK) { - /* Try to execute the command from a list of pre-built applications. */ + /* The pre-built application was successfully started -- run OK. + * If not, then fall through to execute the cmd_nrecognized handler. + */ - return nsh_execapp(vtbl, cmd, argv); + return OK; } #endif |