Export Modbus Poll tags to Kepware
Kepware can create hundreds of static tags from a CSV file. Export to SCADA writes that file from the blocks you poll in Modbus Poll, so the address and data type of each tag come from a register you have already seen working.
Availability. Export to SCADA was added to the Modbus Poll and BACnet Explorer source after Modbus Poll 1.3.5 and BACnet Explorer 1.2.1 were prepared. It is in the open source repository on GitHub and ships with the next app update; if you do not see the button in the app yet, you are on a build from before that update. It needs Pro.
1. Export from Modbus Poll
- Add the read blocks you want and connect once to check the values.
- Click Export to SCADA in the blocks panel (Pro) and choose Kepware tags (CSV).
- Read the yellow notes. They list the device settings to change in Kepware for your word order, and the unit ID and port to set on the device.
- Click Save file.
2. Prepare the device in Kepware
Create a channel with the Modbus TCP/IP Ethernet driver and add a device. Set its IP address, port and Unit ID (Kepware takes these from the device, not from the tag file). The export uses addresses that start at 1, which is the default. Do not turn on Zero-Based Addressing.
3. Import the CSV
Select the device (or a tag group inside it) in the project tree, then choose File, Import CSV. The command is only available while a device or tag group is selected.
What the file contains
Tag Name,Address,Data Type,Respect Data Type,Client Access,Scan Rate,Scaling,...
Voltage_3000,403001,Float,1,R/W,1000,None,...
Counter_10,400011,Word,1,R/W,1000,None,...
Energy_100,300101,Long,1,RO,1000,None,...
Run_state_0,000001,Boolean,1,R/W,1000,None,...
Addresses always have six digits: 0 coils, 1 discrete inputs (input coils), 3 input registers, 4 holding registers. The number after it is the Modbus Poll address plus one.
| Modbus Poll type | Kepware data type |
|---|---|
| uint16 | Word |
| int16 | Short |
| int32 | Long |
| float32 | Float |
| float64 | Double |
| coil, discrete | Boolean |
Word order
Kepware reads 32-bit and 64-bit values with the low word first by default. Most devices, and the default in Modbus Poll (AB CD), send the high word first. When that is your case, open the device properties and switch off First Word Low in 32-Bit Data Types, and First DWord Low in 64-Bit Data Types for doubles. If your device swaps the bytes inside each register, switch off Modbus Byte Order as well. The export lists the right combination for the order you had selected.
BACnet Explorer
BACnet Explorer writes the same kind of CSV for the Kepware BACnet/IP driver, with addresses in the form AnalogValue.100.PresentValue. Kepware takes the device instance, IP address and port from the device, so set those on the BACnet/IP device before you import. The export notes list the values to use.
Export your Modbus Poll tags to a SCADA
Read the registers you care about in Modbus Poll, then use Export to SCADA in the blocks panel (Pro) to write the tag list for Ignition, Kepware, Node-RED, RustRED, Home Assistant or Voltrus SCADA.
Get Modbus Poll