MES 3.0

MQTT Overview

MQTT (Message Queue Telemetry Transport) is a machine-to-machine data transfer protocol. It is the most popular messaging protocol for Internet of Things (IoT) and Industrial Internet of Things (IIoT). MQTT allows to securely connect, publish, and subscribe to data. 



MQTT Modules Download

MQTT modules by Cirrus Link Solutions are designed specifically for the integration of MQTT data and building IIoT/SCADA/MES solutions. See Cirrus Link Documentation for more details.

  • MQTT is used with IoT and IIoT to publish and subscribe data.
  • Especially effective in high latency situation.
  • Sepasoft module tag collectors work with MQTT supporting integration of IoT/IIoT and MES.


The following example scenario explains installation and configuration of the Cirrus Link MQTT modules onto typical Ignition Edge Gateway and a Central Ignition Gateway that will use tags to communicate data for recording and storage (it assumes both gateways have already been installed and configured). The Edge Gateway is the source of incoming factory data via tags and the Central Ignition Gateway receives and records the tag values.

Once the installation and configuration completed, customize the tags and configuration as needed for your specific factory environment.

This example uses Ignition version 8.0.16, MQTT Modules version 4.0.5, and Sepasoft MES Modules 3.80.0.


Download MQTT Distributor, Engine and Transmission Modules

  1. On the Inductive Automation website, navigate to the Strategic Partner Modules tab (shows all available third-party modules).

  2. Use the two pull-downs for the desired Ignition version. Choose the same version as the central Ignition Gateway and the Edge Gateway you already have installed. 

  3. Download the MQTT Distributor, MQTT Engine and MQTT Transmission modules. 




