Invalid Size Of Array

hitthis911

Member
Join Date
Dec 2020
Location
Thunder Bay
Posts
12
I'm running into an issue with a few Add-Ons within my rungs, I will add some pictures for a description of what is happening, I know I'm missing something simple but for the life of me a can figure out what.

Thank you in advance.

Agitators.PNG Agitators2.PNG
 
Your tag size doesn’t look to match the requested AOI array size. Opening up the array parameter window will display the desired tag size... or type in a new tag name and press ctrl+W to get the pop up add tag window with the default data type and size filled in
 
You need to look at the AOI definition to see what size that input is expecting. The tag you are trying to use in your AOI must match exactly. I see the tag you are using is an array with a length of 1, if the AOI is expecting an array with the length of anything other than 1, it will complain. Also, the tag format may need the "[0]" at the end.
 
In this snip it appears to me that the array size is [41] on the in and [2] on the out. When i input that I get "Invalid Array Subscript Specifier" error.

Agitators3.PNG
 
In this snip it appears to me that the array size is [41] on the in and [2] on the out. When i input that I get "Invalid Array Subscript Specifier" error.


Post the whole program; more eyes looking is better; everyone watching through OP's eyes is slower and/or untenable.
 
As drbitboy said, having the whole would help, but I believe the error is telling you everything you need to know, which I've already addressed:

How you typed it in the AOI is likely wrong, it needs to be "...Data[0]", not "...Data" and the size of the arrays you are passing to your AOI don't match. The AOI is expecting a size of 41 for your input and a size of 2 for your output. The tags you are passing to the AOI are a size of 1.
 
There appears confusion between the AOI's data type and what the AOI expects as parameters. For example, BCM_3 is declared as the AOI's data, but then is being passed into it the first argument. The AOI is expecting a different UDT -- one that associated with the device, which looks like a smart motor starter. That UDT should have a 41-byte array to pass as the input argument and a 2-byte array to receive the AOI's output.
 
This may seem like a dumb question but where would I find the "code" and or "declaration" on Logix5000.

In your controller organizer, try finding the Add-on Instructions folder.
This should have a subfolder with your AOI's name, tags and logic. I think this is what people are referring to.

Another question, did you add that module as a generic module, or using an EDS file? Sometime you have to be careful with the sizes defined for generic, or even EDS based modules. This can potentially make the AOI deem the incoming data wrong.

Also, what is the size of the BCM_3.data? What device is BCM? Is the AOI public? I can try and figure it out on my Studio5k.
 
Last edited:
Sorry for the slow reply, I finally got this issue solved. The issue was coming from the module definition, I had left it as default and did not match what the add-on instruction was. I will attach a picture of what I changed. Thank You very much for all the help.

Agitator5.PNG
 

Similar Topics

Hi All, Can I get help with the following Invalid Input Size Fault displayed in Studio 5000. Allen Bradley: Studio 5000 V33 CompactLogix...
Replies
1
Views
1,405
I have a problem with 2 powerflex 40 connected via 22-comm-E (multi-drive) with a compactLogix L32 controller. I'm sure I've correctly set all...
Replies
1
Views
4,485
Hi, I'm trying to add ethernet modules to one of our plcs, but I get about 15 errors that say "Invalid Signature. Reseal instruction to resolve."...
Replies
5
Views
298
Hello, Im new to Studio 5000 View Designer and i try to make a popup reusable screen. So i create a user-defined screen with 2...
Replies
2
Views
239
Hi, I'm setting up a new cell with a Fanuc R30iB and Compact Guardlogix 5380 PLC. I have gone through my robot setup as usual, but have not...
Replies
2
Views
705
Back
Top Bottom