[Request?] Add an option to prevent multiple cargo requests in a single schedule

Adds new train stops forming a highly configurable logistic network.

Moderator: Optera

Post Reply
Arie Atari
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sat Dec 03, 2022 10:27 pm
Contact:

[Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Arie Atari »

Hi, I'm playing an Pyanodon run where i use a single station to request and deliver multiple items. This works fine in Py since quantities of a single item are relatively low, but the number of different items is very high.

Sometimes 2 items are requested at once from a station and combined in a single LTN schedule. This almost always ends up in a lot of one item and none of the other item in the cargo wagon, while waiting indefinitely for the second item request to complete. I therefore have to keep an eye on all the trains every few minutes to prevent a complete deadlock.

If there was a setting in LTN to prevent the request of multiple items in a single schedule then this problem would not exist for my LTN setup. I hope this setting can be added to the mod settings of LTN to make the mod even greater than it already is!
Attachments
Constant combinator settings
Constant combinator settings
Constant combinator settings.JPG (31.81 KiB) Viewed 1066 times
Station overview
Station overview
Station overview.JPG (153.21 KiB) Viewed 1066 times
Train schedule with multiple item requests in a single schedule
Train schedule with multiple item requests in a single schedule
LTN Schedule.JPG (60.57 KiB) Viewed 1066 times

User avatar
Optera
Smart Inserter
Smart Inserter
Posts: 2916
Joined: Sat Jun 11, 2016 6:41 am
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Optera »

The whole point of LTN is to combine requests.
If you don't want that use Providers and/or Requesters dedicated to one type of freight.

Arie Atari
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sat Dec 03, 2022 10:27 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Arie Atari »

I agree with you for a vanilla play or maybe a light overhaul mod play, but it's almost impossible in Py to build a separate station for each different item, since some recipes require 8 to 10 (or more) different items. That's why i see a usecase for my question when using LTN with Py.

My base consists of 37 trains and 120 stations, plus 30 depot stations. Each station can handle up to 8 different resources. I think i would need at least 500 stations when i would build a separate station for each different item. Even though space is unlimited, it would be impractical for me to build that many stations.

I just noticed you're the creator of the LTN mod and you have already created a post with designs of LTN stations. I haven't had the time yet to read the full thread, but i'll dive into it and maybe post my Py setup there. Hopefully this thread may give me some new ideas.

Thanx for your reply.

Arie Atari
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sat Dec 03, 2022 10:27 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Arie Atari »

I can't figure it out: if LTN is designed to combine requests, why don't the inserters switch from loading the first item (at >= condition, 480 in the example in my screenshot) to the second/third item? I guess since the condition is still met when above 480 (load >=item count, instead of load = item count), but what would then be the trigger to switch the filter type for the inserter? Is my wiring not correct? I added an arithmetic combinator like the Optera Provider station blueprint, but that didn't help. I'm a bit desperate now, since i have to spend about 20% of my time checking and correcting the train network, which i could better spend at building.

User avatar
Nosferatu
Fast Inserter
Fast Inserter
Posts: 228
Joined: Fri Jan 20, 2017 4:48 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Nosferatu »

Is the train station set to "read train content" ?
What signals do your inserts get when the loading malfunctions? (Connect wire to electric pole and read the signal there)

Arie Atari
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sat Dec 03, 2022 10:27 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Arie Atari »

The train station itself is not connected. The constant combinator is connected to the input (lamp) with red wire, the inserters are connected to the output with green wire. In my attempt to use an arithmetric combinator i did use the station itself and it was only set to "read train content". Didn't help though.

I use this setup for all my stations (183 atm). A few screenshots below:
Signals output via electric pole
Signals output via electric pole
Scr-LTN-01.png (1.81 MiB) Viewed 838 times
Train loading status. At this moment the train is loaded with 2.3k gravel and still loading
Train loading status. At this moment the train is loaded with 2.3k gravel and still loading
Scr-LTN-02.png (72.5 KiB) Viewed 838 times
The content of the warehouse. No gravel present at this moment, the gravel from the yellow belts gets immediately loaded into the train
The content of the warehouse. No gravel present at this moment, the gravel from the yellow belts gets immediately loaded into the train
Scr-LTN-03.png (1.86 MiB) Viewed 838 times
Close-up of the wiring
Close-up of the wiring
Scr-LTN-04.png (1.22 MiB) Viewed 838 times
Content of the constant combinator
Content of the constant combinator
Scr-LTN-05.png (32.73 KiB) Viewed 838 times

User avatar
Nosferatu
Fast Inserter
Fast Inserter
Posts: 228
Joined: Fri Jan 20, 2017 4:48 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Nosferatu »

Arie Atari wrote:
Sat Nov 11, 2023 2:00 pm
...he inserters are connected to the output with green wire.
That's step one - the output sends the "Expected train inventory after un-/loading is complete. "
So in your example it sends 1000 gravel and 1000 whatever that black thing is

Now we need to subtract from that signal what the train has loaded.

Connect the trains station to the arithmetric combinator witch should be set to *-1 like you had it before.
The output from this should be connected to the electric pole.

When the train has loaded enough that should make the signal zero or minus and then the filter inserters will stop loading that material.

Arie Atari
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sat Dec 03, 2022 10:27 pm
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by Arie Atari »

Yes, it's working! Your explanation gives me a better insight in the mechanics too.
Thank you very much for your help!

Btw the black thing is Tailings dust, one of the many (side) products in Pyanodon.

mrvn
Smart Inserter
Smart Inserter
Posts: 5709
Joined: Mon Sep 05, 2016 9:10 am
Contact:

Re: [Request?] Add an option to prevent multiple cargo requests in a single schedule

Post by mrvn »

In your station you have to set locked slots at the LTN stop. Because if the schedule asks for a full train split into 2 items and you load even 1 item of one kind to much then you won't have space to load enough of the second item and the train doesn't leave.

But locked slots are wastefull. You need to set the locked slots to the number of items the station provides. More if the stacksize is small. This reduces the cargo size of the train. I usually go with using just 5 stack filter inserters to load the cargo wagon and then at the sixth position have one filter inserter with stacksize override = 1 that unloads any excess items. That needs a second arithmetic combinator to compute the excess items.

Alternatively you can use more complex combinator constructions to load the extact number of items in the first place. But that is much trickier then unloading the small excess the trivial setup loads.

Post Reply

Return to “Logistic Train Network”