Combinator Q: how to count inserter throughput

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
vanatteveldt
Filter Inserter
Filter Inserter
Posts: 947
Joined: Wed Nov 25, 2015 11:44 am
Contact:

Combinator Q: how to count inserter throughput

Post by vanatteveldt »

The reason for this post is stupid, I thought the wiki figure on stack inserter throughput was outdated but I simply confused belt->container with container->container throughput.

However, it prompted me to try to measure inserter throughput and I think I have room to learn about combinators :). This is what I came up with:

Image

the bottom constant combinator is the control set to output 1 red (the stop signal).
This is fed into the middle decider, which outputs green 1 IF red <= 0.
This is fed into the top decided, which is a counter set to output [green input count] IF [green > 0]. The red wire loops output back to input, creating the counter.
The green signal is also used to start the stack inserter [green > 0]

So, if I switch off the control stop signal, the stack inserter starts moving and the counter starts counting.

If the chest reaches 4800 items, the bottom decider outputs 1 red, stopping the counter. You can also stop the counter and inserter manually by re-activating the control combinator.

The top two arithmetic are really stupid, I use the top right to reset the counter by doing [each * -1 -> each] and feeding it back to the counter, then removing the wire again.
The top left I use to subtract 10k so I can see the actual figure.

The good news is that I get 10391 ticks to fill the chest, giving me a throughput of 4800 / 10391. * 3600 = 1663 which is within rounding error of the calculated value of 60*2.31*12. So the contraption works.

So my question to the combinator gurus: how can I do this better / easier / more efficiently?

blueprint

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3707
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Combinator Q: how to count inserter throughput

Post by DaveMcW »

Power switch: Copper plate (chest) < 4800
Inserter: Read hand contents pulse
Arithmetic combinator (memory loop): Copper plate (inserter) + 0 → Copper plate

vanatteveldt
Filter Inserter
Filter Inserter
Posts: 947
Joined: Wed Nov 25, 2015 11:44 am
Contact:

Re: Combinator Q: how to count inserter throughput

Post by vanatteveldt »

DaveMcW wrote:Power switch: Copper plate (chest) < 4800
Inserter: Read hand contents pulse
Arithmetic combinator (memory loop): Copper plate (inserter) + 0 → Copper plate
Sorry I'm probably dense here, wouldn't that count the amount of items transported rather than the time it took to transport X items?

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3707
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Combinator Q: how to count inserter throughput

Post by DaveMcW »

Er, right.

Power switch: Copper plate (chest) < 4800
Arithmetic combinator: T + 1 → T

Connect power to start the counter, deconstruct it to reset.

vanatteveldt
Filter Inserter
Filter Inserter
Posts: 947
Joined: Wed Nov 25, 2015 11:44 am
Contact:

Re: Combinator Q: how to count inserter throughput

Post by vanatteveldt »

DaveMcW wrote:Er, right.

Power switch: Copper plate (chest) < 4800
Arithmetic combinator: T + 1 → T

Connect power to start the counter, deconstruct it to reset.
Great thanks. Never thought of using the power switch as an on/off signal, much easier!

Post Reply

Return to “Gameplay Help”