Microsoft Azure IoTHub client libraries

Dependents:   sht15_remote_monitoring RobotArmDemo iothub_client_sample_amqp f767zi_mqtt ... more

This library implements the Microsoft Azure IoTHub client library. The code is replicated from https://github.com/Azure/azure-iot-sdks

Revision:
42:448eecc3676e
Parent:
40:1a94db9139ea
Child:
43:038d8511e817
--- a/iothub_client.h	Mon May 23 07:35:31 2016 -0700
+++ b/iothub_client.h	Tue Jun 07 10:49:08 2016 -0700
@@ -25,6 +25,12 @@
 {
 #endif
 
+#define IOTHUB_CLIENT_FILE_UPLOAD_RESULT_VALUES \
+    FILE_UPLOAD_OK ,\
+    FILE_UPLOAD_ERROR
+
+    DEFINE_ENUM(IOTHUB_CLIENT_FILE_UPLOAD_RESULT, IOTHUB_CLIENT_FILE_UPLOAD_RESULT_VALUES)
+        typedef void(*IOTHUB_CLIENT_FILE_UPLOAD_CALLBACK)(IOTHUB_CLIENT_FILE_UPLOAD_RESULT result, void* userContextCallback);
 
 	/**
 	* @brief	Creates a IoT Hub client for communication with an existing
@@ -183,11 +189,24 @@
 	*				  name. @p value is pointer to a long.
 	*				- @b messageTimeout - the maximum time in milliseconds until a message
 	*                 is timeouted. The time starts at IoTHubClient_SendEventAsync. By default,
-	*                 messages do not expire.
+	*                 messages do not expire. @p is a pointer to a uint64_t
 	* @return	IOTHUB_CLIENT_OK upon success or an error code upon failure.
 	*/
 	extern IOTHUB_CLIENT_RESULT IoTHubClient_SetOption(IOTHUB_CLIENT_HANDLE iotHubClientHandle, const char* optionName, const void* value);
-
+    
+    /**
+    * @brief	IoTHubClient_UploadToBlobAsync uploads data from memory to a file in Azure Blob Storage.
+    *
+    * @param	iotHubClientHandle	                The handle created by a call to the IoTHubClient_Create function.
+    * @param	destinationFileName	                The name of the file to be created in Azure Blob Storage.
+    * @param	source                              The source of data.
+    * @param	size                                The size of data.
+    * @param    iotHubClientFileUploadCallback      A callback to be invoked when the file upload operation has finished.
+    * @param    context                             A user-provided context to be passed to the file upload callback.
+    *
+    * @return	IOTHUB_CLIENT_OK upon success or an error code upon failure.
+    */
+    extern IOTHUB_CLIENT_RESULT IoTHubClient_UploadToBlobAsync(IOTHUB_CLIENT_HANDLE iotHubClientHandle, const char* destinationFileName, const unsigned char* source, size_t size, IOTHUB_CLIENT_FILE_UPLOAD_CALLBACK iotHubClientFileUploadCallback, void* context);
 #ifdef __cplusplus
 }
 #endif