
sample: examples\aliyun_iotkit_csdk_mqtt project: board\TencentOS_tiny_EVB_MX_Plus\KEIL\aliyun_iotkit_csdk_mqtt
223 lines
6.3 KiB
JSON
223 lines
6.3 KiB
JSON
{
|
|
"schema":"https://iotx-tsl.oss-ap-southeast-1.aliyuncs.com/schema.json",
|
|
"profile":{
|
|
"productKey":"a1h88DsZIaY"
|
|
},
|
|
"services":[
|
|
{
|
|
"outputData":[
|
|
|
|
],
|
|
"identifier":"set",
|
|
"inputData":[
|
|
{
|
|
"identifier":"LightStatus",
|
|
"dataType":{
|
|
"specs":{
|
|
"0":"关闭",
|
|
"1":"打开"
|
|
},
|
|
"type":"bool"
|
|
},
|
|
"name":"工作状态"
|
|
},
|
|
{
|
|
"identifier":"LightAdjustLevel",
|
|
"dataType":{
|
|
"specs":{
|
|
"unit":"%",
|
|
"min":"0",
|
|
"max":"100",
|
|
"step":"1"
|
|
},
|
|
"type":"int"
|
|
},
|
|
"name":"调光等级"
|
|
},
|
|
{
|
|
"identifier":"LightAlias",
|
|
"dataType":{
|
|
"specs":{
|
|
"length":"32"
|
|
},
|
|
"type":"text"
|
|
},
|
|
"name":"别名"
|
|
}
|
|
],
|
|
"method":"thing.service.property.set",
|
|
"name":"set",
|
|
"required":true,
|
|
"callType":"async",
|
|
"desc":"属性设置"
|
|
},
|
|
{
|
|
"outputData":[
|
|
{
|
|
"identifier":"LightStatus",
|
|
"dataType":{
|
|
"specs":{
|
|
"0":"关闭",
|
|
"1":"打开"
|
|
},
|
|
"type":"bool"
|
|
},
|
|
"name":"工作状态"
|
|
},
|
|
{
|
|
"identifier":"LightAdjustLevel",
|
|
"dataType":{
|
|
"specs":{
|
|
"unit":"%",
|
|
"min":"0",
|
|
"max":"100",
|
|
"step":"1"
|
|
},
|
|
"type":"int"
|
|
},
|
|
"name":"调光等级"
|
|
},
|
|
{
|
|
"identifier":"LightAlias",
|
|
"dataType":{
|
|
"specs":{
|
|
"length":"32"
|
|
},
|
|
"type":"text"
|
|
},
|
|
"name":"别名"
|
|
}
|
|
],
|
|
"identifier":"get",
|
|
"inputData":[
|
|
"LightStatus",
|
|
"LightAdjustLevel",
|
|
"LightAlias"
|
|
],
|
|
"method":"thing.service.property.get",
|
|
"name":"get",
|
|
"required":true,
|
|
"callType":"async",
|
|
"desc":"属性获取"
|
|
}
|
|
],
|
|
"properties":[
|
|
{
|
|
"identifier":"LightStatus",
|
|
"dataType":{
|
|
"specs":{
|
|
"0":"关闭",
|
|
"1":"打开"
|
|
},
|
|
"type":"bool"
|
|
},
|
|
"name":"工作状态",
|
|
"accessMode":"rw",
|
|
"required":false
|
|
},
|
|
{
|
|
"identifier":"LightAdjustLevel",
|
|
"dataType":{
|
|
"specs":{
|
|
"unit":"%",
|
|
"min":"0",
|
|
"max":"100",
|
|
"step":"1"
|
|
},
|
|
"type":"int"
|
|
},
|
|
"name":"调光等级",
|
|
"accessMode":"rw",
|
|
"required":false,
|
|
"desc":"调光等级采用百分比表示"
|
|
},
|
|
{
|
|
"identifier":"LightAlias",
|
|
"dataType":{
|
|
"specs":{
|
|
"length":"32"
|
|
},
|
|
"type":"text"
|
|
},
|
|
"name":"别名",
|
|
"accessMode":"rw",
|
|
"required":false
|
|
}
|
|
],
|
|
"events":[
|
|
{
|
|
"outputData":[
|
|
{
|
|
"identifier":"LightStatus",
|
|
"dataType":{
|
|
"specs":{
|
|
"0":"关闭",
|
|
"1":"打开"
|
|
},
|
|
"type":"bool"
|
|
},
|
|
"name":"工作状态"
|
|
},
|
|
{
|
|
"identifier":"LightAdjustLevel",
|
|
"dataType":{
|
|
"specs":{
|
|
"unit":"%",
|
|
"min":"0",
|
|
"max":"100",
|
|
"step":"1"
|
|
},
|
|
"type":"int"
|
|
},
|
|
"name":"调光等级"
|
|
},
|
|
{
|
|
"identifier":"LightAlias",
|
|
"dataType":{
|
|
"specs":{
|
|
"length":"32"
|
|
},
|
|
"type":"text"
|
|
},
|
|
"name":"别名"
|
|
}
|
|
],
|
|
"identifier":"post",
|
|
"method":"thing.event.property.post",
|
|
"name":"post",
|
|
"type":"info",
|
|
"required":true,
|
|
"desc":"属性上报"
|
|
},
|
|
{
|
|
"outputData":[
|
|
{
|
|
"identifier":"ErrorCode",
|
|
"dataType":{
|
|
"specs":{
|
|
"0":"恢复正常"
|
|
},
|
|
"type":"enum"
|
|
},
|
|
"name":"故障代码"
|
|
}
|
|
],
|
|
"identifier":"Error",
|
|
"method":"thing.event.Error.post",
|
|
"name":"故障上报",
|
|
"type":"alert",
|
|
"required":false
|
|
},
|
|
{
|
|
"outputData":[
|
|
|
|
],
|
|
"identifier":"TamperAlarm",
|
|
"method":"thing.event.TamperAlarm.post",
|
|
"name":"防撬报警",
|
|
"type":"alert",
|
|
"required":false
|
|
}
|
|
]
|
|
}
|