Repository: incubator-mynewt-site Updated Branches: refs/heads/master dbce794f8 -> cb9f939e6
added a new customize newtmgr section. This closes #144. Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-site/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-site/commit/cb9f939e Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-site/tree/cb9f939e Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-site/diff/cb9f939e Branch: refs/heads/master Commit: cb9f939e680a345c2ef0b726a84c3d401f21abb7 Parents: dbce794 Author: aditihilbert <[email protected]> Authored: Fri Jan 27 10:28:53 2017 -0800 Committer: aditihilbert <[email protected]> Committed: Fri Jan 27 10:28:53 2017 -0800 ---------------------------------------------------------------------- docs/os/modules/devmgmt/customize_newtmgr.md | 55 +++++++++++++++++++++++ 1 file changed, 55 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-mynewt-site/blob/cb9f939e/docs/os/modules/devmgmt/customize_newtmgr.md ---------------------------------------------------------------------- diff --git a/docs/os/modules/devmgmt/customize_newtmgr.md b/docs/os/modules/devmgmt/customize_newtmgr.md new file mode 100644 index 0000000..3678b24 --- /dev/null +++ b/docs/os/modules/devmgmt/customize_newtmgr.md @@ -0,0 +1,55 @@ +## Customizing Newt Manager Usage with mgmt + +The **mgmt** package enables you to customize Newt Manager (in either the newtmgr or oicmgr framerwork) to only process the +commands that your application uses. The newtmgr commands are divided into management groups. +A manager package implements the commands for a group. It implements the handlers that +process the commands for the group and registers the handlers with mgmt. +When newtmgr or oicmgr receives a newtmgr command, +it looks up the handler for the command (by management group id and command id) from mgmt and calls the +handler to process the command. + +The system level management groups are listed in following table: +<table style="width:90%" align="center"> +<tt> +<td>Management Group</td> +<td>newtmgr Commands</td> +<td>Package</td> +</tt> +<tr> +<td>MGMT_GROUP_ID_DEFAULT</td> +<td>```echo``` ```taskstats``` ```mpstats``` ```datetime``` ```reset```</td> +<td>mgmt/newtmgr/nmgr_os</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_IMAGE</td> +<td>```image``` </td> +<td>mgmt/imgmgr</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_STATS</td> +<td>```stat``` </td> +<td>sys/stats</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_CONFIG</td> +<td>```config```</td> +<td>sys/config</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_LOGS</td> +<td>```log```</td> +<td>sys/log</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_CRASH</td> +<td>```crash```</td> +<td>test/crash_test</td> +</tr> +<tr> +<td>MGMT_GROUP_ID_RUNTEST</td> +<td>```run```</td> +<td>test/runtest</td> +</tr> +</table> +Both newtmgr and ocimgr process the MGMT_GROUP_ID_DEFAULT commands by default. You can also +use mgmt to add user defined management group commands.
