Guidance on how to connect 3rd party PLC to IoT Hub

Zach Pertee 0 Reputation points
2025-09-19T18:11:01.9166667+00:00

We need some assistance connecting our PLC to IoT Hub via MQTTS. We have two vendors struggling with the same issue. It seems like we can authenticate but not actually send telemetry to the cloud.

Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
{count} votes

1 answer

Sort by: Most helpful
  1. Manas Mohanty 11,850 Reputation points Microsoft External Staff Moderator
    2025-09-23T02:40:42.15+00:00

    Hello Zach Pertee

    Here’s how you can connect a 3rd party PLC (Programmable Logic Controller) to Azure IoT Hub, with references to public documentation and resources:

    1. Use an Industrial Gateway or IoT Edge Device

    Most 3rd party PLCs do not natively support direct connection to Azure IoT Hub. You typically need an industrial gateway or an IoT Edge device that can:

    • Communicate with the PLC using industrial protocols (e.g., Modbus, OPC UA, S7, etc.)
    • Translate PLC data to a protocol supported by IoT Hub (MQTT, AMQP, HTTPS)
    • Securely forward data to Azure IoT Hub

    Reference:


    2. Register the Gateway/Device in IoT Hub

    • Create a device identity for your gateway or edge device in the IoT Hub device registry.
    • Use the generated credentials (symmetric key, X.509 certificate, or TPM) to authenticate the device.

    Reference:


    3. Configure Data Flow

    • Set up the gateway or IoT Edge device to poll or subscribe to data from the PLC.
    • Configure the gateway to send telemetry data to IoT Hub.
    • For OPC UA-based PLCs, you can use the Azure IoT Edge OPC Publisher module.

    5. Security and Management

    • Use IoT Edge for secure, managed connectivity and module deployment.
    • Leverage Azure IoT Central or IoT Hub for device management, monitoring, and command/control.

    Hope it helps.

    Please share your methodology and error trace for further assistance.

    Thank you.


    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.