-
Notifications
You must be signed in to change notification settings - Fork 0
Reference Tokens NVM3 LittleFS
Command suites for manufacturing tokens, NVM3 storage, and the LittleFS filesystem. All methods return a dict. See Command-Reference for shared conventions.
Common token parameters:
-
tokengroup— a built-in token set:common,zigbee, orznet. -
tokendefs— path to a JSON file defining a token set (alternative totokengroup). -
tokens—(TOKEN_NAME, value)pairs. -
securerange/range—(start, end)tuples.
Handling of manufacturing tokens.
Create a token header file at filename.
Erase tokens (on device or in a secure range). type: secure or device (static tokens only). tokens is a list of token names.
read(filenames=None, outfile=None, showoverrides=False, tokens=[], securerange=None, tokengroup=None, tokendefs=None, range=None, type=None, includeall=False, address=None, **kwargs)
Read tokens from the device or from file(s).
-
filenames— read from these files instead of the device. -
outfile— write output here (otherwise stdout). -
showoverrides— show NVM3 overrides (static tokens only). -
tokens— limit output to these token names. -
range— NVM3 area range;securerange— static secure-token range. -
type—secureordevice;includeall— show all tokens in the group (static only). -
address— memory address.
Write tokens to the device. tokens values are hex strings.
Target.writeManufacturingTokens()/writeStaticTokens()wraptokens writefor Series 1/2 and Series 3 respectively.
NVM3 (non-volatile memory) storage. Object keys are integers; helper methods format objects/counters as 0xKKKKK:value.
Delete NVM3 objects from a file; write the result to outfile. object_keys are keys to delete; delete_all=True deletes everything.
Delete NVM3 objects on the device.
Dump NVM3 contents to outfile.
Create an initialized NVM3 file of size_bytes for device.
Parse an NVM3 file and optionally export objects to nvm3file.
Read NVM3 objects from the device (optionally to nvm3file).
set(filename, outfile, address=None, range=None, objects=None, counters=None, nvm3file=None, **kwargs)
Set NVM3 objects/counters in a file; write to outfile.
-
objects: list[tuple[int, bytes]]—(key, data)entries. -
counters: list[tuple[int, int]]—(key, value)entries.
Write NVM3 objects/counters to the device.
Interact with a LittleFS filesystem. Filesystem location is given by address, range, or infile (a binary containing the filesystem).
Add file(s)/dir(s) to a filesystem and write it to outfile.
Dump the filesystem to outfile.
extract(dest_dir=None, zip_dir=None, file_paths=[], dir_paths=[], address=None, range=None, infile=None, **kwargs)
Extract file(s)/dir(s) to dest_dir, or into a zip at zip_dir.
Show filesystem info.
Initialize a new filesystem for device and write it to outfile. size is in bytes. (Note: the Commander's configured target_device is intentionally not applied here — device is passed explicitly.)
List files in the filesystem. (Maps to the CLI littlefs list command.)
Remove file(s)/dir(s) from the filesystem.
PyCommander · GitHub · Simplicity Commander docs · Licensed under the Silicon Labs MSLA
Getting started
Using PyCommander
Topics
Command reference
- Overview
- adapter · aem · vcom · ctune
- device · flash · verify · readmem · extflash
- security
- tokens · nvm3 · littlefs
- convert · ebl · gbl3 · gbl4 · ota · rps · postbuild
- util · serial · mfg917
Contributing