Overview
Points are individual items that can be read or written from/to Nodes. They can be Device Points represent specific data elements (like registers, I/O values, or variables in field devices (Nodes). Each Point is bound to a specific Tag in the solution configuration) within a Node, which represents a connected device. By binding device points to tags in the software, they provide granular access to device data for both monitoring and control, enabling seamless data exchange between the platform and field devices.
On this page:
Table of Contents maxLevel 3 style none
Adding and Editing Device Points
Data Device Points define specific values for each Node node that can be accessed using Tagstags. The number of data Device Points you can configure is related to both the Product Model that is the product model configured for the project solution and your software license.
To configure pointsDevice Points, follow these steps:
- Access
- Access Unified Namespace → Tags. Copy
- Copy the tags to be used. Access
- Access Devices → Points.
- Paste the copied tags.
- Double-click the property you wish to edit on the row corresponding to the tag you want to modify.
Info |
---|
To add or remove a column, right-click the heading area and select or deselect columns. |
Device Points Properties
The following table describes each available property you can configure when configuring a Device point:. If a property column is not visible on the grid, enable it by right-clicking the grid header and selecting it from the list.
Column | Description | ||
---|---|---|---|
TagName | The associated tag name. The three dots button | Tag Name | Enter a Tag name or click "..." allows you to select a tag. You can also create a new Tagan existing tag from a list. |
NodeSelect | Defines the Node associated node for this data pointDevice Point. | ||
Address | Enter Defines the register address, which is based on the PLC and protocol for this data Point and Tag. | ||
Data TypeDataType | Select Defines the data type you want to usebe used. Most protocols should use the native option since the protocol will automatically handle the data conversion. Selecting a different data type overrides the defaults. Some options may not apply to the selected Node. Make sure you know the applicable data types.node. | ||
Modifiers | Select the options you want if the PLC uses a different byte order. You can change the position bit, byte, Word, or Dword of the communicated data. | ||
Access TypeAccessType | Select the access type for this data Point. You can define and configure the access types. → Read more about Devices AccessTypesSee Access Types for additional information. | ||
Scaling | If you want to manipulate This property manipulates the Tag value , select the options you want. When when the data is read in the Equation option, it has 2 options:
For a write operation, the calculations are the opposite. The system will multiply by the Div value, then subtract the Add value. | Label | A text that represents a label to the Point. |
Dynamic Address Configuration
Everything in the Device configuration, from the Node to address and Tag mapping, can be changed online using scripts.
The following example outlines a process for configuring dynamic addresses using MQTT telegrams.
Dynamic Address example
The address format is `/topic/@Tag.gateway/data`, where `@Tag.gateway` will `@Tag.gateway
` will be replaced with specific values. The MQQT telegrams are received on topics like the ones below:
- /topic/gateway/data:
- /topic/gatewayX/data
- /topic/gatewayY/data
- /topic/gatewayZ/data:
You need to configure the Points that will be used. Access Devices → Points to configure points defining their names, Node, Tags, and Address.
To use the Dynamic Address through scrips, your code will need to execute the following steps:
- First, it needs to retrieve the data of the desired point from the database using the
GetDataTable
method. - Then, you will update the Address field of the retrieved data row with a new address formed by concatenating
Group
,@Tag.Gateway
, and/Device
. - After performing the changes, your code will update the database with the new row data using
UpdateDataRows
.
The system will log an error if any error occurs during the updating process. Otherwise, it applies the changes to the database.
The following code presents an example of changing the Address for the desired point.
Code Block |
---|
string error; DataTable dt_DevicePoints = TK.ProjectDB.GetDataTable("EditDevicesPoints", "TagName='Tag.Tag01.Velocidade'"); DataRow[] rows = new DataRow[1]; rows[0] = dt_DevicePoints.Rows[0]; @Info.Trace(rows[0]["Address"].ToString()); rows[0]["Address"] = "Group01/"+@Tag.Gateway+"/Device01"; @Info.Trace(rows[0]["Address"].ToString()); rows[0].AcceptChanges(); TK.ProjectDB.UpdateDataRows("EditDevicesPoints", rows, out error); if (String.IsNullOrEmpty(error) == false) { @Info.Trace("Error changing tag address: " + error); } else { @Info.Trace("Applying Devices Changes - begin"); TK.ProjectDB.ApplyProjectChanges(); @Info.Trace("OK!"); } |
Code Breakdown
To make it easier for you to understand the above example, next you find additional explanations related to core operations.
In the code block below, the first parameter identifies the Points table from which data is retrieved. In this case, the second parameter refers to the specific column used for filtering data, the Tag Name column. This column is used to identify the tag configured within the Points table. For instance, the tag Tag.Tag01.Velocity
is retrieved in this example.
Code Block |
---|
DataTable dt_DevicePoints = TK.ProjectDB.GetDataTable("EditDevicesPoints", "TagName='Tag.Tag01.Velocity'"); |
The following code enables you to choose the new desired address. The string type tag @Tag.Gateway will receive a different name in the example.
Code Block |
---|
rows[0]["Address"] = "Group01/"+@Tag.Gateway+"/Device01"; |
The following line of code updates the Address internally in the system.
Code Block |
---|
K.ProjectDB.UpdateDataRows("EditDevicesPoints", rows, out error); |
If no error occurs in the update, you can apply the change to the project using the code below. From then on, the Address will use the new value previously entered on the script.
Code Block |
---|
TK.ProjectDB.ApplyProjectChanges(); |
Importing Device Points
Fromfrom PLC
Addressesaddresses
Addittionally Additionally, you can simplify the creation of Device Points with various methods for automatic data configuration import. Access the
? Read more about Importing PLC Addresses for further information about the process and configurations available.
In this section:
Page Tree | ||||
---|---|---|---|---|
|
...