ATTENTION

This 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

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 01-04-2013
George Serhan George Serhan is offline
Flexsim User
 
Join Date: Oct 2011
Posts: 49
Downloads: 10
Uploads: 0
Thanks: 59
Thanked 0 Times in 0 Posts
Rep Power: 107
George Serhan is on a distinguished road
Default closing specific port#

Hi,
There might be a simple answer to what I'm trying to do. I have a source that is distributing the same items to a queue and a processor. The queue gets the priority of the items up to a count of 2 then the items suppose to route through the processor. I tried using the closeoutput, but it closes both output of the source. Closeip doesn't work on discrete objects (wish it would). I tried to assign a port# and see if I can turn it off, no success. sample model is attached.
Thanks
Attached Files
File Type: fsm Port Closing.fsm (66.3 KB, 101 views)
  #2  
Old 01-05-2013
Jörg Vogel's Avatar
Jörg Vogel Jörg Vogel is offline
Flexsim User
 
Join Date: Sep 2007
Location: Hannover, Germany
Posts: 643
Downloads: 35
Uploads: 0
Thanks: 802
Thanked 665 Times in 410 Posts
Rep Power: 642
Jörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond repute
Default

you can put between the Queue und the Processor two further Queues. Now you can control the output in the inserted Queues.

Joerg
  #3  
Old 01-07-2013
Jörg Vogel's Avatar
Jörg Vogel Jörg Vogel is offline
Flexsim User
 
Join Date: Sep 2007
Location: Hannover, Germany
Posts: 643
Downloads: 35
Uploads: 0
Thanks: 802
Thanked 665 Times in 410 Posts
Rep Power: 642
Jörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond reputeJörg Vogel has a reputation beyond repute
Default

You can write your own code in the Send to Port under flow in the source object: if the content of the object of output-port 1 (queue) is greater than 1 send the flowitems to port 2 (processor).
Code:
if (content(outobject(current,1)) > 1) return 2;
return 0 ;
Joerg
The Following 2 Users Say Thank You to Jörg Vogel For This Useful Post:
George Serhan (01-07-2013)
  #4  
Old 01-07-2013
George Serhan George Serhan is offline
Flexsim User
 
Join Date: Oct 2011
Posts: 49
Downloads: 10
Uploads: 0
Thanks: 59
Thanked 0 Times in 0 Posts
Rep Power: 107
George Serhan is on a distinguished road
Default

Thanks Joerg


Thread Thread Starter Forum Replies Last Post
Closing GUI Windows correctly Stephan Seidel Q&A 3 02-09-2012 05:10 AM
How to assign more than one physician to a specific bed? Lionel Lim FlexSim HC: Q&A 2 02-10-2010 10:13 AM
Problem in opening and closing ports claudia gertheinrich Q&A 3 01-22-2010 02:34 AM
Keeping run speed after closing the model Lydia Franck Gripes and Goodies 4 05-06-2009 03:38 AM
Close A Specific Port Joe Allen Q&A 2 09-11-2008 06:30 PM


All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.