Help needed: Requisition order via circuits

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

ashjones303 wrote: ↑
Thu Sep 08, 2022 8:53 pm
That's pretty damn close to being it. Your final combinator does what I want, except mid way through delivery it could be over written if stone is needed while trying to collect iron.

I'm not going to lie, I don't understand in the slightest how it filters through the items like that. All three of the the "anything" combinators have zero output so I cant see it being sorted there, and the top "everything" combinator I have requested all three inputs but only one at a time is displayed in the final combinator. Its close to real magic :)
This is it is think ?


EDIT: i changed the bp , i made mistake and originally copied string of previous design twice



it uses the same magic as the two previous but it's polished with reduced number of combinator and threshold to 1K or different value.

It does require manually setting up the depot number in the cell initially whatever data inside the cell will be kept, it also require the inititalization with a constant combinator to represent the full storage. Then i'm not quite sure how it works.


the idea is that if you take any signal from say a chest, and you do each *-1, and you output the negative and the original signal at the same "place" there will be a little delay during which things will not be 0 because it takes 1 tick longer for the signal that are made negative to reach the "place".

This "place" is a decider combinator that allows everything to go through when anything is different than 0.

This means each time the quantity in chest changes, either positively or negatively, then only the amount of change is passed onto the memory and only during 1 tick.

This means when ressources are consumed , it is written down, and when replenish also. memory never reset

i'm not sure how the 1K threshold works
Last edited by mmmPI on Thu Sep 08, 2022 9:32 pm, edited 1 time in total.

mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

ColonelSandersLite wrote: ↑
Thu Sep 08, 2022 9:13 pm
Is sending a single tick pulse really the main problem you're having? That's pretty easy man. Try this little demo.

Switching the constant combinator from off to on sends a single tick pulse which lights up the light for exactly 1 tick.

Switching the constant combinator from on to off does nothing.
I was reformulating the problem in an attempt to make sure i had understood it well

I think the latest design i posted is doing the original request.

this demo is nice because it is exactly what's required to write the depot ID in the memory cell of the latest design :D

mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

ashjones303 wrote: ↑
Thu Sep 08, 2022 9:13 pm

Looking at it, there is no reason the depot ID needs to be included until the very end, so that makes sense

This one is good also but it can never be overwritten meaning I can can only use it once where as I am looking for something that I can use multiple times over, for example if a circuit chip factory depot develops and needs new materials
What do you mean overwritten ?

The request can be changed, you would need to connect a constant combinator to fake a full storage, then set the request at this amount, then delete the first constant, it will act as if everything was consumed in 1 tick, and request the new item.

The latest design is sadly requiring the same manipulation.[ or not ? just adding something to the request combinator seems to do it for me as long as it's above the 1K threshold set in the second decider ? ]

Edit : i copied wrong "latest design" but corrected, please don't be mad i'm tired i made wiring all day and need some rest sorry x)

ashjones303
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon Aug 08, 2016 3:59 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by ashjones303 »

ColonelSandersLite wrote: ↑
Thu Sep 08, 2022 9:13 pm


DoshDoshington did his video pretty recently. It can be seen here.
https://www.youtube.com/watch?v=_S87vHUobvQ

Nilaus was the other one but those videos are pretty old now. That was more than a couple of factorio major version updates ago.

ashjones303 wrote: ↑
Thu Sep 08, 2022 3:49 pm
mmmPI wrote: ↑
Thu Sep 08, 2022 2:59 pm
... the problem becomes a way to trigger this during only 1 tick so that you don't store the negative value.
Exactly this. I did something similar in an old save but I cant find it now and I know there is a way to do it but it was years ago and I cant remember.

Again, thank you both
Is sending a single tick pulse really the main problem you're having? That's pretty easy man. Try this little demo.

Switching the constant combinator from off to on sends a single tick pulse which lights up the light for exactly 1 tick.

Switching the constant combinator from on to off does nothing.

Thank you for both of those. Nilaus touches on what I am wanting to do but i've never been able to implement his methods successfully. Not familiar with Doshdoshington, Ill give him a watch.

I thought at the time my problem was a one tick issue, now I dont know, i close my eyes and all I can see is red and green wires

ashjones303
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon Aug 08, 2016 3:59 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by ashjones303 »

mmmPI wrote: ↑
Thu Sep 08, 2022 9:26 pm
ashjones303 wrote: ↑
Thu Sep 08, 2022 9:13 pm

Looking at it, there is no reason the depot ID needs to be included until the very end, so that makes sense

This one is good also but it can never be overwritten meaning I can can only use it once where as I am looking for something that I can use multiple times over, for example if a circuit chip factory depot develops and needs new materials
What do you mean overwritten ?

The request can be changed, you would need to connect a constant combinator to fake a full storage, then set the request at this amount, then delete the first constant, it will act as if everything was consumed in 1 tick, and request the new item.

The latest design is sadly requiring the same manipulation.[ or not ? just adding something to the request combinator seems to do it for me as long as it's above the 1K threshold set in the second decider ? ]

Edit : i copied wrong "latest design" but corrected, please don't be mad i'm tired i made wiring all day and need some rest sorry x)
Oh, my bad, sorry. I'm just grateful you have even had a try. Thank you so much for your time and efforts and take some time out! Im keeping the memory cell clearing setup, I always struggle there. Thank you again

mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

ashjones303 wrote: ↑
Thu Sep 08, 2022 9:44 pm

Oh, my bad, sorry. I'm just grateful you have even had a try. Thank you so much for your time and efforts and take some time out! Im keeping the memory cell clearing setup, I always struggle there. Thank you again

Sorry for posting many crappy design before the working one, if it's even working , sorry for the wrong post initially on the latest design, i'm reposting it in case because there's many before but this one is the last one from all the serie.

I like playing with combinator, i do it a lot but usually i try not to spam crappy design, thanks you for providing a mini-game and having the patience to check every iteration :D
mmmPI wrote: ↑
Thu Sep 08, 2022 9:16 pm

ashjones303
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon Aug 08, 2016 3:59 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by ashjones303 »

EDIT: I don't know why it wont link BP cleanly but the string is at the bottom

Had a sleep and a think and a bit more of a think and included the filter combinator mod.
I hope someone finds this useful, and if this needs posting a different forum, really sorry

( https://mods.factorio.com/mod/Filter_Combinator)

I'm including the walk through mainly for myself to debug but also to hopeful explain what it does.

CC and bugs welcome. Made to work alongside AAI programmable vehicles but is not required to replicate



Design Spec - an LTN styled system where AAI will deliver all the requested goods as is placed in one order. It will remember this order and allow a new order to be generated without rewriting the original order. Once the order is completed, the new order is entered into the system and the process continues. There is a certain margin for not having enough

The Request Value Constant combinator - How much of any given item you want at maximum level in the storage box

Decider Combinator "A" - The value at which any given item can fall to before it requests a restock

Iron Chest (represented by constant combinator for test purposes) - What you have in stock.

Decider Combinator "B" - Memory cell that is written to when any value >1000 is inputted on a single tick. This could be a single value or hundreds. Once saved, this memory cannot be over written until all values = 0

Bottom Green Wire - Real time update of storage to compare against memory - filtered with memory cell to compare like for like.

Decider Combinator "C" - Combines Storage Value and Order Value. All values > 0 order fulfilled. (I cant get this part to make sense but it works as intended)

Decider Combinator "D" and "Delay" - Part of the reset system to allow deleting the memory cell and inputting new data. (I cant remove the checks smoothly but they don't interfere as it stands.)

Application of this data - Sending an AAI Vehicle (truck, car, tank, boat, plane) on a collection run for a copper order and not be confused mid collection by a request for stone and/or iron. On delivery of copper, the copper order is closed and the new iron stone order is issued.

Special Thanks to mmmPI and ColonelSandersLite



Last edited by ashjones303 on Fri Sep 09, 2022 3:17 pm, edited 3 times in total.

mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

ashjones303 wrote: ↑
Fri Sep 09, 2022 12:39 pm
EDIT: I don't know why it wont link BP cleanly but the string is at the bottom
you need to add [ b p ] and [ / b p ] without spacing before and after the string
ashjones303 wrote: ↑
Fri Sep 09, 2022 12:39 pm
Had a sleep and a think and a bit more of a think and included the filter combinator mod.
I hope someone finds this useful, and if this needs posting a different forum, really sorry

( https://mods.factorio.com/mod/Filter_Combinator)
I didn't know the mod, i recommend : https://mods.factorio.com/mod/PickerDollies when toying with combinators, it allow you to move a wired combinator using Shift + WASD arrow, lamps power poles and so on, it's super useful !

Will check the blueprint when i can add the mod :)

ashjones303
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon Aug 08, 2016 3:59 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by ashjones303 »

Ah ha! Thank you!

And yes, picker dollies is a must to compact it all down into a homogeneous mass to fit in between the factories

mmmPI
Smart Inserter
Smart Inserter
Posts: 1883
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Help needed: Requisition order via circuits

Post by mmmPI »

I had time to check and it's more complicated than what i did :) , it took me time to recognize and i'm still unsure about what the filter combinator is doing/why.

I think i understand why you added back the check signals and what you did to sync the reset signal to the memory cell to match the new value allowed by the check signal in the combinator just before.
ashjones303 wrote: ↑
Fri Sep 09, 2022 12:39 pm
Decider Combinator "C" - Combines Storage Value and Order Value. All values > 0 order fulfilled. (I cant get this part to make sense but it works as intended)
[Everything >= 0 => output R1] on a decider combinator will output 0 in the R channel if there is a negative signal "false" and will output R=1 as the condition is "true". When there is no input everything = 0 so it output 1 which after the delay disrupt the the memory cell based on R not being 1 to keep its value.

The storage value will increase in quantity as much as the order value eventually which will yield 0 when compared and disrupt the memory cell. (i think, not sure how it plays out in game in the quantity in storage keep decreasing to double the order )

There is a part of the forum dedicated to "show your creations" and a sub-part for "circuit creation" in case you feel like doing a presentation or explanations or maybe pictures of it when implemented :)


I'm playing with transport drone currently to avoid spending my game only doing circuits and actually get some progress done on science , i could use some pre-made blueprint as base for a future game with AAI x).

Post Reply

Return to β€œGameplay Help”