miot-spec-doc
miot-spec-doc copied to clipboard
请问 设备端属性"prop":"switch" 和云端"type": "urn:miot-spec-v2:property:on ....."是 如何对应转换的了?
请教一个问题:
例如,一个只有开关属性的灯,
- 设备端定义属性名称为: switch
- 云端设备描述使用的是"type": "urn:miot-spec-v2:property:on:00000006:philips-moonlight:1"
- App端使用https请求 GET /api/v1/properties?pid=AAAD.1.1,AAAD.2.3 其中App和云端通过www.miot-spec.org规范定义,相互转化是比较明确且容易实现的.
请问 设备端属性 "prop":"switch" 和云端 "type": "urn:miot-spec-v2:property:on ....." 是 如何对应转换的了?
通过分类这些prop,对所有prop做了分组,详细见规范 https://iot.mi.com/new/guide.html?file=07-%E4%BA%91%E5%AF%B9%E4%BA%91%E5%BC%80%E5%8F%91%E6%8C%87%E5%8D%97/02-%E5%BA%94%E7%94%A8%E4%BA%91%E5%AF%B9%E4%BA%91%E6%8E%A5%E5%85%A5/01-%E5%B0%8F%E7%B1%B3IOT%E5%8D%8F%E8%AE%AE%E8%A7%84%E8%8C%83