Hi Kevin,

To set various properties of the /oic/d and /oic/p resources you can use the 
following API:

C:
OCStackResult OCSetPropertyValue(OCPayloadType type, const char *propName, 
const void *value)
defined in ocstack.h

C++: 
OCStackResult OC::OCPlatform::setPropertyValue(OCPayloadType type, const 
std::string& tag, const std::string& value)
defined in OCPlatform.h

The OCPayloadType enum is defined in octypes.h.

E.g. To set the platform ID in C++ call:
OC::OCPlatform::setPropertyValue(PAYLOAD_TYPE_PLATFORM, OC_RSRVD_PLATFORM_ID, " 
12345678-abcd-1234-abcd-abcdefghijkl")

Regards,

Martin Rösch


Von: iotivity-dev@lists.iotivity.org [mailto:iotivity-dev@lists.iotivity.org] 
Im Auftrag von Joo-Chul Lee
Gesendet: Dienstag, 4. September 2018 03:21
An: iotivity-dev
Betreff: [dev] how to share "same platform ID" among iotivity stack instances?


Hi all, 
 
I have had one question since I began to study OCF (OIC?) spec…
That is how to share “same platform ID” among logical OCF devices in IoTivity 
codes.
 
Is this just an implementation skill (dependent on programmer) ? or is there 
any typical way used in codes ?
At least I have not found any sample codes in IoTivity stack…
 
Thanks & BR,
 
- Kevin 

-- 
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Joo-Chul Kevin Lee, ETRI
161 Gajeong-dong, Yuseong-gu, daejon, 305-700, KOREA
E-mail: r...@etri.re.kr/cms.r...@gmail.com Tel: +82-42-860-1021
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#9916): 
https://lists.iotivity.org/g/iotivity-dev/message/9916
Mute This Topic: https://lists.iotivity.org/mt/25172934/21656
Group Owner: iotivity-dev+ow...@lists.iotivity.org
Unsubscribe: https://lists.iotivity.org/g/iotivity-dev/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to