MQTT_CommandSubscriber (FB)ΒΆ

FUNCTION_BLOCK MQTT_CommandSubscriber

Function Block to receive Command over the Google Cloud Iot Core MQTT Bridge

InOut:

Scope

Name

Type

Comment

Inout

MQTTBridge

MQTT_Bridge

Instance of the MQTT Bridge

Input

xEnable

BOOL

Subscribes a command

pbCommandPayload

POINTER TO BYTE

Pointer to Command Payload

uiMaxCommandPayloadSize

UDINT

Maximal size of Command Payload

eQoS

MQTT.MQTT_QOS

Quality of Service of the Command Subscriber

Output

eError

Error

Output Error

eMQTTError

MQTT.MQTT_ERROR

Error from MQTT

xSubscribeActive

BOOL

Subcriber is active and lisenig

xReceived

BOOL

Received a message

xBusy

BOOL

xDone

BOOL

xError

BOOL