MQTT_ReadTopicReal (FUN)ΒΆ

FUNCTION MQTT_ReadTopicReal : WORD

This function subscribes to the specified MQTT topic and returns published messages as real numbers.

The output valid is set to TRUE when a publication occurs on the topic and the message payload is stored into value.

InOut:

Scope

Name

Type

Comment

Return

MQTT_ReadTopicReal

WORD

Status code returned by the runtime (0 means "no errors").

Inout

id

WORD

Operation identifier used by the runtime.

Input

topic

STRING(127)

MQTT topic name.

qos

WORD

Quality of Service level.

Output

value

REAL

Real value published on the topic.

valid

BOOL

TRUE when a valid value has been received.