Introduction to FactoryTalk View Global Objects
Using FactoryTalk View Global Objects, you will create a single object that you use many instances of in your project. For example, consider a tank farm. You might create one tank object that you use for 32 different tanks. Any change you make to the global object applies to every tank. Consequently, this makes your object much easier to develop and maintain. Since each instance of the object relates to different tags, the object itself uses “Place Holders”. The place holders are replaced by tag names during runtime.
Create the FactoryTalk View Global Objects
In this case, I’ll create a global object to control a simple light. In logic, I have the same add-on instruction to control each light. Basically, this ensures that all of the lights work the same way, and guarantees consistency in tag names. They just have different input and output addresses. Obviously, each add-on instruction in logic will also have it’s own unique tag name.
To create the global object, simply right click Global objects, and create new.
I’ve grouped some objects together for this global display to control each light. In this case, I have a text object at the top to display which light I’m controlling. Also, I have a maintained pushbutton, as well as preset and accumulated values for delaying each light on and off.
With this purpose in mind, set up the objects as if you are using them to control a single light.
Add your Place Holders
First, take a look at the text object. We want the text object to reflect which light we are controlling. The name of the light will be different in each instance. For this reason, our variable is a place holder. I’ll declare this as place holder #104 as you can see.
After that, let’s set up the connection for the maintained pushbutton object.
Remember that each light has an add on instruction. This add-on instruction has a unique name in logic. The parameters for each instruction are the same…. For example: To turn on the kitchen light via HMI, I will write the value of 1 to “Kitchen.HMI”. To turn on the computer room light, I write a 1 to “ComputerRoom.HMI”, and so on. We see the commonality is the “.HMI” portion of the tag. However the name of the tag itself is variable, so we need a place holder for this.
When we add each instance of this global object later on in our project, we will declare what tag placeholder #102 needs to be replaced with.
Likewise, let’s look at one more example. Included in the same add-on instruction in logic is a time out timer. This accumulated value is the name of the tag associated with the add on instruction followed by “.TimeOut.ACC”. The name of the main tag is the same as the previous example, so we’ll use the same place holder (#102).
Repeat this for each portion of the global object.
Define the Global Parameters for FactoryTalk View Global Objects
At this point, we’ll define the place holders. Right click the entire global object group, and choose “Global Object Parameter Definitions”
Define each place holder you are using, and add a description. This will help you later on, when you use the object on your main display screens.
Add instances of the Global Object
Next, we’ll add all of the instances of the global object to a display screen for the operator to use.
Remember, each instance will use different tags. We need to declare which tags to use in leu of the place holders at run time. Let’s set up the first instance. I’m going to right click the first object, and select “Global Object Parameter Values”.
Finally, we’ll declare what we want to replace the placeholders with at runtime for this particular instance. Remember each instance will have different values for the place holders at runtime.
Repeat this for each instance of the global object.
Test the Display
Finally, we’ll test the display to make sure everything is working as expected!
For more information, visit the FactoryTalk View ME Category Page!
— Ricky Bryce