I have requestor chests in my main base. I have a secondary base that needs item from the main base. When the secondary base is low on necessary items, I need it to send a signal to the main base, set the items for requestor chest, and send a train to go pick up the resources.
Can someone help me create this setup?
Automate Train requests
Re: Automate Train requests
Ok. The easiest way I know of to set this up is a little bit complicated, but it works. I’ve done this for defense trains, and for nuclear building trains. Basically, what I’m suggesting is trains dedicated to carrying everything these outposts may need, that are kept at your main base until the outpost needs them, then they run off to deliver.
Step 1 : Set up the train.
At most 12 different types of item per Cargo Wagon. At your main base, set up the track, train station, locomotive(s), and cargo wagon(s). Set up fuel for the Locomotives. Starting with the first cargo wagon, decide how many stacks you want of each item the cargo wagon is to carry. The Middle Mouse Button is your friend, use it to lock each slot to the specific item you want carried. Any empty slots (slots you are not going to use, either due to the 12 item type limit or just due to lack of need) should be blocked off by using the X. Using Requestor Chests and Stack Inserters, fill the Cargo Wagon. Repeat this process for all the Cargo Wagons that you need to use. Set the train to wait at this station until Full Cargo.
Step 2 : Set up the outpost.
At the outpost, set up the reverse of the train station : leaving a gap in the track before the station (so your train does not show up unexpectedly) place the station, Stack Filter Inserters taking stuff out of the cargo wagons and into Passive Provider chests. Wire up ALL the chests together. Connect a Constant Combinator to them, and the Train Station itself. Set the Constant Combinator (you may need more than one if you have too many item types) to output the negative number of the items you want. For example, if you want 1 stack of Repair Packs, set the Constant Combinator to output -100. Set the Train Station to turn on whenever Anything < 0. Lock the unnecessary slots in each Passive Provider. If you want 2 stacks of Walls, you only want 2 slots open in that chest, lest the call for something else have their Passive Provider overflowing with Walls. Set the train for 5 seconds of inactivity at this station, then complete the track.
What this does is sums the contents of all the chests. It then adds the Constant Combinator’s negative amount to that. So if you have -100 Repair Packs in the CC, and only have 25 in a chest, the overall signal sent to the Train Station is -75. If you have 120 Repair Packs in all the chests, 25 is sent to the Train station. Whenever anything is less than 0, is -1 or lower, the station comes on and the train brings everything it has. Slot limits on the chests prevent overloading the receiving station, And you wind up refilling to what you want.
Personally, I tend to give the Passive Providers an extra slot or two; that slot or two per chest provides a small buffer so the train is not called just because one or two items were taken.
Step 1 : Set up the train.
At most 12 different types of item per Cargo Wagon. At your main base, set up the track, train station, locomotive(s), and cargo wagon(s). Set up fuel for the Locomotives. Starting with the first cargo wagon, decide how many stacks you want of each item the cargo wagon is to carry. The Middle Mouse Button is your friend, use it to lock each slot to the specific item you want carried. Any empty slots (slots you are not going to use, either due to the 12 item type limit or just due to lack of need) should be blocked off by using the X. Using Requestor Chests and Stack Inserters, fill the Cargo Wagon. Repeat this process for all the Cargo Wagons that you need to use. Set the train to wait at this station until Full Cargo.
Step 2 : Set up the outpost.
At the outpost, set up the reverse of the train station : leaving a gap in the track before the station (so your train does not show up unexpectedly) place the station, Stack Filter Inserters taking stuff out of the cargo wagons and into Passive Provider chests. Wire up ALL the chests together. Connect a Constant Combinator to them, and the Train Station itself. Set the Constant Combinator (you may need more than one if you have too many item types) to output the negative number of the items you want. For example, if you want 1 stack of Repair Packs, set the Constant Combinator to output -100. Set the Train Station to turn on whenever Anything < 0. Lock the unnecessary slots in each Passive Provider. If you want 2 stacks of Walls, you only want 2 slots open in that chest, lest the call for something else have their Passive Provider overflowing with Walls. Set the train for 5 seconds of inactivity at this station, then complete the track.
What this does is sums the contents of all the chests. It then adds the Constant Combinator’s negative amount to that. So if you have -100 Repair Packs in the CC, and only have 25 in a chest, the overall signal sent to the Train Station is -75. If you have 120 Repair Packs in all the chests, 25 is sent to the Train station. Whenever anything is less than 0, is -1 or lower, the station comes on and the train brings everything it has. Slot limits on the chests prevent overloading the receiving station, And you wind up refilling to what you want.
Personally, I tend to give the Passive Providers an extra slot or two; that slot or two per chest provides a small buffer so the train is not called just because one or two items were taken.
-
- Filter Inserter
- Posts: 291
- Joined: Tue Jan 29, 2019 4:00 am
- Contact:
Re: Automate Train requests
Just to add to this, another addition could be to use only 1 or 2 provider chests per wagon, and wire up the filter inserters to get instructions based on the demand. The unload will be a little slower, but it saves having almost-empty multiple chests sitting around. If you're not adverse to a little plagiarism, for more ideas around this, KatherineOfSky has a good "wall repair station" tutorial.astroshak wrote: Fri Apr 03, 2020 9:45 am *snip*
At the outpost, set up the reverse of the train station : leaving a gap in the track before the station (so your train does not show up unexpectedly) place the station, Stack Filter Inserters taking stuff out of the cargo wagons and into Passive Provider chests. Wire up ALL the chests together. Connect a Constant Combinator to them, and the Train Station itself. Set the Constant Combinator (you may need more than one if you have too many item types) to output the negative number of the items you want. For example, if you want 1 stack of Repair Packs, set the Constant Combinator to output -100. Set the Train Station to turn on whenever Anything < 0. Lock the unnecessary slots in each Passive Provider. If you want 2 stacks of Walls, you only want 2 slots open in that chest, lest the call for something else have their Passive Provider overflowing with Walls. Set the train for 5 seconds of inactivity at this station, then complete the track.
*snip*
Re: Automate Train requests
That idea calls for a few modifications to what I’d posted above. This is mainly because, I believe, you need positive numbers going to the Filter Inserters to make them work.
Instead of wiring the chests to the train station, wire them to an Arithmetic Combinator. That AC should be set for Everything * -1, Everything.
Wire the output of that AC to the Filter Inserters, using the Set Filters option. Set the Constant Combinator to the actual numbers you want (if you want 100 Walls, above you set it for -100 Walls; now, you set it for that 100 Walls). Wire the output of the AC to the CC and to the Train Station. Set the Train station to enable when Anything > 0.
In theory this will call for a train by enabling the station whenever anything drops below the desired amount. And only the stuff you want will be offloaded. I’ve personally had some less-than-stellar luck with this particular setup, which is why I recommend the setup I initially posted.
Instead of wiring the chests to the train station, wire them to an Arithmetic Combinator. That AC should be set for Everything * -1, Everything.
Wire the output of that AC to the Filter Inserters, using the Set Filters option. Set the Constant Combinator to the actual numbers you want (if you want 100 Walls, above you set it for -100 Walls; now, you set it for that 100 Walls). Wire the output of the AC to the CC and to the Train Station. Set the Train station to enable when Anything > 0.
In theory this will call for a train by enabling the station whenever anything drops below the desired amount. And only the stuff you want will be offloaded. I’ve personally had some less-than-stellar luck with this particular setup, which is why I recommend the setup I initially posted.
-
- Filter Inserter
- Posts: 291
- Joined: Tue Jan 29, 2019 4:00 am
- Contact:
Re: Automate Train requests
Thanks for clarifying that point about the negative/positive numbers, @astroshak. Yes, that arrangement does require the extra arithmetic combinator, as you describe. I've just made these often enough that it's just habit, and I forget some of the little details.