你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

az sphere device capability

Note

This reference is part of the azure-sphere extension for the Azure CLI (version 2.45.0 or higher). 该扩展将在首次运行 az sphere device capability 命令时自动安装。 Learn more about extensions.

管理设备功能配置。

命令

名称 说明 类型 Status
az sphere device capability apply

暂时在附加设备上应用功能会话。

Extension GA
az sphere device capability download

从 Azure Sphere 安全服务下载设备功能文件。

Extension GA
az sphere device capability show-attached

显示附加设备的当前设备功能配置。

Extension GA
az sphere device capability update

更新附加设备的设备功能配置。

Extension GA

az sphere device capability apply

暂时在附加设备上应用功能会话。

az sphere device capability apply [--capability-file]
                                  [--none {false, true}]

示例

暂时应用设备功能会话。

az sphere device capability apply --capability-file myCapabilities.cap

结束临时应用的设备功能会话。

az sphere device capability apply --none

可选参数

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--capability-file

功能文件的路径和文件名。 可以提供相对路径或绝对路径。

--none -n

结束附加设备上的临时功能会话。

属性
默认值: False
接受的值: false, true
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

仅显示错误,禁止显示警告。

属性
默认值: False
--output -o

Output format.

属性
默认值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

增加日志记录详细程度。 使用 --debug 获取完整的调试日志。

属性
默认值: False

az sphere device capability download

从 Azure Sphere 安全服务下载设备功能文件。

az sphere device capability download --catalog
                                     --resource-group
                                     [--device]
                                     [--output-file]
                                     [--type {ApplicationDevelopment, FieldServicing}]

示例

使用资源组、目录名称、设备 ID 和功能下载设备的“ApplicationDevelopment”功能。

az sphere device capability download --resource-group MyResourceGroup --catalog MyCatalog --device <DeviceIdValue> --type ApplicationDevelopment --output-file myCapabilities.cap

使用资源组、目录名称和设备 ID 下载设备的“无”功能。

az sphere device capability download --resource-group MyResourceGroup --catalog MyCatalog --device <DeviceIdValue> --output-file myCapabilities.cap

必需参数

--catalog -c

用于执行此操作的 Azure Sphere 目录。 指定 Azure Sphere 目录名称。 可以使用 az config set defaults.sphere.catalog=<name>配置默认的 Azure Sphere 目录。 值来源:az sphere catalog list。

--resource-group -g

Azure 资源组的名称。 可以使用 az config set defaults.group=<name>配置默认组。 值来源:az group list。

可选参数

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--device -d

要针对此命令的设备。 当未附加任何设备或多台设备时,必须这样做才能消除要面向的设备。 如果设备已附加,则可以提供设备 ID、IP 地址或本地连接 ID。 否则,必须仅提供设备 ID。

属性
值来源: az sphere device list
--output-file -of

要在其中下载功能的路径和文件名。 如果未设置此参数,该文件将保存在具有默认名称(capability-device.cap)的当前文件夹中。

--type -t

要下载的功能的空间分隔列表。 如果未设置此参数,则会下载功能“None”。

属性
接受的值: ApplicationDevelopment, FieldServicing
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

仅显示错误,禁止显示警告。

属性
默认值: False
--output -o

Output format.

属性
默认值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

增加日志记录详细程度。 使用 --debug 获取完整的调试日志。

属性
默认值: False

az sphere device capability show-attached

显示附加设备的当前设备功能配置。

az sphere device capability show-attached [--device]

示例

显示附加设备的设备功能配置。

az sphere device capability show-attached

显示指定设备的设备功能配置。

az sphere device capability show-attached --device <DeviceIdValue>

可选参数

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--device -d

在附加多个设备时运行命令的设备。 指定附加设备的 ID、IP 地址或本地连接 ID。

属性
值来源: az sphere device list-attached
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

仅显示错误,禁止显示警告。

属性
默认值: False
--output -o

Output format.

属性
默认值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

增加日志记录详细程度。 使用 --debug 获取完整的调试日志。

属性
默认值: False

az sphere device capability update

更新附加设备的设备功能配置。

az sphere device capability update --capability-file
                                   [--device]

示例

更新附加设备的设备功能配置。

az sphere device capability update --capability-file myCapabilities.cap

更新指定设备的设备功能配置。

az sphere device capability update --capability-file myCapabilities.cap --device <DeviceIdValue>

必需参数

--capability-file

要应用的设备功能配置文件的路径和文件名。

可选参数

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--device -d

在附加多个设备时运行命令的设备。 指定附加设备的 ID、IP 地址或本地连接 ID。

属性
值来源: az sphere device list-attached
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

仅显示错误,禁止显示警告。

属性
默认值: False
--output -o

Output format.

属性
默认值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

增加日志记录详细程度。 使用 --debug 获取完整的调试日志。

属性
默认值: False