Easy way to add descriptions to fairly large array in Studio 5000?

tetcie

Member
Join Date
Jan 2023
Location
UK
Posts
21
Hi All,

On my site, the standard template for storing recipes in the PLC is to create a tag called PartRecipe which is an 2D array - for example lets say 100x30.

PartRecipe[0,0] corresponds to part number 0, characteristic 0 (height). PartRecipe[0,1] corresponds to part number 0, characteristic 1 (width).
PartRecipe[20,0] corresponds to part number 20, characteristic 0 (height).

I have to add descriptions to each characteristic on each part number (so on every part numbers [x,0] the description is height) however, I am unsure how to do this easily/quickly, as I don't want to have to go through each individual array value to add the description in manually - if there's 3000 descriptions to add manually it'll take ages.

Does anyone know of any way to do this? I think this has been done in other PLCs on site by the previous engineer but I can't seem to find anyway in Studio 5000 that'll let me do it.

As you can probably tell this is the first time I've ever had to do this (and I havent been using Studio 5000 for very long either) - in previous jobs I've been able to store recipes in a database in the SCADA system and pull the data out from there but we're not capable of doing that onsite at the moment.
 
Add comments to a couple of them, file save as, change type to L5K or L5X. Open in NP++, notice the syntax for a commented tag, update all of your comments.
 
I'm not sure how much it would mess with your current programming but this sounds like a perfect application for a UDT.

Create a UDT with a single dimension array of your characteristics. Then a second String item for your description.

When you define your tag of type [whatever you call it] UDT, make it an array of your part numbers.
 
Maybe I'm off-base here, but why do you want to do this? It's clear you're using indirect addressing to pull your recipes from the array, and at that time it's necessary to know what each means. If that's the case (and that alone), only the target location needs to be labeled.
 
I'm with Steve on this, but to answer the question:

Comment the a couple of elements the way you want them, export tags and logic comments to excel. Open the file in excel, find the array and note how the comments are defined. Copy/paste and find/replace to your heart's content, and then re-import your file.
 

Similar Topics

See picture. I want to add a rung (magenta) into the existing code. Can't figure out how to do this. I select a -||- , right? When I drag/drop...
Replies
21
Views
1,800
I would like to do change a kinetix drive, so i believe i just have to put the IP address in the new kinetix and just connect right? Do I need to...
Replies
1
Views
1,201
Hey all, I am trying to check in logix designer in emulator and I need to check the hmi alarms by toggling bits to activate an alarm . But...
Replies
4
Views
2,068
Good afternoon guys, I have a basic question on the bubble level in the picture attached. This is probably really easy, but I don't get it, haha...
Replies
11
Views
3,359
Hi, I was wondering if anyone has experience of using an HMI that is easier to use and interface with a CONTROLOGIX PLC. I have alot more...
Replies
17
Views
5,383
Back
Top Bottom