magazine-button
Home>Programmable Control>Columns>AUTOMATION SOFTWARE - OPC extender: Visual Basic development

AUTOMATION SOFTWARE - OPC extender: Visual Basic development

Written by  Jeremy Pollard October 16, 2007
In my last column, I reviewed the OPC DataHub from Software Toolbox. An accompanying product, the OPC Extender, is a logical transition for your Visual Basic (VB) development needs.

Users can use VB to create an HMI with the data that is served up by the DataHub, though the same is true when using any OPC server. You can also use a direct PLC driver; but once the OPC Unified Architecture (OPC/UA) is released, most industrial hardware vendors will support this specification, making OPC/UA the preferred data access method.

In fact, such companies as Rockwell Automation will be embedding OPC/UA into their hardware platform in future releases. To create an HMI in VB using an OPC server, you have to create code to connect to an OPC server, and there are many ways to do this.

Standard procedure dictates that you access OPC tags by name, perform the read, and do something with it. The OPC Extender changes all of this, allowing users to create applications without coding. This extends all controls in every application in which it is used.

Installing the application is painless, but it will only work with Visual Studio 2003/2005 and .NET. The 2005 Visual Studio Express version is not supported, although that is what I used for testing. VB6 users can use the ActiveX controls that come with the product, but keep in mind that a lot of the power will not be realized if you do.

I opened up Visual Studio and started testing. The scope of this test is to connect, read and write using the Extender. Just to be clear, the process of getting data into an HMI using OPC requires the use of a configured OPC server, which includes defining tag names for each PLC address you need to access.

Once the VB development is open, you can start a new project, add a form and then add the Extender components you need. There are a few components that can aid in automatically stepping the user through the process of configuring the application.

I first added the OPC data engine that connects the VB application to an OPC server. This connector searches the computer that you named the default computer for installed OPC servers. These OPC servers will communicate to the PLCs and extract data, which you can then configure. The engine will enumerate the tags that have been previously configured.

The "Subscription" extender allows you to connect to the OPC data engine. It subscribes to the OPC data engine, and asks for the data and information that you specified on the form you added after launching VB development. I added and selected a text box. The properties for this text box show up in the "Properties" window in the VB development environment. The "SubscriptionExtensions Array" property is where the connection is made with the object on the form. Anyone who has written code to connect a data point to an object knows that there is a bit to do to make this happen. But so far things have been painless.

The control that you associate with the OPC tag needs to have its display property associated with the data that the tag provides. For instance, "TEXT" is the property to connect with the OPC data tag, while "CAPTION" is the property for label control.

Using the text box control, the OPC Extender can format the data, and make the control read only, write only or read/write. You can add multiple connections to the object when there are multiple properties that can be set. There is an "InvokeMethodName" associated with each control. This only has real meaning for customer-generated controls where certain methods can be invoked upon a data change, such as the "PumpON" method when a pushbutton is pressed.

What does OPC Extender really give users? It will give them a huge jump on the market when OPC UA finally comes out. Since it separates the engine from the extension, the engine portion is the only part that changes when your OPC driver changes. Most industrial VB programmers donít code that way to allow for an easy upgrade path.

Does the Extender do everything without coding? Not really. If you want to change the colour of the text in the text box when the value exceeds 100, you have to do that with code. Remember that the form controlsí method can be invoked when the data is changed, but the code has to be written.

Writing data is all done via code. However, the benefit of the OPC Extender is that you can work from the data that is attached to the control, and use the controls events, properties and methods in the code instead of the native OPC data.

The Extender is runtime distributable at no charge, so the price tag is easier to handle if you are dealing with OPC. The Extender can be very helpful for any OEM. Though it is expensive, it may just be the ticket for you if your applications cover various OPC drivers.

Software Toolbox will soon have a version that directly accesses PLC memory.

Jeremy Pollard is a 25-year veteran of the industrial automation industry. He has worked as a systems integrator, consultant and an educator in the field. Jeremy can be reached at This e-mail address is being protected from spambots. You need JavaScript enabled to view it .

PRODUCT SPECS:
Name: OPC Extender
Version: 1.1
Vendor: Software Toolbox
Application: Visual Basic development
Price: $1,195 US

Last modified on June 16, 2009

Add comment


Security code
Refresh

The global programmable logic controller (PLC) and PLC-based programmable automation controller (PAC) market declined significantly across all regions of the world in 2009, but that is expected to change over…
Category: News
Read more...
KeControl C3, KEBA’s newest generation of controls, which has their debut on the SPS/IPC/DRIVES fair in Nuremberg in November 2009, have been selected as a winner of the iF product…
Category: News
Read more...
This year, with all of the economic challenges facing manufacturers, staying competitive is going to require cost reductions, increased productivity and efficiencies, innovation and the adoption of new technologies to…
Category: Features
Read more...
Okay, you’ve tackled PLCs, and now you can program them with one hand behind your back. So what’s next? What’s the next logical challenge? Think SQL and relational databases. Why?…
Category: Columns
Read more...
The automation systems market for discrete industries started to slow down rapidly with the economic trouble alarms that started sounding in the U.S. at the end of 2007. The manufacturing…
Category: News
Read more...
Californians have always been faced with the problem of how best to conserve, control and move water. California has a wide diversity of climactic and geographical contrasts. The northern part…
Category: Features
Read more...
What kind of controller is best for your application? Is it a PLC (programmable logic controller) — or perhaps you should use a PAC (programmable automation controller), or maybe a…
Category: Features
Read more...
Through the ’90s and the past decade, PCs became indispensable to every business, and naturally, many people and vendors started looking at using them to control machines and processes on…
Category: Features
Read more...
  • Latest Products

    • Programmable automation controller
      Programmable automation controller The new Allen-Bradley CompactLogix 5370 programmable automation controllers (PACs) from Rockwell Automation bring machine builders a high-performance, right-sized integrated motion control solution for their machine applications. The 5370 series, which…
      Read more...
    • Combo HMI-PLC with custom plug-in I/O
      Combo HMI-PLC with custom plug-in I/O Maple Systems' Human Machine Controller (HMC) combines an HMI and PLC into one unit. With customizable I/O, the HMC accepts up to five plug-in I/O modules with varying configurations of…
      Read more...
    • Programmable automation controllers
      Programmable automation controllers The Allen-Bradley ControlLogix 5570 Series programmable automation controllers (PACs) from Rockwell Automation include the ControlLogix 5571, 5572, 5572S, 5573, 5573S, 5574 and 5575 controllers. The PACs feature enhanced process, motion,…
      Read more...

    MA Online Resource Centre



    Featured Video

    More Videos...