Hi Kevin, On Fri, Jul 06, 2018 at 02:41:17PM +0200, Kevin Townsend wrote: > I'm doing some initial development using only the simulator (for > convenience sake), and was testing out 'newtmgr fs' support to quickly > get data to and from the simulator. > > My sim target is setup to use NFFS using mostly default values: > > # NFFS filesystem > FS_CLI: 1 # Include shell FS commands > CONFIG_NFFS: 1 # Initialize and configure NFFS into the > system > NFFS_DETECT_FAIL: 2 # Format a new NFFS file system on > failure to detect > > Everything works fine from shell when I start the .elf file and create > an NFFS file in code, and I can see the file and contents via cat: > > ls /cfg > 604693 5 /cfg/id.txt > 604693 1 files > 604900 compat> cat /cfg/id.txt > 5678 > > But when I try to do anything with 'newtmgr fs' (up or down) I always > get *error 5*, which I assume corresponds to > https://github.com/apache/mynewt-core/blob/master/fs/fs/include/fs/fs.h#L72:
The error codes that come back in newtmgr responses are always (or at least should be) MGMT_ERR codes: https://github.com/apache/mynewt-core/blob/42bb5acc2f049d346c81f25e8c354bc3c6afefd4/mgmt/mgmt/include/mgmt/mgmt.h#L65 `MGMT_ERR_ENOENT` is indicated when the newtmgr command isn't recognized (it is also used for other conditions; seems like we should have a dedicated error code for "command not supported). Did you enable the `FS_NMGR` syscfg setting? Chris