<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Batch item only leaves queue after previous item has finished the next task. in FlexSim Forum</title>
    <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576849#M75891</link>
    <description>&lt;DIV class="fr-view clearfix"&gt;Argh!  Thanks &lt;A rel="user" href="https://answers.flexsim.com/users/19365/felixmh.html" nodeid="19365"&gt;@Felix Möhlmann&lt;/A&gt; .&lt;/DIV&gt;</description>
    <pubDate>Mon, 25 Mar 2024 12:58:35 GMT</pubDate>
    <dc:creator>jason_lightfoot_adsk</dc:creator>
    <dc:date>2024-03-25T12:58:35Z</dc:date>
    <item>
      <title>Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576840#M75882</link>
      <description>&lt;P&gt;&lt;I&gt;[ FlexSim 24.0.2 ]&lt;/I&gt;&lt;/P&gt;&lt;DIV class="fr-view clearfix"&gt;
 &lt;P&gt;Hello,&lt;/P&gt;
 &lt;P&gt;I'm fairly new to this programme so this may be an easy fix.&lt;/P&gt;
 &lt;P&gt;For context I'm trying to simulate a section of a cable factory.&lt;/P&gt;
 &lt;P&gt;The first queue after the source represents a storage carousel where the intention is to stack 2 items (lengths of cable). For this reason I selected LIFO so the top cable will be removed first. However I need the queue to fully empty after it has 2 items stacked (I selected "flush contents between batches" to no avail). I also need the bottom item to wait until the top item has been fully processed by the processor - because in reality the bottom item (length of cable) cannot move until the top item (length of cable) has been fully removed from the storage carousel ie the time taken by the processor (VCV).&lt;/P&gt;
 &lt;P&gt;I hope this makes sense and someone is able to give assistance.&lt;/P&gt;
 &lt;P&gt;TIA, Jake&lt;/P&gt;
 &lt;P&gt;&lt;A rel="noopener noreferrer" href="https://answers.flexsim.com/storage/attachments/80385-cable-factory.fsm" target="_blank"&gt;Cable factory.fsm&lt;/A&gt;&lt;/P&gt;
 &lt;P&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;/DIV&gt;</description>
      <pubDate>Fri, 15 Mar 2024 16:55:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576840#M75882</guid>
      <dc:creator>JakeT</dc:creator>
      <dc:date>2024-03-15T16:55:44Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576841#M75883</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;&lt;P&gt;A hint first: one machine holds 2 items. You are better of by 2 machines are holding 1 item each. Merge statistic in calculated tables later.&lt;/P&gt;&lt;P&gt;This tool called FlexSim is event driven by triggers in objects or by activities in process flow.&lt;/P&gt;&lt;P&gt;you can control entry and exit of objects by methods of Flexscript Class API of objects. Suitable methods are close or open input or output.&lt;BR /&gt;&lt;A id="isPasted" href="https://docs.flexsim.com/en/24.1/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/Object.html#Property-input&amp;lt;/a&amp;gt;"&gt;&lt;/A&gt;&lt;A id="isPasted" href="https://docs.flexsim.com/en/24.0/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/Object.html#Property-input&amp;lt;/a&amp;gt;"&gt;&lt;/A&gt;&lt;A href="https://docs.flexsim.com/en/24.0/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/Object.html#Property-input"&gt;https://docs.flexsim.com/en/24.0/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/Object.html#Property-input&lt;/A&gt;&lt;BR /&gt;You find often templates to edit fields instead of writing a source code script yourself.&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Sat, 16 Mar 2024 06:28:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576841#M75883</guid>
      <dc:creator>joerg_vogel_HsH</dc:creator>
      <dc:date>2024-03-16T06:28:53Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576842#M75884</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;&lt;P&gt;Here one approach (there are many).&lt;/P&gt;&lt;P&gt;First I would make all the objects with the same behavior instances of the same template just so that you only have to alter the logic on the template and not on each instance.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="makeinstancesoftemplate.gif"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1522968i55D09241D9532E66/image-size/large?v=v2&amp;amp;px=999" role="button" title="makeinstancesoftemplate.gif" alt="makeinstancesoftemplate.gif" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Then add to the queue template a process finish trigger that adds the item label 'hold' set to 1 on the item below (current.first) and adds a label 'itemBelow' to the top object (current.last) with the value item.first;&lt;/P&gt;&lt;P&gt;Change the sendtoport to return -1 if the label hold is 1. (item.hold?==1) and zero (any port) otherwise:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="1710769308254.png"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1522969iA347F0E98ED7221C/image-size/large?v=v2&amp;amp;px=999" role="button" title="1710769308254.png" alt="1710769308254.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Then on the VCV template object add the 'end collecting'* trigger that sets 'hold' to zero on the item below releases it.&lt;/P&gt;&lt;PRE&gt;if (item.itemBelow?) {
&amp;nbsp; &amp;nbsp; item.itemBelow.hold=0;
&amp;nbsp; &amp;nbsp; releaseitem(item.itemBelow);
}&lt;/PRE&gt;&lt;P&gt;I've attached the model for moderators to review in case you get stuck and they need something to which they can refer.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10px;"&gt;*edited was previously and incorrectly 'process finish'&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 18 Mar 2024 13:37:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576842#M75884</guid>
      <dc:creator>jason_lightfoot_adsk</dc:creator>
      <dc:date>2024-03-18T13:37:50Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576843#M75885</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;&lt;P&gt;Hi &lt;A rel="user" href="https://answers.flexsim.com/users/43778/jaket.html" nodeid="43778"&gt;@Jake &lt;/A&gt;, 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.&lt;/P&gt;&lt;P&gt;If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always comment back to reopen your question.&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 21 Mar 2024 15:27:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576843#M75885</guid>
      <dc:creator>Jeanette_Fullmer</dc:creator>
      <dc:date>2024-03-21T15:27:43Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576844#M75886</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;
 Thank you Jason for the detailed response. I am trying to work through the steps of your answer. I have not figured out how to add the process finish trigger on both the queue and the VCV process. Is this something you could maybe expand on? 
 &lt;P&gt;I couldn't find your attached model to review. I was hoping to reverse engineer it to save me asking potentially stupid questions! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;
