After the robot program starts, will the URCap node’s DataModel be unified to one value?
We added several same URCap nodes as above gif and set different values of each DataModel.
However, when the robot program is executed, the DataModel values are unified into one.
@aofk159 i understand you adress a problem that has nothing to with sharing data between the nodes (which is explained above) so,
how do you trigger your data model inside the urcap entities? basically, for any UI Input all you need to do is to call model.set with every change (UI Input Button etc.) and (most importantly) call model.get with the specific key on openView(). The model Data will also be saved when you save your program. This way, it should be working with multiple urcaps of the same type
The current situation is like this.
After adding the same two URCaps, we set the model’s Job ID(model key) value (1000,2000 …).
However, when the robot program is started, the model values of the two URCaps are set to the model values of the first URCap in the program.
Can not set specific variable values in the data model?
If it is the same node, does it have the same value for one model value?
If the same URCap is contained in each of the parent node’s child nodes, is it a different class?
it should be working fine. Even if it’s a copied URCap Node it has its own Datamodel. I would check if your model.set and model.get functions are called well e.g. on openView()/ closeView() and save the right information or won’t reset to defaults.
Putting any URCap in a Subtree should also not lead to any problems with its datamodel.
Thank you. I noticed that it worked well before I started the robot program. However, when a robot program starts, it does not have its own data model but has the same value as one data model.
Although the value of the URCap node model is set to something else, the specific value of the model is fixed to one value in the robot program script. How can I make scripts have different values for each URCap node?