Supported hardware
Machine | Router |
---|---|
MELSEC series iQ-R (R08CPU*), iQ-F, L (LO2CPU-P*), Q * other CPUs in the series may also be supported |
StrideLinx router3, firmware 3.17 and up (upgrade) |
For Live data, Historical data, Datalogging to MQTT broker, and Alarming you'll need to set up a data source and add variables. This article shows you how to do this for communication via Mitsubishi's MELSEC.
- Prepare the machine
- Add a data source
- Add variables
- Test variables
- Live data, Historical data, Alarming
Prepare the machine
The machine needs to be prepared to enable communication.
iQ-F and iQ-R series (GX Works3)
- Open GX Works3 and open your machine project.
- In the Navigation pane, go to Parameter > expand your CPU (FX5UCPU in the example below) > Module parameter.
-
Open the Ethernet Port parameters.
- Expand Basic Settings in the Item List and double click External Device Configuration.
- Expand Setting Item External Device Configuration and open the External Device Configuration window by double clicking <Detailed Setting>.
- Expand Ethernet Device (General) in the Module List.
- Drag and drop SLMP Connection into the grey area. This is the MELSEC module.
- Select protocol TCP and choose a Port No. between 1025-4999 or 5010-65534.
- Save the setting by pressing Close with Reflecting the Setting at the top.
-
Apply the new project setting.
Now all that's left is to write these settings to the machine.
L and Q series (GX Works2)
- Open GX Works2 and open your machine project.
- In the Project Window, open Parameter > PLC Parameter and go to the tab Built-in Ethernet Port Setting.
- If you haven't already, enter an IP address for the CPU Module and a Subnet Mask Pattern (usually 255.255.255.0).
- Check the option Set Open Setting in Ethernet Configuration window and press Ethernet Conf..Enable MELSEC communication in your machine.
- On a new row, select protocol TCP, select open system MC Protocol and choose a Host Station Port Number between 1025-4999 or 5010-65534. UDP is also supported, but TCP is recommended because this protocol is less error-prone.
Add a data source
The machine will need to be added as a MELSEC data source.
- Go to Fleet Manager > Devices and click on your device name.
- In the left menu, at Services, click on the icon and select Data source > MELSEC.
- Enter the requested information (details below) and click on Add.
Field Description Name Enter a name for the data source. Identifier The identifier is entered automatically and ensures that every data source remains unique, even if they share the same name. IP address Enter the IP address of your machine. Port Enter the Port No. that you configured in your machine.
In GX Works 2 this is called Host Station Port Number.MELSEC Serie The Mitsubishi MELSEC series to which your machine belongs.
If you're unsure, please consult the Mitsubishi website. "QnUCPU" is Mitsubishi's notation for every MELSEC-Q Series machine with CPU type Q..U..CPU, for example Q04UDVCPU or Q26UDEHCPU.Transport protocol Select the same protocol that you configured in your machine (TCP/UDP). Network No. and PC No. If configured in the machine, enter the correct settings here. If not, leave the default settings.
Applicable when using a custom MELSEC machine network.Request destination module I/O No. and Request destination module station No. If configured in the machine, enter the correct settings here. If not, leave the default settings.
Applicable when using a specific I/O module for communication.Authentication type The Ethernet connection in the machine may be password protected. Enter the password or leave it empty if no password is configured on the machine. Polling sleep time The StrideLinx router will continuously request data from the machine. This then enables you to log aggregated values, like the average value or the maximum value that occurred, and to trigger alarms when certain conditions are met.
The polling sleep time is the time that the StrideLinx router waits before asking data again, after it just received data from the machine.
A polling sleep time of 100ms is recommended. In the rare case that you are experiencing a high CPU load on the machine, you can increase this setting to reduce the load.
Add variables
Once you've added a data source, you can start adding variables.
- Under your Data source, go to Variables and click onAdd variable.
- Enter the requested information (details below) and click on Add.
Field Description Name Enter a name for the variable. Identifier The identifier is entered automatically and ensures that every variable remains unique, even if they share the same name. Type Select the variable's data type (bool, int, float, etc). Device type Select the variable's device type (register type). Device No. Enter the variable's address. The address notation (decimal or hexadecimal) depends on the selected device type.
Device type Device No. notation SM - Special relay Decimal SD - Special register Decimal X - Input Hexadecimal Y - Output Hexadecimal M - Internal relay Decimal L - Latch relay Decimal F - Annunciator Decimal V - Edge relay Decimal B - Link relay Hexadecimal D - Data register Decimal W - Link register Hexadecimal TS - Timer (Contact) Decimal TC - Time (Coil) Decimal TN - Timer (Current Value) Decimal TS - Retentive timer (Contact) Decimal TC - Retentive timer (Coil) Decimal SN - Retentivetimer (Current Value) Decimal CS - Counter (Contact) Decimal CC - Counter (Coil) Decimal CN - Counter (Current Value) Decimal SB - Link special relay Hexadecimal SW - Link special register Hexadecimal DX - Direct access input Hexadecimal DY - Direct access output Hexadecimal Z - Index register Decimal R - Block switching method Decimal ZR - Serial number access method Hexadecimal Factor Multiplies the value. Leave empty if the data type is boolean.
This factor is automatically applied to all data visualization in StrideLinx Cloud components, both Live and Historical, and when exporting that data to a CSV file. Entering a factor in a data component overrules this factor.
This factor does not apply to log triggers, alarms and datalogging to MQTT broker.Unit Displayed behind the value (e.g. kg). - Repeat step 5 for every variable you want to add or click Import from CSV-file near the top right corner to add variables in bulk instead.
- The structure of the CSV file is explained here: Import variables: CSV file structure.
- Using Export to CSV-file and Import from CSV-file enables you to easily copy variables from one device to another device. Alternatively, you can also use device templates.
You have now made the changes in the StrideLinx Cloud, but these are not yet active in your device. You will need to push your changes to your device for them to take effect.
Temporary disconnect
After this next step, the config push, the device may temporarily disconnect and LAN communication may be temporarily interrupted while it's applying the new settings. This only takes a moment.- Click on Push config to device in the top right corner.
Test variables
The variables test is recommended to check if all added variables are configured correctly. It shows the value of all variables if everything is configured correctly and shows an error if something is not configured correctly.
- Click on Run test near the top right corner.
- The test will attempt to update values every 0.5 seconds.
- Is the test showing unexpected values? Check the addresses and data types of the variables.
- Is the test showing a timeout error? Check that the data source is configured correctly and the machine is connected and powered on. If you are still getting a timeout error, contact your IT to make sure the test is not blocked. The test sets up an outgoing connection from your computer to the StrideLinx router using:
Port Transport protocol Application protocol 443 TCP WebSocket
Live data, Historical data, Alarming
Now that the data source and variables have been set up, you can continue below.
- Click below to continue in the feature specific articles.