Plant logic

Order generation chooses Periodic orders or Plant logic. Search blocks by name in the When, Transport, Waits and decisions, Warehouse and Advanced variables groups. Find a block in the graph selects and centres it at a readable size; Focus selection frames selected blocks. Issues in an inactive graph belong to the draft and do not block periodic orders.

By default the simulator creates one order at a fixed interval, rotating through the selected pickup and drop-off pairs. Plant logic replaces that rule with a block diagram, so orders can follow production times, events at stations, conditions and counters.

Watch the videos: first workflow, variables and conditions, cyclic missions.

Designing with the AI assistant

When the AI service is configured, the AI button in the Draw, Plant logic and Simulate toolbars opens the same panel. An administrator separately enables beta access. The conversation, message draft and proposal remain available when switching workspaces. The − button (Minimize AI assistant) reduces the chat to a bottom-right bar showing its activity status. Click the bar or AI to restore it: drafts, references and active requests are preserved. The × button closes the panel.

  1. Describe your process. Type @ and select an element: the list distinguishes stations, paths, links, zones, warehouses, fleets, blocks and variables by name, type and ID. Use arrow keys and Enter to select; Ctrl+Enter sends the message. A name typed as plain text needs confirmation, even when it appears unique.
  2. Answer one question at a time about frequency, destinations, conditions, overlapping missions or position. Suggested answers are alternatives. You can say “you choose” to delegate missing parameters: assumptions appear in the proposal. You can add more @ references; selections stay confirmed throughout the conversation, including after reopening it. Only new elements need confirmation. When several elements are suggested, Confirm all selects those still available and sends confirmation in one click. For a subset, select individual elements and use Confirm references. Deleted elements are marked and their reference can be removed.
  3. Read the change summary. Preview shows logic, layout and parameters; the Before/Proposal button compares the original and proposed state, including indirectly moved geometry. To revise a proposal, send another message.
  4. Apply inserts all changes in one step, undoable with Ctrl+Z. Until then, neither the project nor the simulation changes. Discard dismisses the proposal; normal Save persists applied changes.

Multiple processes become independent sequences in the same workflow. Existing sequences remain. When deletion is needed, the panel offers Allow deletions and continue or Continue without deleting. The first button sends consent and continues; you do not need to write flags or edit JSON. The proposal remains a preview until Apply. You can also enable Allow deletions for this request under Options. Enabling the workflow replaces periodic generation. The assistant uses only existing blocks and functions, including Production profile; it asks how to adapt requests that cannot be represented. It also lays out VNA racks, floor stacks and drive-in racks and sets the lift of AGV forklifts, with the same rules as the editor: changing a storage's type converts it as the panel does, and its initial stock is laid out again from the back.

If you edit the project while the assistant works, the proposal must be updated before applying. Invalid editor fields are made reachable and block application. Checks cover the complete result statically: geometry, references, variables, roles, fleets and reachability. Behaviour still needs to be tested in simulation. The assistant does not start runs, interpret CAD images or control real equipment.

The panel selector reopens conversations; + starts a new one and the trash button deletes the selected conversation without undoing applied changes. History is separate from .sim files: the first save associates it with the project, while Save as creates a new association. Deleting the project or account also deletes associated history. A draft retains its association through browser draft recovery. Hosted conversations count towards the 200 MB account quota; this quota does not apply locally. Individual conversation limits remain active in both modes.

Stop interrupts the request; reloading the page or restarting the server never automatically repeats paid calls. During the beta the app sets no daily request or token limit: anyone with AI enabled can use it freely. One request is active per account and two globally, with at most 8 model calls and 120 seconds per request. The panel shows the requests and tokens used in the current UTC day; a conservative amount is reserved before each call and replaced by the confirmed usage, and if the provider does not confirm usage the reservation remains counted. Your message and the necessary context from the open project, including unsaved changes, are sent to OpenAI; CAD backgrounds, credentials and legacy actions are excluded. See the privacy notice.

Next to Send, the AI model selector offers Sol and Luna. Your choice applies to the next request, survives workspace switches and is restored from a conversation when you reopen it. Both models have the same operations and checks; quotas are shared. Model access depends on the operator's API key: an error does not automatically switch to the other model.

Actual shows input and output tokens confirmed by OpenAI, including reasoning and cached input. Reserved shows the conservative budget for calls in progress or without confirmed usage: the reservation is replaced with actual usage when a response includes usage data. Errors, interruptions and restarts do not erase uncertain reservations. Old mixed counters appear as Previous total, without guessing their breakdown; all three amounts count towards the daily limit. They are not a balance in euros. The agent loads only the capabilities it needs and can batch creation, connections and presentation while preserving checks on the complete result.

