Balancing >2 chests/warehouses (w. combinators)?

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Bushdoctor
Fast Inserter
Fast Inserter
Posts: 183
Joined: Sun Feb 21, 2016 6:33 pm
Contact:

Balancing >2 chests/warehouses (w. combinators)?

Post by Bushdoctor »

Good day,

A long time ago this community provided me with the means to balance between chests and warehouses, and sofar it has worked really well.
This happens to be an LTN requester-station, but as you can see it also includes the 'balancer', probably familiar to a lot of people.

Image

My question is: How can I make this work for a station with 4 warehouses instead of 2?
I tried simply chaining the above setup (which resulted in 3 combinators), but that didn't work.
-Then again, I know nothing about combinators, so I wouldn't know if I should have changed settings or something.

Can this be done, balancing 4 warehouses/chests in a similar way as the above screenshot?
Thanks.
mmmPI
Smart Inserter
Smart Inserter
Posts: 3643
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Balancing >2 chests/warehouses (w. combinators)?

Post by mmmPI »

There are 2 differents problems : 1) balancing the warehouse 2) sum up the quantity for LTN.

(are the filter inserters all in the same direction or 50%/50% ? )

If you only focus on 1), you can get rid of the green wire that is used only for 2), in this case you are left with a setup with only red wire. i think the setup would work if you alternate a version with red wire and a version with green wire, when you copy paste

W-R-W-G-W-R-W

Where W-R-W represent what is on the picture, and W-G-W the same with green wire instead of red.

This would allow to balance the warehouse 2 by 2, which should end up as equalizing them , directing material to one side for that if the inserters are all in the same direction.



Now the 2) part is a way to sum up the quantity of the "W" all the warehouses in W1-R-W2-G-W3-R-W4 .

The only thing i could came up with is a hack, the total quantity in the station should be calculated doing W1+W2+W3+W4, but W2 and W3 are already using 2 color of wire just to balance.

In theory : W1=W2=W3=W4, so maybe doing (W1+W4)*2 will be close enough . This mean only adding the sum of the first and last warehouse times 2 and hoping it still function as an equivalent.

Hopefully W1 and W4 are only using red wire. So you'd just need to use a green wire to link the first and the last warehouse. This green wire you extend in an arithmetic combinator input setup exactly like the one in the screenshot but with "2" instead of "-1".

And you connect the output as to the station/lamp as it is done already.

Hopefully that is working/correctly explained, if you provide a save-file with your modpack and the setup you show i'll try and build it.

Also someone may come with better answer i'd be curious.
mmmPI
Smart Inserter
Smart Inserter
Posts: 3643
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Balancing >2 chests/warehouses (w. combinators)?

Post by mmmPI »

DaveMcW wrote: Tue Jul 30, 2019 12:00 am viewtopic.php?f=18&t=72289
That's way better, there is one wire color for all the warehouse, that allow for a real sum for the LTN station.
Bushdoctor
Fast Inserter
Fast Inserter
Posts: 183
Joined: Sun Feb 21, 2016 6:33 pm
Contact:

Re: Balancing >2 chests/warehouses (w. combinators)?

Post by Bushdoctor »

@mmmPI
Thanks for explaining all that! I understand what you mean, and because of that, I'm going to give it a shot.

@DaveMcW
Thanks for posting that link! It's probably the better solution, but I gotta give mmmPI's idea a shot because it's a more familiar setup for me.
Good to have a (probably) working solution at hand!

Thank you very much gents!
mmmPI
Smart Inserter
Smart Inserter
Posts: 3643
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Balancing >2 chests/warehouses (w. combinators)?

Post by mmmPI »

Bushdoctor wrote: Tue Jul 30, 2019 8:00 pm @mmmPI
Thanks for explaining all that! I understand what you mean, and because of that, I'm going to give it a shot.

@DaveMcW
Thanks for posting that link! It's probably the better solution, but I gotta give mmmPI's idea a shot because it's a more familiar setup for me.
Good to have a (probably) working solution at hand!

Thank you very much gents!
If mine doesn't function at least you got another one that WILL :)

I offered to try and build one myself i had in mind also looking in the modpack at stuff that would change the inserter vs belt/loader speed, to make sure the inserter can keep W1=W2=W3=W4 almost true, and not create huge unbalance, if you try to unload too many belts from the warehouse W1, then the inserter will lag behind, and the LTN request can trigger too early since the hack i proposed doesn't calculate the real sum.
Bushdoctor
Fast Inserter
Fast Inserter
Posts: 183
Joined: Sun Feb 21, 2016 6:33 pm
Contact:

Re: Balancing >2 chests/warehouses (w. combinators)?

Post by Bushdoctor »

@mmmPI
It worked like a charm!
Those white inserters are usually able to keep up later in the game, but you're right and I decided to read only the contents of W1 and base my LTN orders on that. (Just because it was easier, not because I was smart)
I think that's gonna work... Haven't actually tested deliveries yet, but the balancing works great.
Thanks again!
Post Reply

Return to “Gameplay Help”