* @param[in] sep network endpoint description.
* @param[in] data Data received from remote OIC device.
* @param[in] dataLength Length of data in bytes.
+ * @return ::CA_STATUS_OK or ERROR CODES (::CAResult_t error codes in cacommon.h).
* @pre Callback must be registered using CAIPSetPacketReceiveCallback().
*/
-typedef void (*CAIPPacketReceivedCallback)(const CASecureEndpoint_t *sep,
- const void *data,
- uint32_t dataLength);
+typedef CAResult_t (*CAIPPacketReceivedCallback)(const CASecureEndpoint_t *sep,
+ const void *data,
+ uint32_t dataLength);
/**
* Callback to notify error in the IP adapter.
int CAGetPollingInterval(int interval);
/**
- * Tell the IP server an interface has been added.
- */
-void CAWakeUpForChange();
-
-/**
* Set callback for error handling.
*
* @param[in] errorHandleCallback callback to notify error to the ipadapter.
*/
void CAIPSetErrorHandler(CAIPErrorHandleCallback errorHandleCallback);
+/**
+ * Set udp multicast time to live value to control the scope of the multicasts.
+ * @param[in] ttl To be set to any value from 0 to 255.
+ *
+ * @return ::CA_STATUS_OK or ERROR CODES (::CAResult_t error codes in cacommon.h).
+ */
+CAResult_t CAIPSetMulticastTTL(size_t ttl);
+
+/**
+ * Get udp multicast time to live value.
+ * @param[out] ttl TTL pointer to get the stored multicast time to live.
+ *
+ * @return ::CA_STATUS_OK or ERROR CODES (::CAResult_t error codes in cacommon.h).
+ */
+CAResult_t CAIPGetMulticastTTL(size_t *ttl);
+
+/**
+ * Create multicast socket to receive multicast message from remote device.
+ */
+void CreateMulticastSocket();
+
+/**
+ * Close multicast socket to stop receiving multicast message.
+ */
+void CloseMulticastSocket();
#ifdef __cplusplus
}
#endif