ATTENTIONThis FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices. |
flexsim.com |
#1
|
|||
|
|||
Need help for coding on lifts.
Hi,
I need help for coding for the lifts. I want 3 lifts to serve level 4,5,6 and 1 lift to serve all levels. Can someone help me and guide me along? Regards, Chris |
#2
|
|||
|
|||
really need help.
Hi,
Really need help on these. Anyone can explain whether do I use the dispatcher to control the lifts in the way i want? Really need some help on the coding. Regards, Chris |
#3
|
||||
|
||||
Chris,
I think you should use 2 dispatchers. 1 for levels 4,5 and 6 and 1 for all levels and then determine what dispatcher you want to use. But ofcourse that means that everybody who is standing on 4 and needs to go to 5 will take one of the three but he could also take the other one so you have to determine with what rule which dispatcher is taken. Hope this is of any assistance. Steven |
The Following User Says Thank You to Steven Hamoen For This Useful Post: | ||
chrisquek (11-25-2008) |
#4
|
|||
|
|||
Hi Steven,
I understand about using 2 dispatcher having 1 of them connecting to the lifts which serve level 4,5 and 6 and the other to serve all levels. The problem is I do not know what command should be use in order to have the dispatcher telling the 3 lifts to serve only level 4,5 and 6. Could you advise me on how can I go about doing it? Regards, Chirs |
#5
|
||||
|
||||
Chris,
The dispatchers do nothing more than passing on a tasksequence that you give them to a lift that is free. It is the tasksequence that determines where the lift is traveling. So if you are on level 4 and you create a tasksequence to go to level 5 you have to pass it to the right dispatcher. So instead of writing: "createemptytasksequence(centerobject(queue,1),0,0 );" you have to change the 1 in a 2 or use a variable. So for instance: int LiftType = 0; if( CurrentFloor > 3 && CurrentFloor < 6 && DestinationFloor > 3 && DestinationFloor < 6) { LiftType = 1; } else { LiftType = 2; } createemptytasksequence( centerobject( queue, LiftType ), 0, 0 ); Steven |
The Following User Says Thank You to Steven Hamoen For This Useful Post: | ||
chrisquek (11-25-2008) |
Thread | Thread Starter | Forum | Replies | Last Post |
Need help urgently - model with multiple lifts (taskexecuter) | chrisquek | Q&A | 7 | 07-11-2008 07:50 PM |
A pitfall in Flexsim coding | AlanZhang | Gripes and Goodies | 7 | 05-16-2008 03:37 PM |