Changing Motor Folder to Motor Instance Tag?

I am currently using the Programmable Device Simulator and one of the programs that Ignition pre-made. I ran into this problem when trying to create use a UDT for a template. The motors amp and HOA properties are defined in a folder and I can’t upload a folder to template properties. Is there a way to change that motor folder into a motor instance tag while keeping the same amp and HOA properties? Could I do this on the gateway side of things or is a motor instance something that is created and modified on only the Designer?
Would going through the device settings on Gateway and setting the expression defining the amps to define the motor then branching off of those with the Amp and HOA properties in the Designer work?
Also, would there be a way to use the motor folders in this instance with some workaround scripting or no? I am new to Ignition so my scripting knowledge is very little.

Where there is a will, there is a way.

But your cleanest, easiest way will be to create a UDT with said properties, and create instances for each motor.

Then use indirect tag addressing in your template so it works dynamically with your UDT instances

1 Like

In addition to what @andrews said, what you’ve got there is a Template that has a UDTType template parameter defined which links to a type of motor UDT definition. These let you directly link a UDT instance of that type to the Template when you use it on a screen. While it might seem useful on the surface, there are a few downsides which for me and a lot of others means we steer clear of using UDTType parameters whatsoever.

The alternative solution as @andrews mentions is to create string type parameters to pass in the tag path to the device instance. Then you can use indirect tag bindings within the Template to read any tag attached to the device such as hoa, status, etc.

To create a UDT Definition from those motor tags, you can right click on one of the motor folders and select create udt from tags


Just curious what would those downsides be as far as using a UDTType template parameter?

Also I did try using the indirect binding parameter but as far as I could tell there wasn’t a way to bind a template parameter to the motor numbers as those are not actual motor instances but just folders holding both an Amps and HOA tags in each folder. Those 2 are bindable and I could create UDT instances to bind to 2 template parameters but this would be annoying to do. I guess my main question would be how to go about fixing this issue?

Say you’ve passed in your device tag path as a string into deviceTagPath as Overview 1/Motors/Motor 1.
Then on a component property you can use an indirect tag binding to read the two tags with:
Where {1} is bound to {Template Name.deviceTagPath}

You don’t need to use UDT for your tags, but it’s far easier to maintain a standard if you do for things that are repeatable. Again, not talking about udttype params in the graphics, just udt tag definitions and instances.

I’ll find you the reasons not to use udttype params later on, they’re scattered throughout the forum though

1 Like

Ok I managed to make everything work out thanks to your help. Thank you.

I ended up not using UDT for my tags as the UDT would not read the folder name and just going with indirect tag bindings. To set it up the way I would need to to make that work I think I would need to mess with my tag paths on the gateway side and that’s something I can mess with later.

Yep I ended up just using indirect bindings without the UDT instances as a UDT definition wouldn’t read a folder name to get its values. I will have to mess with the Gateway side of things to make the UDT instances work but at least now I know how to go about fixing this problem when I go to do an actual project rather than just a device simulator.

Your could make the folder in the tag path indirect. And use a parameter you pass to change it.



thats what I did