Logix5000/Designer Call AOI from Structured Text Routine

AMarks95

Member
Join Date
Jul 2018
Location
South Dakota
Posts
224
How do I call an AOI from an ST routine?

I have tags made for the AOIs in my Controller Tags group, but how do I call the AOI in a Structured Text routine so that the logic is executed on each one.

For example, I have an AOI called "SCP" and an instance called "SCP_test". Do I call it like so?
SCP(SCP_test, SCP_test.Input, SCP_test.In_MIN, SCP_test.In_MAX, SCP_test.Out_MIN, SCP_test.Out_MAX, SCP_test.Output);
 
Code:
AO_Name(AO_Instance, Required param1, Required param2, ...);

Optional params can (and should) be set prior to the call:

Code:
AO_Instance.OptionalParam1 := someValue;
AO_Instance.OptionalParam2 := {some expression};
AO_Name(AO_Instance, RequiredParam1, RequiredParam2, ...);

And finally, calling multiple instances:
Code:
AO_Instance1.OptionalParam1 := someValue;
AO_Instance1.OptionalParam2 := {some expression};
AO_Name(AO_Instance1, RequiredParam1, RequiredParam2, ...);

AO_Instance2.OptionalParam1 := someValue;
AO_Instance2.OptionalParam2 := {some expression};
AO_Name(AO_Instance2, RequiredParam1, RequiredParam2, ...);

AO_Instance3.OptionalParam1 := someValue;
AO_Instance3.OptionalParam2 := {some expression};
AO_Name(AO_Instance3, RequiredParam1, RequiredParam2, ...);
 
Last edited:

Similar Topics

Strange things happening.... I have a bunch of RSLogix5000 V20 .ACD files that open perfectly well on my desktop PC, but when I try to open them...
Replies
5
Views
2,644
Whenever I doube-click a RSLogix 5000 v20.04 .acd file, I see an process popup called Logixdesigner.exe in the task manager but it never opens up...
Replies
11
Views
3,170
Hi! So my problem is a little funky, I had Studio 5000 v 24 and 30 installed, but forgot to install RSLogix (which I cannot go without). Is there...
Replies
2
Views
112
So I had an odd request from a customer for the above. I have written the logic and tested it all in one PLC with only using 7 outputs and 7...
Replies
15
Views
427
I'm a Siemens person, and this is one of my first AB programs. The customer wants everything programmed in Ladder. I have a lot of data (3...
Replies
14
Views
216
Back
Top Bottom