Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Scroll Documents: Update page title prefix

...

Table of Contents

...

Overview

As with all adapters, an existing https://unit040.atlassian.net/wiki/spaces/PUD/pages/280987237/Logic+Simulator#Overview is required.

...

Where to find the different Gateway Adapters.

...

Where to find

To find the MQTT adapter, go to the Inspector window of a https://unit040.atlassian.net/wiki/spaces/PUD/pages/280987237/Logic+Simulator#Overview component.
This https://unit040.atlassian.net/wiki/spaces/PUD/pages/280987237/Logic+Simulator#Overview can be added under Logic.

...

Feature overview

...

Info

Only the settings between the lines refer to the MQTT Adapter.

...

QoS

known as

speed

reliability

remarks

0

fire & forget

fast

poor

Messages can get lost in unstable connections. Very suitable for wires local connection

1

single handshake

slower

good

No message is lost. Can lead to duplicate messages. but is much faster than QoS 2

2

double handshake

slowest

exact

If getting the message exactly once is more important than performance. Quite an overhead compared to the other 2 levels

...

How to use

Please see the https://unit040.atlassian.net/wiki/spaces/PUD/pages/280987237/Logic+Simulator#Overview documentation for further instructions on setting up your simulation.

...

Prerequisites for MQTT

MQTT can work with an online broker, but is more commonly used with a local broker. There are a lot of brokers available. An overview can be found at: https://en.wikipedia.org/wiki/Comparison_of_MQTT_implementations

...

For testing purposes we recommend using a client like i.e. MQTT.fx https://mqttfx.jensd.de/

...

Used Protocol

To communicate with the MQTT adapter in Prespective you need to apply the following protocol:

...

  • Topic to write is the address defined by the PLC address in the signal naming

  • Value is the value that is within the range of the specified type

...

Supported Types

  • BOOL

  • BYTE

  • SBYTE

  • WORD

  • DWORD

  • SHORT

  • USHORT

  • INT16

  • UINT16

  • INT32

  • UINT32

  • INT64

  • UINT64

  • REAL32

  • REAL64

  • BYTEARRAY

  • STRING

  • STRUCT

...

Naming Rules

...

Setting up the component works as like any other prelogic component. The thing you have to take into account is how the PLC Address Path Format (or implicit naming rule) is configured. The output of this Address is the topic to which the component is reading and/or writing.

...