When to use it

  • Several production lines with different rhythms and stations.
  • A transport that must start when another one is delivered (chained moves).
  • A source that must be served again only once it is empty (cyclic replenishment).
  • Orders that depend on the state of the plant: free AGVs, queued missions, a stock counter.

If a fixed interval between orders is enough, stay with the periodic generator in Orders.

Sequences, blocks and connections

A diagram is made of blocks joined by connections. A trigger block (Start, Periodic timer, Production profile, On station drop-off, On pickup completed, Cyclic mission) creates a sequence: an independent token that travels from block to block along the connections, waits where a block tells it to wait, and ends at End sequence or at an unconnected Continue output.

  • Each output has at most one connection, to the next block's input. Port sides automatically follow the arrangement of the blocks.
  • An unconnected Continue output ends the sequence like End sequence, and its port says so. Both outputs of Condition, Probability and Repeat must be connected: use End sequence to finish a branch. A start that is not connected is an issue to fix, because on its own it creates no orders; Cyclic mission creates its transports by itself and needs nothing after it.
  • Many sequences can run at the same time, even through the same blocks. Several connections entering one block do not synchronise sequences.
  • Variables are shared by all sequences and start at the initial value set in their definition block.
  • Time only advances with the simulation: every duration is in simulated seconds.

Block reference

Triggers

BlockSettingsBehaviour
▶ Start—Starts one sequence at time zero.
◷ Periodic timerInterval (s), First start after (s)Starts a new sequence at each interval, even if the previous one is still running.
Production profileNormal rate; optional peaks with a start delay, duration and rateStarts sequences continuously at the normal rate. Each peak replaces that rate temporarily, then normal production resumes. Queues and existing sequences continue.
↧ On station drop-offDrop-offs to observe, Drop-offs per startStarts a sequence each time any AGV completes an unload at one of the selected stations. Arrivals, pickups and parking returns do not trigger it. With Drop-offs per start above 1 it starts a sequence every N drop-offs; each station counts its own.
↥ On pickup completedPickups to observe, Pickups per startStarts a sequence when any AGV finishes loading at a selected Pick station. Delivery may still be in progress. Connect Wait to delay the next mission. With Pickups per start above 1 it starts a sequence every N pickups of each station.
↻ Cyclic missionBlock pickups, Block drop-offs, Delay while source is free (s)For each selected source with no pending or active mission (from any block), waits the delay and generates a transport to a reachable drop-off (drop-offs rotate). Repeats by itself.

Flow and conditions

BlockSettingsBehaviour
◴ WaitDuration (s)Holds the sequence for a production or processing time.
⊣ PrerequisiteCheck, Comparison, ValueHolds the sequence until the condition is true. It does not reserve AGVs or resources.
◇ ConditionCheck, Comparison, ValueEvaluates the condition once and continues on the Yes or No output.
↺ RepeatRepetitionsSends the sequence along the Repeat output the number of times set, then along Done. Connect the last block of the branch back to Repeat: each sequence counts on its own and, once it has left on Done, starts again from zero if it comes back. The editor warns when the branch does not return to the block.
% ProbabilityProbability of Yes (%)Continues on Yes with the probability set, otherwise on No. Draws follow the run's random seed, so the same run repeats them.
◑ Time windowFrom, ToHolds the sequence until the simulated time of day is within the window, every day. The run starts at 00:00; a window such as 22:00–06:00 runs past midnight, for night shifts.
# Update variableVariable, Operation (Set / Increment), ValueSelects a variable defined in the diagram. Integers can be set or incremented, including by negative amounts; Booleans can be set to True or False.
■ End sequence—Ends this sequence. Other sequences and vehicles continue.

Plant variables

Add one Plant variable block for each shared variable. It is independent of the sequence and has no ports or connections. Set a unique name, choose Integer or Boolean, and enter the initial value. The variable returns to that value at the start of a run and after Reset. Names can contain up to 40 characters: letters, numbers, spaces and underscores.

Update variable, Prerequisite and Condition show the defined names in the Variable menu. Prerequisite and Condition can also check Free AGVs, Pending missions, Active missions and Completed missions. Integers support ≥, ≤, =, > and <; Booleans support = and ≠ with True or False. A duplicate name or a reference to a deleted variable prevents a run until corrected.

Diagrams saved before this feature automatically receive a definition block for each name already used, with an initial value of 0. Earlier counters may keep decimal increments as Number (compatibility); new variables are Integer or Boolean.

