(bright music)
- [Instructor] We've created a simple device type
with variable tags included in Profile Editor,
but what happens when you need one that is not in that list?
Our default tags are based around standard electric meters,
but we want more than that in our project.
Let's look at how we can create our own custom tags.
Before we create a new tag, however,
let's look at variable tag name.
This IEC Tag Name field is the name that will be inserted
into our database and referenced frequently
inside the software.
This naming convention is based on a simplified version
of the IEC 61850 standard.
While it's not absolutely necessary
to follow this convention, you should at least come up
with a naming standard.
A standard will allow you to use common code
for different types of devices.
If my phase A current is always MMXU1\A\phsA,
I can write code that operates on current
for all my electrical meters.
If you're interested in following this standard,
I encourage you to read up more on IEC 61850.
The same goes for the Item Name.
This is a more friendly name that we'll use in the graphics,
and should also be as standard as possible across devices.
One more thing: Tag Description, Item Name, and IEC Tag Name
must all be unique within Profile Editor.
You cannot create duplicate tags.
There are two ways to access the custom tags dialog.
In the Settings menu, I could select Set Up Custom Tags.
More often though, I'll be in the middle of assigning tags
to a device type and realize that I'm missing one.
For this example I think I want to display
the firmware version in the graphics.
Here, I'll click Add/Edit Custom Tags.
As with a device type,
I have the same four options at the top of the screen.
With any luck I'll be creating a tag
that is similar to another, so I'll use Create From.
Here I can search for existing tags,
so this is also useful for verifying
that my tag doesn't already exist.
Firmware only has Onboard Alarms,
which are not what I'm looking for,
and version has nothing at all,
so it looks like I'm starting from scratch.
For Tag Name,
I'm not going to follow the IEC 61850 naming convention,
but again, I encourage you to come up with some standard
rather than creating every tag uniquely.
A Display Name should be more readable.
This is the name that will show up
both in Profile Editor as well as in the final runtime.
Item Name will generally be similar to Tag Name,
but can also have spaces.
Group defines where this tag is found inside Profile Editor.
If a value doesn't make sense anywhere else,
it goes in Miscellaneous.
Data Type determines the variable type used
inside the software's database.
Referring back to my register list,
the firmware is stored as a 16-bit unsigned integer.
Let me open up my help file
to the page Logic code definitions.
If I search for unsigned here,
I'm taken straight to the Scaled Register Unsigned.
The description looks like the type of value I'm reading,
and this is stored as a REAL tag,
so that's what I'll choose in Profile Editor.
If my value had units, I would select them here.
Engineering Units can be accessed in CICODE functions,
and Profile Editor has functionality
to automatically convert units,
which we'll see in a later video.
CITECT Format is the default number of characters
displayed in the graphics.
This tag is an integer,
so I'll select four digits with no decimals.
Polling Priority sets that default priority
that we saw when we addressed our other tags.
Since it mostly has no effect, I'll leave it at Normal.
Alarm Text is used by digital tags only.
They display this text on the alarm pages
when their alarms trigger,
if your profile uses them as alarms.
The remaining options are used to categorize
various filters in runtime which you are welcome to set.
The only one I'd like to point out is the Alarm Level.
We will return to these categories
when we discuss alarms in later videos,
but I want to point out that they are initially configured
at the tag level.
With all of my options set now, I'll Save & Exit.
You can see why I prefer to create my tags
from existing ones and as your tag library grows,
you'll click Create New, less and less.
This concludes our exercise in creating a variable tag.
I'll apply an address to this register,
then we can move on and build a profile
based on this device type.
Until then, thank you.