MQTT Installation - Central Gateway

  1. On the central Ignition Gateway console browser page (e.g. http://localhost:8088-), navigate to Configure → Modules (in the SYSTEM section).

  2. At the bottom of the page, click Install or Upgrade a Module and select the MQTT Distributor Module file from your Downloads folder. Follow the instructions and agreements on the page to complete the installation.

  3. Repeat the step above to install the MQTT Engine Module.



MQTT Configuration - Central Gateway 

Configure MQTT Engine Module

By default, the MQTT Engine Module is configured to point to an MQTT Server at tcp://localhost:1883, which means that it will automatically connect to the MQTT Distributor Module you installed with it.

  1. In the Configure tab, scroll down to the MQTT Engine section and click Settings. Configure the following:

    1. In the General tab, change the Primary Host ID to a name string of your choice.

    2. In the Miscellaneous section, disable Store Historical Events (clear the check box).

    3. Click Save Changes.





Configure Chariot SCADA

  1. While still in Settings, select the Servers tab to edit the default Chariot Scada, as follows:

    1. In the Name field, leave the default name string as "Chariot SCADA".
      Note: This username will need to be set for all modules.

    2. Verify that the Enable this MQTT Server Setting checkbox is checked (enabled).

    3. Check the Check this box to change the existing password box and enter the Chariot SCADA's password in the two Password fields.
      Note: The same password will need to be set for all modules.

    4. Click Save Changes




Configure MQTT Distributor Module

  1. In the Configure tab, scroll down to the MQTT Distributor section and click Settings (for this example scenario, the Non-TLS Connection is being used). Configure the following:

    1. Verify that the Enable the MQTT Server checkbox is checked (enabled).

    2. Verify that the Enable Websockets connections for the MQTT Server checkbox is checked (enabled).

    3. No change to the default port addresses were required for this example.

    4. Click Save Changes.

 




Configure Admin and Password

  1. Select the Users tab and change the Username field to the admin user you configured in the MQTT Engine Module.

  2. Check the Check this box to change the existing password box and type the password you selected in the MQTT Engine Module into both Password fields. 




MQTT Installation - Edge Gateway

Install MQTT Transmission Module

  1. On the Ignition Edge Gateway server, open the gateway's console page and navigate to Configure → Modules (in the SYSTEM section).

  2. At the bottom of the page, click Install or Upgrade a Module and select the MQTT Transmission Module file from your Downloads folder. Follow the instructions and agreements on the page to complete the installation.


MQTT Configuration - Edge Gateway

Configure MQTT Transmission History

  1. In the Configure tab, scroll down to the MQTT Transmission section and click History. Configure the following:

    1. In the History Stores tab, edit the Name field to be "Default In-Memory Store".

    2. Verify that the Enable this History Store checkbox is checked (enabled).

    3. Change Type to In-Memory.

    4. Click Save Changes.





Configure MQTT Transmission Module - General and Server Tabs

  1. In the Configure tab → MQTT Transmission section, click Settings. Configure the following:

    1. In the General tab, set the checkbox for MQTT Transmission from connecting to the configured MQTT Servers (enabled).

    2. In the Name field, leave the default name string as "Chariot SCADA".
      Note: This username will need to be set for all modules.

    3. Enter the same Chariot SCADA connection password in the Password fields.
      Note: The same password will need to be set for all modules.

    4. Modify the URL field to point to the Ignition Distributor gateway. Example: If the Gateway IP is 10.1.10.97 then set the URL field to tcp://10.1.10.97:1883.

    5. Verify that the Server Set is set to Default

    6. Click Save Changes.




Configure MQTT Transmission Module - Sets Tab

  1. In the Sets tab, edit the Primary Host ID to be the same name string as entered for the MQTT Engine Module in the Central Ignition Gateway.

  2. Click Save Changes.




Configure MQTT Transmission Module - Tag Settings

  1. In the Transmitters tab → Tag Settings section:

    1. Verify that the Enable Transmitter check box is set (enabled).

    2. Set the Tag Provider field to "Edge" (Edge tags).

    3. Set the Tag Path field to "MQTT Tags".

    4. Verify that the Set field is set to Default.

    5. Verify that the Converts UDTs checkbox is set (enabled). 




Configure MQTT Transmission Module - History Settings

  1. In the same Transmitters tab, scroll further down to the History Settings section:

    1. Change the History Store field to the Default In-Memory Store selection.

    2. Verify that the Enabled History Storage by Default checkbox is set (enabled).

    3. Set the checkbox for In-Order History (enabled).




Configure MQTT Transmission Module - Sparkplug Settings

  1. In the same Transmitters tab, scroll further down to the Sparkplug Settings section:

    1. Choose a name string for the Edge Node ID field.

    2. Choose a Device ID.

  2. Click Save Changes to save all the edits to the MQTT Transmission page.





Launch Edge Designer and Configure Edge Tags

  1. Launch Designer for the Edge Gateway.

  2. In the Tag Browser pane, expand the tags in All Providers → EdgeMQTT TagsPLC 1. You should see a set of default tags similar to the screenshot below:



Test Edge Tags

  1. Change the integer value of the Example Tag several times.

  2. Expand the All Providers → MQTT Transmission → Transmission Control tag folder so you can see the Refresh tag.

  3. Refresh the tags by setting the checkbox in the Refresh tag. Wait for it to go blank (unchecked) again.




Launch Central Ignition Designer and Verify Tags

  1. Launch Designer for your Central Ignition Gateway.

  2. In the Tag Browser pane, expand the tags in All Providers → MQTT EngineEdge Nodes all the way down to the Example Tag in the folder previous named in the Device ID field in the Sparkplug Settings section (in this case, Device101). You should see tag folders and tags similar to the screenshot below. 

  3. You should see that the last value that was set for Example Tag in the Edge Gateway is now reflected here in the Central Ignition Gateway. 

  4. Change the integer value of Example Tag in the Edge Designer and verify that the change propagates over to Example Tag in the Central Ignition Designer.



If Example Tag in the Central Ignition Designer is not changing, verify that the connection is still valid on the Edge Gateway MQTT Transmission Settings:



Test Using Value Editor Component

On the Central Ignition Gateway, you should have the OEE Downtime Module and the Production Module installed (as well as a database configured for the Production and OEE Downtime modules). Once you have verified that these modules are both running:

  1. In Designer for the Central Ignition Gateway, create (or open) a page with an MES Equipment Manager component.

  2. Create a Production Model down to the Line level. Example:




Configure State Tag Collector

  1. Verify that the Production Model is activated (not showing in red).

  2. Click on the Line and in the General section click on Tag Collectors.

  3. Add the tag path for the Example Tag created by MQTT Transmission to the State tag collector.

  4. Click Save.




Configure a Value Editor Window

  1. On a new main window, drag on an MES Object Selector, MES Value Editor, and a Date Range component. Arrange as shown below.

  2. In the MES Object Selector, select to Include MES Line Objects.


  3. Bind the Equipment Path property of the MES Value Editor to the Equipment Item Path property of the MES Object Selector


  4. Bind the Start Date and End Date of the MES Value Editor to the Start Date and End Date on the Date Range component.

  5. On the MES Object Selector, select the line that you set to collect data from the Example Tag (Line 1 in this example).

  6. Set the Tag Collector Type field of the MES Value Editor to Equipment State, and make sure that the Date Range component is set to sufficiently brackets the timespan when you made changes to Example Tag

  7. In the Tag Browser pane of the Edge Gateway Designer, change the integer value of the Example Tag. You should see values added to the MES Value Editor.






  • No labels