Missions

BlockSettingsBehaviour
⇢ Generate missionBlock pickups, Block drop-offs, Quantity, Pickup at the starting station, Wait until deliveredEach time a sequence passes, queues the transports set in Quantity (1 by default), rotating through the reachable pickup/drop-off pairs. The allocator chooses the AGV. With Pickup at the starting station the pickup is the station that started the sequence (On station drop-off or On pickup completed) instead of the block pickups, so one sequence serves several stations. With Wait until delivered the sequence goes on only once every order of that pass is delivered, without a Wait for delivery block.
⚄ Random missionBlock pickups, Block drop-offs, Quantity, Pickup at the starting station, Wait until deliveredGenerates the orders set in Quantity; for each, a random pickup with at least one reachable drop-off, then a random reachable drop-off. The same pair can repeat. Both options work as in Generate mission; with the pickup at the starting station only the drop-off is random.
✓ Wait for deliveryWait for: Last mission / All missionsWith Last mission it waits until the last mission generated by this sequence has been unloaded; with All missions it waits for every mission the sequence generated since its previous wait, for example all the orders of a block with Quantity above 1. It needs a mission block before it on every incoming branch.

Fleet and the AGV selection rule stay in Simulate›Scenario; speeds and pickup and drop-off times belong to each fleet, in Simulate›Vehicles.

Normal production and peaks

Add Production profile from When and connect it to the work it should start: Generate mission, Random mission, Store or Retrieve. Each profile controls its own flow in starts per hour. Every start creates a sequence; directly connected to Generate mission, it creates one mission per start. It does not set the fleet size.

Worked example: line supply, from 60 to 120 missions/hour

Goal: two hours of normal demand, a 30-minute peak, then a return to normal. Start with a layout containing a pickup station and a drop-off station connected by a route the AGVs can use, with a ready fleet in Simulate›Scenario.

  1. Add the blocks. In Plant logic, add Production profile from When, then Generate mission and End sequence from Transport. For an existing flow, replace its Periodic timer or Start: leaving the old trigger connected adds more demand.
  2. Connect them in order. Click the profile's Continue output and the Generate mission input; then connect Generate mission's Continue output to End sequence. No return connection is needed: the profile already starts new sequences at the configured rate.
  3. Choose the transport. Select Generate mission and choose the pickup and drop-off stations. Select the profile and name it Line supply, to identify it in the results.
  4. Set demand. Enter the values in the following table, already proposed for a new profile. Confirm each number with Enter or by leaving the field. Under Advanced, leave Repeat peaks daily off.
  5. Enable and save. Set Order generation to Plant logic, check for Valid workflow and press Save.
  6. Run the test. Open Simulate, choose 4 h for the duration and press Start run. You will have an hour and a half after the peak to observe recovery.
Line supply · Production profileGenerate missionEnd sequence

Each start of this diagram creates one mission. End sequence closes the block sequence: the queued mission continues until delivery. You can insert Wait for delivery before End sequence to keep the sequence open until delivery; the profile will still start other sequences.

SettingValueMeaning
Normal rate60 starts/hContinuous production outside peaks.
Start after (min)120The peak begins two simulated hours after the run starts.
Duration (min)30The peak ends at simulated time 02:30.
Rate during peak120 starts/hReplaces the normal rate during the peak; it is not added to it.
Simulated timeFlow demandWhat to observe
00:00–02:0060 missions/hour: one every 60 secondsThe queue under normal demand.
02:00–02:30120 missions/hour: one every 30 secondsWhether the queue grows under stress.
02:30–04:0060 missions/hour: one every 60 secondsWhether and when the queue returns to its pre-peak level.

Read recovery. Open Results›Timeline: the queue and throughput charts highlight the peak and the legend names Line supply. At 02:30 the normal rate resumes without clearing the queue or interrupting missions. A falling queue means the fleet is clearing the backlog while new orders arrive; a queue that is still high at 04:00 has not recovered within the chosen duration. If the queue does not grow during the peak, the system may already handle that load. Throughput measures deliveries over the trailing hour: it need not jump to 120 as soon as the peak starts. The configured rates describe demand, not a guaranteed delivery rate.

Compare two tests. To compare two fleet sizes, keep the profile, four-hour duration and Simulate›Scenario›Randomness›Seed unchanged (for example, 12345), then use Run comparison. The same seed reproduces the same scenario; changing the fleet can change the order of random draws.

