IotMqttv5ReqResSample

Sample for the use of MQTTv5 Request/Response

In this sample, the communication to an MQTT broker using MQTTv5 is shown. In particular, the Request/Response mechanism of MQTTv5 is demonstrated. As a prerequisite, the message broker used must support MQTTv5. The basic flow of the sample is as follows:

The following figure once again illustrates the basic flow of communication. More information about individual lines of code can be found directly in the comments of the corresponding sample download.

IotMqttv5ReqResSample 1:

Requirements

Development environment

Target platform

PLC libraries to include

TwinCAT v3.1.4026.0

IPC or CX (x86, x64, ARM)

Tc3_IotBase (>= v3.4.2.0),
Tc2_Utilities (>= v3.4.4.0)