&lt;/DIV&gt;</description>
      <pubDate>Thu, 21 Mar 2024 17:13:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576844#M75886</guid>
      <dc:creator>JakeT</dc:creator>
      <dc:date>2024-03-21T17:13:42Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576845#M75887</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;
 Thank you Joerg, I will review the link attached. 
&lt;/DIV&gt;</description>
      <pubDate>Thu, 21 Mar 2024 17:14:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576845#M75887</guid>
      <dc:creator>JakeT</dc:creator>
      <dc:date>2024-03-21T17:14:52Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576846#M75888</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;&lt;P&gt;Jason probably wanted to say "On End Collecting" trigger for the queue, as queues do not have a Process Finish trigger.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="1711093583540.png"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1522970i6483EECB7684FA95/image-size/large?v=v2&amp;amp;px=999" role="button" title="1711093583540.png" alt="1711093583540.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;And I just realized that I capitalized the label names in the screenshot whereas Jason did not. Make sure that the label names match everywhere they are used as they are case sensitive.&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 22 Mar 2024 07:48:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576846#M75888</guid>
      <dc:creator>moehlmann_fe</dc:creator>
      <dc:date>2024-03-22T07:48:27Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576847#M75889</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;
 &lt;P&gt;Thanks for the comment Felix. &lt;/P&gt;
 &lt;P&gt;&lt;BR /&gt;&lt;/P&gt;
 &lt;P&gt;I have added your suggestions into the programme but the simulation is still not running properly. The main issues are:&lt;/P&gt;
 &lt;P&gt;1. VCV 3 is no longer being engaged at all &lt;/P&gt;
 &lt;P&gt;2. The 700T queues are not accepting more than 1 item causing the source to become blocked.&lt;/P&gt;
 &lt;P&gt;3. The 700T queues also enter a state of what appears to be constant releasing - which is causing the source to become blocked. &lt;/P&gt;
 &lt;P&gt;The aim is for the 700T queue to build up batches of 2 items, and then LIFO each item should supply the VCV (processor). the bottom item should not exit the queue until the top item has finished the VCV processor. &lt;/P&gt;
 &lt;P&gt;&lt;BR /&gt;&lt;/P&gt;
 &lt;P&gt;If anyone has any suggestion I would be extremely grateful. &lt;/P&gt;
 &lt;P&gt;I've made sure that all labels are worded the same. I'm getting these comments from the system console but unsure how to analyse and debug them. &lt;/P&gt;
 &lt;P&gt;&lt;BR /&gt;&lt;/P&gt;
 &lt;P id="isPasted"&gt;&lt;EM&gt;&lt;STRONG&gt;Label property Type retrieved on /Queue1/Woman. Label does not exist. at MODEL:/Queue1&amp;gt;variables/sendtoport&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
 &lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;Property itemBelow not available for Variant with value NULL. Must by a treenode type Variant. at MODEL:/VCV1&amp;gt;variables/processfinishtrigger&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
 &lt;P&gt;&lt;BR /&gt;&lt;/P&gt;
 &lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;&lt;A rel="noopener noreferrer" href="https://answers.flexsim.com/storage/attachments/80671-cable-factory-1.fsm" target="_blank"&gt;cable-factory (1).fsm&lt;/A&gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
 &lt;P&gt; &lt;/P&gt;
 &lt;P&gt; &lt;/P&gt;
&lt;/DIV&gt;</description>
      <pubDate>Fri, 22 Mar 2024 17:25:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576847#M75889</guid>
      <dc:creator>JakeT</dc:creator>
      <dc:date>2024-03-22T17:25:17Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576848#M75890</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;&lt;P&gt;You removed the header from the On Process Finish trigger so item is no longer a valid variable in your code.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="1711129012890.png"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1522972i3CC2DE23BB26FA73/image-size/large?v=v2&amp;amp;px=999" role="button" title="1711129012890.png" alt="1711129012890.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 22 Mar 2024 17:36:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576848#M75890</guid>
      <dc:creator>moehlmann_fe</dc:creator>
      <dc:date>2024-03-22T17:36:58Z</dc:date>
    </item>
    <item>
      <title>Re: Batch item only leaves queue after previous item has finished the next task.</title>
      <link>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576849#M75891</link>
      <description>&lt;DIV class="fr-view clearfix"&gt;Argh!  Thanks &lt;A rel="user" href="https://answers.flexsim.com/users/19365/felixmh.html" nodeid="19365"&gt;@Felix Möhlmann&lt;/A&gt; .&lt;/DIV&gt;</description>
      <pubDate>Mon, 25 Mar 2024 12:58:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/flexsim-forum/batch-item-only-leaves-queue-after-previous-item-has-finished/m-p/13576849#M75891</guid>
      <dc:creator>jason_lightfoot_adsk</dc:creator>
      <dc:date>2024-03-25T12:58:35Z</dc:date>
    </item>
  </channel>
</rss>