Add peak adds an optional peak, up to 24. Starts and durations are whole simulated minutes; durations must be positive and peaks must not overlap. A peak's rate must be higher than the normal rate and at most 3600 starts/h; decimal rates are accepted. Removing every peak leaves the normal rate. Set the normal rate to zero when this flow should work only during peaks.

Minutes are counted from the run start, not the computer's clock. Peaks initially happen once and can be later than 24 hours into the run. In Advanced, Repeat peaks daily repeats them every 24 simulated hours and requires every peak to fit within that day. Normal production continues between and after peaks in either mode.

Within a constant-rate interval, starts are evenly spaced; the new interval starts at a peak boundary and its end is exclusive. Add conditions or prerequisites downstream when the flow should also react to queues or stock. If demand reaches the diagram's technical limit of 500 sequences or 1000 pending orders, the run stops with an explicit error and keeps its partial results. It does not silently discard starts and present a saturated run as complete.

Using the editor

  1. Open the workspace. Click Plant logic in the header. An empty diagram offers Start from an example.
  2. Add blocks. Drag a block from the Blocks palette onto the diagram, or click it to add it.
  3. Connect. Click a block's output port, labelled Continue, Yes or No, then the next block's input. Esc or Cancel connection aborts. Inputs and outputs orient automatically after connecting, while moving blocks and while drawing a connection: a block placed below the previous one, in the same column, receives its connection from above and the output leaves from the bottom; on a return row, the input can be on the right and outputs on the left. With several inputs, connections from nearby rows carry more weight; ties consider outputs, then default to left-to-right. Connections go around the blocks they would cross.
  4. Add from an output. Hover an output, or reach it with Tab: a fan opens with the blocks that usually follow that block and, where possible, returns (Back to …) to earlier blocks of the same sequence, offered only when the loop passes through a block that takes time. The chosen block appears beside the output, already connected; if the output was connected, it goes in between. Esc closes the fan.
  5. Configure. Select a block to edit its name and settings in Block properties. Station lists show only stations with the right role.
  6. Check. The status line reports Valid workflow or the number of issues to fix before starting; each issue names the block concerned.
  7. Enable. Set Order generation to Plant logic. While it is off, the diagram is a draft and the periodic generator is used.
ActionHow
Zoom / panWheel to zoom, middle button to pan; Fit frames the diagram
Select several blocksDrag a rectangle with the left button; Shift/Ctrl+click adds or removes a block
Move a groupDrag one of the selected blocks
Follow a sequenceSelect a block or a connection: its sequence, from the start to the end, and the variables it uses stay highlighted while the rest fades. Selecting a Plant variable highlights the blocks that use it
ArrangeArrange lays the diagram out left to right, one step per column: variables at the top, then the sequences in the order they appear, with the other branch of a decision on the row below and returns left out of the steps. Short sequences sit side by side and unconnected blocks go to the bottom. Ctrl+Z restores the previous layout
SimplifyIn the status line, the list of possible simplifications offers shorter forms that behave the same: cyclic missions that differ only in their pickup, a Condition with a Wait looping back (a Prerequisite), sequences copied for each starting station, identical starts with one mission each (one mission with Quantity), a Wait for delivery right after the block whose orders it waits for. The message frames the blocks and Apply merges them in one undoable step; names that differ between the copies are cleared
Copy / pasteCtrl+C copies blocks with their internal connections; Ctrl+V pastes them beside the existing ones
DeleteSelect a block or a connection and press Delete, or use the delete button in its properties

Changes to the diagram restart the simulation from zero and are saved in the project with Save. The diagram supports undo and redo like the rest of the project.

Watching it run

While the simulation runs, each block shows how many sequences are currently in it and how many have passed through. The status line shows whether the logic is Running or Ready / paused, the number of active and completed sequences and any warnings. Generated orders name the block that created them, for example M12 (3 → 7) from “Line A”.

If the logic hits a runtime problem, such as a loop with no waiting time, Simulate shows an error: open Plant logic, fix the diagram or press Reset.

Common patterns

Production line with a queue limit (the built-in example)

Periodic timer60 sPrerequisitepending ≤ 5Generate missionWait for deliveryWait10 sEnd sequence

Every minute a sequence starts, waits until no more than five missions are pending, generates a transport and waits for it to be delivered before a 10 s processing time.

Chained transports

On station drop-offstation 1Generate mission1 → 2End sequence

Every time something is unloaded at station 1, a new transport from 1 to 2 is created. Station 1 needs both Pickup and Drop roles, and the first delivery to it must come from another sequence of the diagram.

