[1.1.5] Train stop - inserter loading train although being disabled

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
mtfreitasf
Burner Inserter
Burner Inserter
Posts: 12
Joined: Sat Apr 27, 2019 12:38 pm
Contact:

[1.1.5] Train stop - inserter loading train although being disabled

Post by mtfreitasf »

I designed a train stop for my uranium mining. My sulfuric acid setup is far away and I bring it with barrels. So to remove items from this area, I designed the loading stop for two items (uranium and empty barrels). The uranium train is set up with filters in its cargo and is no problem. The barrel train can't be set up with filters because it arrives full with sulfuric acid barrels and loads with empty barrels.

So as not to load the barrel train with uranium I set up the following circuit network. The stop is connected to the inserters loading uranium. Then I set the condition that if the train with ID 220 (the barrel train) is in the station the uranium inserters are disabled. What happens is that when the train arrives, the inserters make one pass, loading a little bit of uranium, and the circuit network kicks in stopping them. The barrels load as expected.

I believe the solution would be to start loading the train after testing the Read stopped train condition in the circuit network.
Setup with barrel train with some uranium
Setup with barrel train with some uranium
Imagem1.jpg (228.66 KiB) Viewed 2535 times
Train stop circuit network - ID = T
Train stop circuit network - ID = T
Imagem2.jpg (152.71 KiB) Viewed 2535 times
Inserter network condition - Barrel train ID is 220
Inserter network condition - Barrel train ID is 220
Imagem3.jpg (253.54 KiB) Viewed 2535 times
Train cargo showing one pass of uranium
Train cargo showing one pass of uranium
Imagem4.jpg (188.32 KiB) Viewed 2535 times


mtfreitasf
Burner Inserter
Burner Inserter
Posts: 12
Joined: Sat Apr 27, 2019 12:38 pm
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by mtfreitasf »

Loewchen,

Thank you very much for your reply but I still believe there is an issue. From the link you provided I understood that the inserter still kept some itens in its hand, so, when the next train arrived (my barrel train), it would empty it. That is not the case - I tried two different methods. The first one, I ran the barrel train twice through the stop. In both runs, the uranium inserter loaded the train.

The second one, I used a green wire, and connected one inserter to an electric pole. I configured the inserter to read the hand and hold the signal. Then I ran the barrel train to the stop. Before entering the station, the inserter was empty. When the train stopped, some uranium was loaded into the inserter which loaded the train. After that, the circuit network kicked in and stopped loading uranium.

As I said in my first post, I believe that the circuit network is being calculated after the loading process is begun. believe the solution would be to start loading the train after testing the Read stopped train condition in the circuit network.

Thank you,

Marcos
Test setup with green wire and empty loading inserters
Test setup with green wire and empty loading inserters
Imagem5.jpg (178.32 KiB) Viewed 2488 times
P.S. I designed a solution (not so elegant) for this problem - one inserter empties the train of uranium
White inserter empties the train of uranium
White inserter empties the train of uranium
Imagem6.jpg (167.43 KiB) Viewed 2488 times

p4wana
Burner Inserter
Burner Inserter
Posts: 5
Joined: Mon Apr 01, 2019 7:19 am
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by p4wana »

The circuit network does not work instantaneously, but is updated in ticks. The behavior you describe can be explained by:

In tick 0 (before the train stops):
- the train station outputs T=0 (as no train is present)

In tick 1 (train just stopped):
- the train station outputs T=220
- the input at the inserter still is T=0, the inserter is active and grabs as many items as it can get

In tick 2:
- the train station outputs T=220
- the input at the inserter is T=220, but the inserter is already moving, current movement is not cancelled by change in enable condition

You need to add some more elaborate circuits here, i.e., the barrel inserters are only enabled if T=220, the uranium inserters are only enabled if (T!=0 and T!=220). The T!=0 condition is currently missing in your set-up.

Loewchen
Global Moderator
Global Moderator
Posts: 8284
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by Loewchen »

I don't think I understand your activation condition for the inserters. When you set them activated for a specific ID it would not matter that the ID arrives after the loading process started as no ID signal would not activate them just as the wrong signal would not.

I saw it in your screenshot now, you use =/= that is not going to work.

mtfreitasf
Burner Inserter
Burner Inserter
Posts: 12
Joined: Sat Apr 27, 2019 12:38 pm
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by mtfreitasf »

Loewchen and p4wana,

I was able to implement it using your tips - thank you very much for all your help and sorry to post it as a bug.

Best regards,

Marcos

foamy
Filter Inserter
Filter Inserter
Posts: 432
Joined: Mon Aug 26, 2019 4:14 am
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by foamy »

Another alternative would've been to split the barrel train's wagonload half and half with filtered slots. It cuts the train's throughput, but how much acid are you really using?

Zanthra
Fast Inserter
Fast Inserter
Posts: 207
Joined: Fri Mar 25, 2016 8:18 am
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by Zanthra »

If you are going to change the design the other solution is to use fluid wagons for the sulfuric acid. Inserters can’t take or load from fluid tanks and pumps can’t access normal wagons, so no circuit conditions are needed for the inserters. The fluid wagons don’t need to manage barrels and unload and load faster than barrels if pumping directly to or from fluid tanks.

But it seems like the OP was able to make his solution work.

mtfreitasf
Burner Inserter
Burner Inserter
Posts: 12
Joined: Sat Apr 27, 2019 12:38 pm
Contact:

Re: [1.1.5] Train stop - inserter loading train although being disabled

Post by mtfreitasf »

Just as an update - I thank you for all your advice. @foamy and Zanthra, I thank you for your solutions. They are simpler and probably more efficient but I wanted to challenge myself. The solution I found was:
Imagem7.jpg
Imagem7.jpg (494.19 KiB) Viewed 1974 times
I'll try to explain the solution and will be available for any questions you may have:

- The train stop is flagged with Read train contents and Read stopped train
Imagem8.jpg
Imagem8.jpg (97.63 KiB) Viewed 1974 times
- The inserters that load the train only work if three conditions are met:
- The train stopped at the station is the Uranium Train AND
- The train has less than 7800 units of Uranium ore (the train has four wagons)
- The RS latch allows it (the range is 200 - 4200). The RS latch is a balancer to fill the chests and are linked to the inserters that fill the chests.
- There is one additional inserter per wagon that loads one ore per time and it works only after the wagon is almost full
- All the inserters that load the wagon are flagged with Override stack size.

The string to import is below and I hope it helps someone with the same challenge. It worked for what I needed.

Best regards,

Marcos

0eNrtXF2O47gRvspCz/JE/CeNJIfYzTwFg4bb5nQLsSVDkhuZDHyAHCQXy0lC2dNtWRLFKtq901rkpRu2rI9FflXFYhXJ78nj9mD3VV40yfJ7kq/Lok6Wf/+e1PlTsdq23zXf9jZZJnljd0maFKtd+6la5dvkmCZ5sbH/TJbkmAZf+bqqm0W93+ZNY6vOu/T4JU1s0eRNbs9tnz58eyg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