在 Alexa 发现过程中,我们需要发送设备详细信息及其功能。我正在发送灯光和风扇详细信息。Light 出现在 Alexa 应用程序中,但没有出现在风扇中。你能帮我找出我在以下回复中做错了什么吗?
我使用这个 Alexa 文档来创建响应。https://developer.amazon.com/docs/smarthome/connect-a-tower-fan-to-alexa.html
{
"event": {
"header": {
"namespace": "Alexa.Discovery",
"name": "Discover.Response",
"payloadVersion": "3",
"messageId": "somd-id"
},
"payload": {
"endpoints": [
{
"endpointId": "fan-i",
"friendlyName": "Fan",
"description": "Fan",
"manufacturerName": "Fan",
"displayCategories": [
"OTHER"
],
"cookie": {},
"capabilities": [
{
"type": "AlexaInterface",
"interface": "Alexa.PowerController",
"version": "3",
"properties": {
"supported": [
{
"name": "powerState"
}
],
"proactivelyReported": true,
"retrievable": true
}
},
{
"type": "AlexaInterface",
"interface": "Alexa.RangeController",
"version": "3",
"instance": "speed",
"capabilityResources": {
"friendlyNames": [
{
"@type": "asset",
"value": {
"assetId": "Alexa.Setting.FanSpeed"
}
}
]
},
"properties": {
"supported": [
{
"name": "rangeValue"
}
],
"proactivelyReported": true,
"retrievable": true
},
"configuration": {
"supportedRange": {
"minimumValue": 1,
"maximumValue": 5,
"precision": 1
},
"presets": [
{
"rangeValue": 1,
"presetResources": {
"friendlyNames": [
{
"@type": "asset",
"value": {
"assetId": "Alexa.Value.Minimum"
}
},
{
"@type": "asset",
"value": {
"assetId": "Alexa.Value.Low"
}
}
]
}
},
{
"rangeValue": 5,
"presetResources": {
"friendlyNames": [
{
"@type": "asset",
"value": {
"assetId": "Alexa.Value.Maximum"
}
},
{
"@type": "asset",
"value": {
"assetId": "Alexa.Value.High"
}
}
]
}
},
{
"rangeValue": 3,
"presetResources": {
"friendlyNames": [
{
"@type": "asset",
"value": {
"assetId": "Alexa.Value.Medium"
}
}
]
}
}
]
}
},
{
"type": "AlexaInterface",
"interface": "Alexa",
"version": "3"
}
]
},
]
}
}
}
注意:我只是在下面重复上面的问题,因为 StackOverflow 不允许粘贴太多代码而描述较少。
在 Alexa 发现过程中,我们需要发送设备详细信息及其功能。我正在发送灯光和风扇详细信息。Light 出现在 Alexa 应用程序中,但没有出现在风扇中。你能帮我找出我在以下回复中做错了什么吗?