Request another pickup after loading

On pickup completedstation 1Wait30 s, optionalGenerate missionPick 1 → Drop 2End sequence

Under When, add On pickup completed and select Pick station 1 in Pickups to observe. Every completed load starts a sequence: after the Wait, a new transport is queued from the same source, even while the previous AGV is still delivering. Without Wait, the order is queued immediately. Arrival, loading start, failed attempts and unloading do not trigger this block.

Seed the first mission with a separate Start → Generate mission (1 → 2) → End sequence. An event block alone waits for a pickup. Every observed station starts the same sequence: to regenerate the mission from the station that started it, observe them all in one block and tick Pickup at the starting station in Generate mission. Set Order generation to Plant logic.

Serve a source whenever it is free

Cyclic missionpickup 1, drop-off 2, delay 30 sEnd sequence

A transport from 1 starts 30 s after the source has no mission pending or active. No timer or loop connection is needed.

Random demand when a vehicle is free

Periodic timer45 sConditionfree AGVs ≥ 1Random missionEnd sequence

Connect the No output of the Condition to a second End sequence. Random choices use the scenario seed: reuse it to repeat this scenario, or choose different seeds to study variability.

Moving a batch of pallets and waiting for it

StartTransfer30 · K01 → D01, D02 · in turnWait for deliveryallTransfer30 · D01, D02 → K02 · in turnWait for deliveryallEnd sequence

Quantity queues every order of the batch at once, and the AGVs take them as lanes come free. With In turn the orders alternate between the selected warehouses, one each, so 30 transfers to D01 and D02 become 15 per drive-in. Wait for delivery with All missions starts the next batch only once this one is finished. No variables, counters or conditions are needed.

A counted loop

StartRepeat10 timesGenerate missionWait for deliveryWait20 sback to Repeat; Done → End sequence

To repeat a job an exact number of times, one after another, connect the Repeat branch to the job and its last block back to Repeat; the Done output continues after the last repetition. For independent orders, Quantity is enough.

A serial loop

StartGenerate missionWait for deliveryWait20 sback to Generate mission

A Periodic timer can start overlapping sequences. For strictly one-after-another work, use Start and connect the last Wait back to the first work block. Always put a Wait in the return connection: a loop with no waiting time is stopped as an instant loop.

More complete studies built on these patterns are in the Scenario cookbook.

Store and retrieve

Store selects the fastest available empty cell; Retrieve selects the fastest available pallet. Configure an exchange station (Pick for Store, Drop for Retrieve) and the permitted aisles. Transfer moves a pallet from one of the From warehouses to one of the To warehouses in the same trip. Connect these blocks to timers, conditions and Wait for delivery. When the warehouse is full/empty the sequence keeps its request pending without taking an AGV or aisle. Wait for delivery resumes only after that mission completes, including the deposit's exit route.

All three have Quantity, the orders generated each time a sequence passes. With several warehouses selected, Distribution chooses how to use them: Fastest takes the quickest place among all of them for each order; In turn alternates the warehouses of the list, one order each (in a transfer both the source and the destination, when they have more than one). In turn, an order waits for its warehouse even if another one has room.

Conditions and prerequisites offer Empty cells, Occupied cells, Available empty cells and Available pallets. Available excludes reservations; empty/occupied counts describe committed stock in usable cells. Choose the warehouses to count, for example only K01 to continue once it is empty; with none chosen, all of them count. With workflow enabled, all periodic generators, including warehouse flows, are replaced by the diagram.

Store, Retrieve and Transfer also have Wait until delivered. Stock replenishment keeps a storage stocked without timers or conditions: when its pallets, counting those already on their way or waiting for a place and leaving out those being retrieved, fall below Reorder below (pallets), it brings them back to the level chosen in Fill up to (Full or A level). Pallets come says where from: From a station, by AGV orders from the exchange station the stores the AGVs carry out; From outside, without AGVs is for example a truck unloaded by its own means: after the Arrival time (s) the pallets enter the free places by themselves, lane by lane in their fill order and never in a lane an AGV is working in, and those that find no place wait for one. Minimum interval (s) spaces two reorders, for example one truck every 30 minutes at most. It works with racks, floor stacks and drive-ins; it repeats by itself and its optional output goes on at each reorder with the orders it issued, or when the pallets from outside arrive. Results count the pallets received from outside separately.

Limits

  • 200 blocks and 400 connections per diagram.
  • 500 running sequences and 1000 pending orders: saturation interrupts the run with an error and preserves partial results.
  • 200 instantaneous transitions per simulation step.