2703
Views
5
Helpful
0
Comments

Options
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
08-14-2018 01:28 AM - edited 08-21-2018 11:42 PM
Prerequisites:
- A RS485 Modbus RTU sensor (TMP36 and ADAM 4017+ as an example)
- A Modbus TCP simulator (ModbusPal as an example)
- EFM 1.5 installed in IR829 IOx at Edge location
- EFM 1.5 installed in a UCS or VM at Fog site or Data Center
- PC
Environment:
- The RS458 Modbus RTU sensor connects to the “S0” serial interface of IR829.
- The “Async0” serial interface is configured to support RS485 in IR829 IOS. And the “async0” is configured for serial access of EFM 1.5 app on IR829 IOx.
- All the communication between the Modbus TCP simulator hosted on PC, IR829, UCS/VM, and PC are available through networks.
- The EFM broke on IR829 IOx is set as upstream of the EFM broker on UCS/VM.
Steps:
1) Install Modbus DSLink:
- Sign in EFM-Admin (https://x.x.x.x:8443/efm-admin), select the EFM Broker on IR829 IOx, install the DSLink of Modbus, and “Start Link” of Modbus DSLink. The dslink-java-modbus zip file could be downloaded from https://dsa.s3.amazonaws.com/links/files/dslink-java-modbus.zip.
2) Connect the Modbus RTU sensor:
- Go to the Modbus DSLink, and click “add serial connection” with “transport type” as “RTU” and “comm port id” as “/dev/ttyS1”. Input the relate values and “Invoke”.
- Select the created serial connection, and click “add serial device”. You may use “slave_id” as 1 if your Modbus RTU sensor’s slave ID is 1.
- Select the created serial device, and click “add point”. You may use type as “HOLDING”, “offset” as 0, and data type as “UINT16” if your Modbus RTU sensor’s data is located in the first Holding Register (40001).
- The value will be refreshed periodically.
3) Connect the Modbus TCP simulator:
- Go to the Modbus DSLink, and click “add ip connection” with “transport type” as “TCP” and “host” as “YOUR_SIMULATOR_IP_ADDRESS”. Input the relate values and “Invoke”.
- Select the created ip connection, and click “add ip device”. You may use “slave_id” as 1 if your Modbus TCP simulator’s slave ID is 1.
- Select the created ip device, and click “add point”. You may use type as “HOLDING”, “offset” as 0, and data type as “UINT16” if your Modbus TCP simulator’s data is located in the first Holding Register (40001).
- The value will be refreshed periodically.
4) Design the Dataflow:
- Go to EFM Dataflow Editor (https://x.x.x.x:8443/dataflow.html)
- Go to “downstream” -> “dataflow”, and “Create Dataflow”
- Go to “upstream” -> “IR829EFM” -> “downstream” -> “Modbus” -> “RTU_ttyS1” -> “serialSensorTemp”, and you will find the value of “sensorModbusRTU”. (Please note that the values may depend on the real values of your inputs for environment.)
- Drag the value of “sensorModbusRTU” and drop it in the created dataflow. And drag and drop the related blocks to do data processing
- You may archive all the data in a table in ParStream. To use ParStearm, you need to create a table in ParStream first, “Add Database” with the default port number of 9042 for the EFM ParStream, go to the Table, select the specific table name your created, right click, and drop and drag the “Insert Row” in the dataflow.
- And you may receive, process data and archive it in the ParStream for Modbus TCP simulator as well.
5) Design the Dashboard:
- Go to EFM Dashboard (https://x.x.x.x:8443/)
- Select a Widget, go to “Data” tab, select the value, and drag and drop it to “Value” in Symbol of the Widget. You may set the related value and modify the Label accordingly.
- You may also select a Chart to display the data in a chart.
- Go to “Preview”, and “Open Preview Link” to see the Dashboard.
- As an example, here it uses the data from RTU_ttyS1 as Temperature and TCP_ModbusSim as Humidity.
FAQ and Troubleshooting:
-
How to configure the Serial Interface for IR829?
- Connect to the first serial port (S0) of IR829. Only the first serial port supports RS485. You need to connect TX/RX+ (pin1), TX/RX-(pin2) and GND(pin4) for RS485.
- Configure the Async0 serial interface in IR829 IOS. Please refer to https://community.cisco.com/t5/cisco-iox-documents/accessing-serial-interface-on-ir829-through-gos/ta-p/3657013 for details.
- It is also possible to use RS232 serial interfaces for IR829. Please note that the Asyns0 is RS232 DCE and Async1 is RS232 DTE.
-
How to simulate Modbus TCP with ModbusPal?
- Use “sudo java -jar ModbusPal.jar” to start ModbusPal.
- Click “Run” it for “TCP/IP”
- Click “Add” to add Modbus Slaves. For example, “slave1” for slave as 1.
- Click the icon of “Show or hide the editor of this slave” for created slave, click “Add” to add the Holding Registers from 1 to 1. You may click “Bind” to Automations you created. The automations could be created in “Automation” which allow to generate linear, random and sine data.
-
How to check the data in ParStream DB?
- Go to “ParStream-Import” dslink, select the DB, right click it with “Query”, and you may input the related SQL scripts to check the data from tables in the ParStream.
-
How to integrate EFM with the third-party systems for data lake, data analytics, and data visualization?
- ParStream is available for the third-party systems through the JDBC and ODBC interfaces.
- It is possible to distribute the data through the DSLink to the third-party systems.