I am trying to use Direct Method to invoke device OTA The device I am using is Quectel EC21 and subscribe to the topic "$iothub/methods/POST/#" When I Invoke the method in Azure IoT explorer,I always get the time out fail message that "message":"Timed out waiting for device to connect." enter image description here
This error message confused me since I expect my device receive the method payload through MQTT from topic "$iothub/methods/POST/#" but I received nothing. But at he same time, I can receive normal cloud to device MQTT message through topic "devices/deviceID/messages/devicebound/#" So, is the Direct method connection and Iot hub connection are different connection?
After searching online and hint from Matthijs. To make the direct method work, I found need to add api version in username field as below For the Username field, use {iothubhostname}/{device_id}/?api-version=2018-06-30