question

Ankith T avatar image
0 Likes"
Ankith T asked Joerg Vogel edited

How to know the type of operator allocated to Control Area/point

I have a model where people and Task executers share a common travel area. To avoid collision between people and Task Executers i am using a control area. i would like to know the type of operator allocated the control area so that if a person allocated the "Max allocations" of the control area can be more than 1 eg., 5 or 6, but if a task executer allocated the control area the max allocations is 1.



1677793465433.png

FlexSim 21.0.10
taskexecutorcontrol areaoperaterallocationoperator type
1677793465433.png (356.8 KiB)
· 3
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Joerg Vogel avatar image Joerg Vogel commented ·
People objects are a flow item class objects. Operators are inherited from taskexecuter class.
0 Likes 0 ·
Ankith T avatar image Ankith T Joerg Vogel commented ·
but i would like to know in the process flow using custom code, which operator allocated the control area, how can i recognize that.
0 Likes 0 ·
Jeanette F avatar image Jeanette F ♦♦ commented ·

Hi @Ankith T, was Jason Lightfoot's answer helpful? If so, please click the "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes 0 ·
Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot edited

In the current version you may be able to use routing constraints to block the allocation of the control area, but in your version you'll need to manage the stop/start of task executers (both types) based on the state of the control area allocation which you can detect and maintain using a process flow.

· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Jason Lightfoot avatar image Jason Lightfoot ♦♦ commented ·

Once you have a pointer to the allocated TE you can test for it being an instance of the Operator class using:

classobject(allocTE)==library().find("?Operator")
0 Likes 0 ·
Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Joerg Vogel edited

I tested all Operator types: People, flow item and operator. They are all the same. taskexecuters/Operator. Then you can not distinguish from their attributes how they got into a model. class_taskexecuter_from_peoples_operator_flowitem.fsm

Edit: Knowing this, all you can do is to mark each operator on creation or after dragging them into a model by label. This label can you use to distinguish a type.


5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.