how to set an elevator idle at level 3

how to set an elevator idle at level 3

Jenson
Not applicable
124 Views
18 Replies
Message 1 of 19

how to set an elevator idle at level 3

Jenson
Not applicable

[ FlexSim 23.0.1 ]

Hi, i need help with my 2nd elevator where it need to be idle at level 3 but it seems that it idle at level 1. hope someone can help.

Final After.fsm

0 Likes
Accepted solutions (1)
125 Views
18 Replies
Replies (18)
Message 2 of 19

moehlmann_fe
Explorer
Explorer
Accepted solution

Do you mean that the elevator should start the model on the third level or that it should return to it when there are no pending requests?

In the first case, you can add a small block to a Process Flow (for example "Arrivals") that simply sets the location of the elevator to that of the third level at the start of the simulation.

1673426981238.png

I fear the second case might be a lot more complicated since the evelator banks are controlled in a unique way, compared to other task executers. You would probably have to monitor the request list and add an entry for level 3 when the list becomes empty and the elevator is currently at another level.

0 Likes
Message 3 of 19

Jenson
Not applicable

hi @Felix Möhlmann,

I have entered the code and it works thanks but i have another problem that occurred after I entered the code that i want the lift to be a station on floor 3 when there is no one taking the lift but currently is that when there no one taking the lift it will station at various lift ( example a patient goes to level 5 and no one else taking the lift. It will stuck at level 5 rather than then going back to level 3 )


Final After.fsm

0 Likes
Message 4 of 19

Jenson
Not applicable

@Joerg Vogel , sorry i have search the post under travel home and find there isnt anything related to elevator in healthcare. maybe u can advised me on it or can i have a sample Final After.fsm

0 Likes
Message 5 of 19

moehlmann_fe
Explorer
Explorer

In the attached model I use a process flow to react to the elevator becoming idle. If it is not already at the correct height, the process flow tells it to travel there.

This seems to work fine, but I can't guarantee that this won't interfere with the standard logic in weird ways at some point.

Edit:

Sorry, I just realized that the model was build in an older version. Here is the updated model in 21.0

elevator_home_location_21.fsm

Please remember to select the correct software version that you are using, when asking a question.

0 Likes
Message 6 of 19

Jenson
Not applicable

@Felix Möhlmann , but once no one taking the lift it will idle at level 3 but it does not take in people at the waiting time ?n

0 Likes
Message 7 of 19

moehlmann_fe
Explorer
Explorer

The people in the waiting line (more specifically the first one) are still waiting to acquire a location.

1673525939023.png

0 Likes
Message 8 of 19

Jenson
Not applicable

@Felix Möhlmann , But if that the case, how do i make lift 1 to take in people from level 3 if lift 2 is occupied. sorry to bother you

Final After 2.0.fsm

0 Likes
Message 9 of 19

moehlmann_fe
Explorer
Explorer

People will always use the elevator that results in the shortest path, so generally the one closest to their current position.

For possible ways aorund this see this post and the links inside.

0 Likes
Message 10 of 19

joerg_vogel_HsH
Mentor
Mentor

@Jenson instead of on resource available the Elevator Bank Object has got an Event called On Idle. This event is only accessible in process flow. You can use it for a single elevator bank object or a group of elevator bank objects.

A Event Driven source can create a token in process flow. You put involved object reference into a token label in the edit field "Assign Event Object To" for example as token.elevator.

You can build a tasksequence by source code or by Process Flow activities as @Felix Möhlmann has shown.

A Tasksequence in scource code consists of a create method, one or several added tasks and finally dispatching of the created tasksequence treenode.final-after-jv.jpg final-after-jv.fsm

0 Likes
Message 11 of 19

Jenson
Not applicable
@Joerg Vogel , Hi i saw the code u mention but elevator bank1 need to station at 1st floor and elevator bank 2 station at 3 floor ( which able to work) but my elevator bank 1 need to accept patients from level 3 as well whn there is space to enter .
0 Likes
Message 12 of 19

Jenson
Not applicable
@Joerg Vogel hi, the problem is it i didnt place enough location?
0 Likes
Message 13 of 19

joerg_vogel_HsH
Mentor
Mentor
homets.addTask(TASKTYPE_TRAVELTOLOC,NULL,NULL,homeLocation.x,homeLocation.y,19.9);

you can set a variable for different home locations by a switch by case structure:

Vec3 homeLocation = elevator.location;
Variant bank = elevator.up; //Datatype treenode or Object ist possible, too
Array banks = ["Elevator Bank1", "Elevator Bank2"];// array of Elevator Bank names
switch(banks.indexOf(bank.name)){
    case 1:
    { homeLocation.z = 20.0;
      break;}
    default: // or case 2: for "Elevator Bank2" for more elevator banks
    { homeLocation.z = 10.0; // set right value
      break;}
}// switch bank.name end
homets.addTask(TASKTYPE_TRAVELTOLOC,NULL,NULL,homeLocation.x,homeLocation.y,homeLocation.z);

final-after-more-home-locations-jv.jpgfinal-after-more-home-locations-jv.fsm

0 Likes
Message 14 of 19

Jenson
Not applicable

@Joerg Vogel hi, sorry to bother you. I think i need to explain detailed on my help cause it does not work. The scenerario is that Elevator Bank 1 will accept patients from level 1 and 3 and elevator 2 will start working on level 3. But elevator bank 1 did not recevived patient from level 3 when the elevator has enough room for more patients to enter the lift . That is goes as well as elevator bank 2, so im having these problems.

At the same time how can I set both elevator to continue accept patients even though certain level only allow a number of people to occupied the same( because I doing a simulation on school where there is 2 lift opposite of each other )

Hope you can help me on it . Maybe u can voice call or something to help or under this comment. Thanks

0 Likes
Message 15 of 19

joerg_vogel_HsH
Mentor
Mentor

Ok, It is hard to express technical data by words. A common practice is to enhance a process charts by words. The end is most a manual. Maybe you can express want you want by a process chart. If you haven't any program for this, you find typical flow chart symbols in Process Flow library panel.

pf-flow-chart-hc.jpg


0 Likes
Message 16 of 19

Jenson
Not applicable

screenshot-26.pngscreenshot-25.png@Joerg Vogel Hi, here the flowchart. Hope this will help. Thanks for helping me

0 Likes
Message 17 of 19

Jenson
Not applicable
@Joerg Vogel hi, i send you the flowchart already. Is it working or there is some error?
0 Likes
Message 18 of 19

jason_lightfootVL7B4
Autodesk
Autodesk
Implement it in a process flow and find out.
Message 19 of 19

Jeanette_Fullmer
Community Manager
Community Manager

Hi @Jenson, was one of Joerg Vogel's or Felix Möhlmann's answers helpful? If so, please click the "Accept" button at the bottom of the one that best answers your question. 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