There is a C++ sample for presence (presenceserver.cpp/presenceclient.cpp) under ~/iotivity/example. This example shows unicast and multicast address with query. Thanks, =Sam
From: iotivity-dev-bounces at lists.iotivity.org [mailto:iotivity-dev-boun...@lists.iotivity.org] On Behalf Of Light, John J Sent: Monday, April 20, 2015 7:41 AM To: jihun.ha at samsung.com Cc: iotivity-dev at lists.iotivity.org Subject: Re: [dev] On subscribePresence() function with a relative URI Jihun, The presence code in master is fragile, as you have discovered. It currently requires you to call subscribePresence with the a full uri, including ?coap:?, IP address and port (unless multicast), and the requirements are not spelled out. I have fixed the problem in the IPv6 code (coming). Others will have to answer whether the issue will be fixed sooner than that. John Light Intel OTC OIC development From: iotivity-dev-bounces at lists.iotivity.org<mailto:iotivity-dev-bounces at lists.iotivity.org> [mailto:iotivity-dev-boun...@lists.iotivity.org] On Behalf Of ??? Sent: Sunday, April 19, 2015 7:32 PM Cc: iotivity-dev at lists.iotivity.org<mailto:iotivity-dev at lists.iotivity.org> Subject: [dev] On subscribePresence() function with a relative URI Hi. All, I'm wondering a usage of subscribePresence() function if a host address is a relative one like "/a/light" not "coap://192.168.0.x:yyyy/a/light" (Please refer to a roomserver application) When I did so, there is no reaction for the request; No request packet toward a desired resource server. Is it an expected behavior as intended? Should we use subscribePresence() with an "coap://", IP, port, plus URI?? Any comment will be happy to me. ?????. ??? ??. Best Regards, Jihun Ha (???/???, Ph.D.) IoT, IoTivity, OIC | IoT Solution Lab Software R&D Center | Samsung Electronics Co., Ltd Mobile +82 10 2533 7947 jihun.ha at samsung.com | jhha85 at gmail.com [cid:image001.gif at 01D07B3C.B8FE6B80] [Image removed by sender.] -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.iotivity.org/pipermail/iotivity-dev/attachments/20150420/ee185c61/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.gif Type: image/gif Size: 13168 bytes Desc: image001.gif URL: <http://lists.iotivity.org/pipermail/iotivity-dev/attachments/20150420/ee185c61/attachment.gif> -------------- next part -------------- A non-text attachment was scrubbed... Name: image002.jpg Type: image/jpeg Size: 823 bytes Desc: image002.jpg URL: <http://lists.iotivity.org/pipermail/iotivity-dev/attachments/20150420/ee185c61/attachment.jpg>