Ruuvi Gateway and Azure IoT Hub connection with MQTT

Hi,
has anyone connected Ruuvi Gateway to Azure IoT hub using MQTT? I followed instructions (Understand Azure IoT Hub MQTT support | Microsoft Docs) “Using the MQTT protocol directly (as a device)” but with no data streaming to Azure.

Is it even possible to get connection working or do I just have incorrect parameters?

Hello,

It seems like it should be doable in Gateway firmware version 1.9 which adds MQTTS support. The release is not ready yet, but if you’re comfortable with installing binaries over USB you can try our latest development builds available at Jenkins.

This screenshot is about our internal testing on older version, but it should be possible to configure all the fields required by Azure IoT hub:

Please let us know how it goes if you give it a try

Hi,
I updated the firmware to support MQTT over TLS/SSL but now I have new problem. Have you limited the length of Username and Password on the Gateway’s MQTT configuration?

According to Microsoft documentation the username must be something like “contoso.azure-devices.net/MyDevice01/?api-version=2018-06-30” and the password “SharedAccessSignature sig={signature-string}&se={expiry}&sr={URL-encoded-resourceURI}”. It seems that username is limited to 50 characters. I’m not sure about password because it is not visible when MQTT configuration is done again.

I’m not sure about what the limitation is right now, but it’s likely limited to something shorter than Azure requires. I opened an issue about this so longer fields will make it to the release. @Alexey_Skvortsov FYI

Thanks!

For your information, Azure username can be easily 100 characters and password 200 depending on IoT hub and devices names.