-
I am currently exploring ways of implementing Upload File to Blob features to an already existing application using this SDK on an IoT device. My application uses MQTT protocol and has Plug and Play support which as I understand is exclusive to only MQTT and MQTT-WS protocols while Upload File to Blob feature is supported only by HTTPS. I am looking at the possibility of uploading files to Azure as well using Device Update for IoT Hub which I'm guessing would need to use some form of file download to my device. Now my idea to use features that are available both to MQTT and HTTPS protocols would be to use two
In the above example I would use Would this approach make any sense or is there be a better alternative or perhaps none at all? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Sorry for the late response. You can not have two simultaneous connections to the hub service at the same time with the same device ID, so that will not work. There should be no need to add the HTTP_Protocol as file upload should work with the MQTT_Protocol. Although our sample shows using HTTP_Protocol that should not be the requirement as MQTT hub connection should also work. |
Beta Was this translation helpful? Give feedback.
-
I updated the sample to demonstrate usage of MQTT and upload to blob. |
Beta Was this translation helpful? Give feedback.
Sorry for the late response. You can not have two simultaneous connections to the hub service at the same time with the same device ID, so that will not work.
There should be no need to add the HTTP_Protocol as file upload should work with the MQTT_Protocol. Although our sample shows using HTTP_Protocol that should not be the requirement as MQTT hub connection should also work.