I take it from the core spec that an OCF server contains a single instance
of /oic/p, but may encompass multiple logical OCF devices.
One of these devices MUST exist at /oic/d. Lets call this the
primary device. Other devices may be specified by verticals each
at some URI (anything but /oic/d). Lets call these secondary devices.
For an /oic/res response, it is required that all resources be
organized under their logical device.
1) Is my above understanding accurate?
2) Should /oic/p then be listed under the designated primary device?
3) Does the following /oic/res response comply with the spec?
It reports two logical devices with associated resources on the
platform.
[
{"di": "07b80660-3521-466f-a67d-d649e5b60a46",
"links": [{"href": "/oic/p", "rt": "oic.wk.p", "if?:
"oic.if.baseline", "p": {_ "bm": 5}
},
{"href": "/oic/d", "rt": "oic.d.light", "if": "oic.if.r
oic.if.baseline", "p": {_ "bm": 5}
},
{"href": "/led/1", "rt": "oic.r.led", "if": "oic.if.r
oic.if.baseline", "p": {_ "bm": 7}
}
]
},
{"di": "07b80660-3521-466f-a67d-d649e5b60a47",
"links": [{"href": "/light/siwtch", "rt": "oic.d.switch", "if":
"oic.if.r oic.if.baseline", "p": {_ "bm": 5}
},
{"href": "/switch/1", "rt": "oic.r.switch", "if": "oic.if.rw
oic.if.baseline", "p": {_ "bm": 5}
}
]
}
]
3) I have sent the following payload to an IoTivity client as an
/oic/res response, but it only recognizes the 3 resources from the
primary device during discovery.
I however expected it to also include /light/switch and /switch/1
from the secondary device in its discovery result.
Is this a bug in IoTivity?
Thanks,
-Kishen.
-
Kishen Maloor
Intel Open Source Technology Center