Client Parameters

<< Click to Display Table of Contents >>

 

Client Parameters

Users can change Bilateral Tables of ICCP Clients, at run time, to add or change Tags, for example, to avoid stopping and restarting a Driver to apply these changes.

On the Client side, this operation can be performed while the Client is in Offline mode or during its normal communication.

During communication, users can change DataSet parameters, add, change, and remove DataPoints and devices. In Offline mode, users can create a completely new Bilateral Table.

 

Changes in Offline Mode

This operation can be performed when starting this Driver, by configuring the Start Offline (Allows Runtime Configuration) option. In this case, execute the steps described next.

1.Select the Start Offline (Allows Runtime Configuration) option.

2.Set the ICCP Client to Offline mode by writing the value "1" to the ICCP.ClientOffline Tag, according to the next example.

Write -1, 0, 0, 3, Array("ICCP.ClientOffline", 1)

 

3.Configure the ICCP.StartOffline Tag with the value "0". This Driver creates the Client component, because it is now in Online mode. However, this Client component is still in Offline mode, due to the previous step, according to the next example.

Write -1, 0, 0, 3, Array("ICCP.StartOffline", 0)

 

4.Write to the StartBatchDatabaseUpdate Tag. In the next example, this Tag was created dynamically before the call.

Set StartBatch = AddObject("IOTag", False, "StartBatch")
StartBatch.ParamItem = "StartBatchDatabaseUpdate"
StartBatch.N1 = 1
StartBatch.Activate
StartBatch.WriteEx 1

 

5.Add DataSets, DataPoints, and devices by using the UpdateDatasetDatabase, UpdatePointDatabase, and UpdateDeviceDatabase Tags. A single call must be performed for each component to create, according to the next example.

'In this case, there is a folder called SYS
'with a Block Tag with five Elements
'named UpdatePoint.
Set UpdtPoint = Item("SYS").Item("UpdatePoint")
UpdtPoint.WriteEx Array("TAGNAME_AAA",13,0,0,1)
UpdtPoint.WriteEx Array("TAGNAME_BBB",13,0,0,1)
UpdtPoint.WriteEx Array("TAGNAME_CCC",13,0,0,1)

 

6.Execute a call to the SaveDatabase Tag.

Set SaveDB = Item("SYS").Item("SaveDatabase")
SaveDB.WriteEx "BLT_Name"

 

7.Set the Client back to Online mode.

Write -1, 0, 0, 3, Array("ICCP.ClientOffline", 0)

 

Changes at Run Time

1.Write to the StartBatchDatabaseUpdate Tag. In the next example, this Tag was created dynamically before the call.

Set StartBatch = AddObject("IOTag", False, "StartBatch")
StartBatch.ParamItem = "StartBatchDatabaseUpdate"
StartBatch.N1 = 1
StartBatch.Activate
StartBatch.WriteEx 1

 

2.Inform all DataSets, DataPoints, and devices by using the UpdateDatasetDatabase, UpdatePointDatabase, and UpdateDeviceDatabase Tags. A single call must be performed for each component to create, according to the next example.

'In this case, there is a folder called SYS
'with a Block Tag with five Elements
'named UpdatePoint.
Set UpdtPoint = Item("SYS").Item("UpdatePoint")
UpdtPoint.WriteEx Array("TAGNAME_AAA",13,0,0,1)
UpdtPoint.WriteEx Array("TAGNAME_BBB",13,0,0,1)
UpdtPoint.WriteEx Array("TAGNAME_CCC",13,0,0,1)

 

3.Execute a call to the SaveDatabase Tag.

Set SaveDB = Item("SYS").Item("SaveDatabase")
SaveDB.WriteEx "BLT_Name"

 

4.When executing a call to the SaveDatabase Tag, the current Bilateral Table is compared to this new Table, with the following rules:

If a match is found on both tables, the new table is copied over the existing one

If an entry is found on the existing table and not on the new table, the existing entry is deleted

If an entry is found on the new table and not on the existing table, a new entry is created

 

5.If any of these changes implies in changes on DataSets, such as adding or changing members, the DataSets are deleted and recreated immediately.

 

IMPORTANT

If a new Tag is created, it must be set to Advise mode (in scan) only after saving the database, that is, to add a new Tag to an ICCP Client at run time, first add the point to the Bilateral Table and save it by using the SaveDatabase Tag, and then create an I/O Tag in the E3 or Elipse Power application's Driver and set it to Online mode by configuring its AllowRead property to True.

 

6.Example of creating a Tag in E3 or Elipse Power at run time.

Set NewTag = Item("ICCPDriver").AddObject("IOTag", False, "MyTagName")
NewTag.N1 = 1 'This is a Client Tag
NewTag.AllowRead = True
NewTag.Activate

Was this page useful?