TechTip: Using Modbus driver in Infilink

New in Inflink V5.00.45 is a built-in Modbus driver, making Infilink a smart choice for SCADA, enabling many projects to be delivered without the need for expensive OPC servers. This TechTip is a run through to get you started.

We’re using a Koyo DirectLogic 06 PLC fitted with an H0-ECOM100 Ethernet module as our Modbus device.

Launch the Modbus driver:

Add a Channel…

Give the channel a name – we’ll stick with the default – “TCP_Channel_1”, click “Next”.

Set the IP address of your device, in our example, the IP address of our H0-ECOM100 in the 06 PLC is… click “Next”.

We’ll use the default values here… and Click “Finish”.

The channel should now appear as below.

Next, we’ll add a device to our channel…

We’ll stick with the default name, “TCP_Device_1”, but you can choose something more memorable for your application. Click “Next”.

Device ID in our example we’ll stick with “1”, however, you may need to adjust for your application. Click “Next”.

We’ll stick with defaults here too. Click “Next”.

The device we are using uses zero-based Modbus addressing – you may need to change this to suit your device. Click “Next”.

Your application may require “byte swapping”, in our example we’re sticking with the defaults. Click “Next”.

We’ll leave block packs as their default settings and click “Finish”.

So that’s our Channel and Device set up, next we’ll add a Tag. Select the device….

and click on “New Tag…”

The Tag needs a name, we’ll call it “tag1”, you can, of course, choose something more meaningful for your application. Enter the address here too… in our case, the address is 401025 (V2000 in the Koyo DirectLogic 06)

So we now have a Channel, Device and a Tag.

Save the file….

Test the connection using “Switch to Runtime”

The value of our Tag is shown…

Using the Modbus Driver in Infilink:

Start a new Infilink project… Click “Create”.

Click on “Yes” to create the new project.

In our example, we’ll use an “Angular meter”.

Draw the meter object on the window.

Right click on the object (or use F4) and select “Properties”

In our project, we have a full scale of 255, so this is set under “Ticks”

Under the Pointer tab, we will link to a tag by clicking “Tags…”

Click the “Driver Node” button

And give the node a name…. and click “OK”.

Give the tag a name, we are using “tag1” as per the setup in the Modbus Driver, but you can assign a different name… the Server item is “TCP_Channel_1.TCP_Device_1.tag1” as per our earlier setup. Click “OK”

The tag should now appear… highlight and click “Select”.

The Tag reference will appear as an expression (as a shortcut, now it’s defined, we can simply enter “Modbus\tag1” to use the tag instead of going through tag definition again). Click “Apply” and “OK”

Click on the “Run” button.

Project running…