Can I use circuits to automate this?

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
nr2117
Long Handed Inserter
Long Handed Inserter
Posts: 52
Joined: Tue Dec 13, 2016 9:24 pm
Contact:

Can I use circuits to automate this?

Post by nr2117 »

First off, two screenshots to illustrate what it is I'm trying to do here:
research buffer
My question is, I've just researched circuit networks, and I'd like to know if there's a way, say, by connecting my first lab to a sensor, so if it doesn't have red flasks, it'd tell the inserter with the red flasks to start putting them onto the conveyor belt (or, to rotate the one that's feeding it with red flasks, or, to turn on the little conveyor belt to feed into the main one)

In the second screenshot there's the inserter and conveyor belt buffer I'm trying to build up for my green flask assemblers. I'd like it so a seperate signal could be sent to those boxes I'm using as a buffer, to instruct it to feed back onto the conveyor belt the materials needed, if/when that lab rens out of green flask.

I don't know if this is possible or not, but I love how this game is about automation. Rather than me running back to manually turn the buffers on, I'd love if it was done automatically like so. I did look up if you can turn conveyor belts on/off, or if you can have a thing that rotates inserters so instead of putting in, they pull out.

Likewise some sort of signal so when the lab is satisfied with flasks, it tells the buffer to turn off and stop feeding into my machines.

nr2117
Long Handed Inserter
Long Handed Inserter
Posts: 52
Joined: Tue Dec 13, 2016 9:24 pm
Contact:

Re: Can I use circuits to automate this?

Post by nr2117 »

Image

I was being dumb. I think this will work, without any need to turn something on or off. Which leads me to wonder, apart from soem very clever stuff with circuits, what else can you use them for?

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3700
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Can I use circuits to automate this?

Post by DaveMcW »

nr2117 wrote:connecting my first lab to a sensor
You can't connect labs, but you can connect the belt in front of the first lab which does the same thing.

Pick up a stack of red wires, click the belt, then click power lines to run the wire back to the inserter.
Click the belt, Mode of operation = Read belt contents, Content read mode = Hold.
Click the inserter, Mode of operation = Enable/disable, Enabled condition = Science Pack 2 < 1.
Last edited by DaveMcW on Tue Dec 13, 2016 10:24 pm, edited 2 times in total.

Zerias
Burner Inserter
Burner Inserter
Posts: 18
Joined: Mon Jun 15, 2015 12:10 am
Contact:

Re: Can I use circuits to automate this?

Post by Zerias »

I don't believe that labs are able to signal when they need a flask, but it's not necessary. The belts providing the flasks can be set to sensor mode and/or enable mode. Connect one or more of these belts to both of your de-boxing inserters, and tell them to only enable when the sensor mode belt has run out of flasks of that type.

Yoyobuae
Filter Inserter
Filter Inserter
Posts: 499
Joined: Fri Nov 04, 2016 11:04 pm
Contact:

Re: Can I use circuits to automate this?

Post by Yoyobuae »

nr2117 wrote:Which leads me to wonder, apart from soem very clever stuff with circuits, what else can you use them for?
Around two months ago I was asking myself a similar question. Have been tinkering with circuit network stuff ever since. :D

I made this a few days ago (used a mod to allow changing assembler recipe via circuit network):
https://youtu.be/cGfAFxHplnE

But yeah, that took a looot of tinkering to make it work correctly. :lol: That kind of clockwork like precision is really hard to achieve (and easy to throw off).

More realistic applications are much simpler and for specific purposes, like managing oil or trains or back-up steam power and such. Trying to apply circuit networks to stuff which shouldn't really be done with circuit networks will just bring you headaches. Unless you really enjoy logical puzzles, on which case help yourself into loads of fun. ;)

User avatar
Deadly-Bagel
Smart Inserter
Smart Inserter
Posts: 1498
Joined: Wed Jul 13, 2016 10:12 am
Contact:

Re: Can I use circuits to automate this?

Post by Deadly-Bagel »

nr2117 wrote:Which leads me to wonder, apart from soem very clever stuff with circuits, what else can you use them for?
I usually don't do anything too clever, mostly just use it to limit cracking and such to ensure I only start cracking light oil when I have at least half as much of it as petroleum or something.

Today I ripped out all of my trains, playing Bob's Mods in a modular base so I had quite a few. Rather than a "circuit train" that provides everything with circuits, I reworked it so I have sort of requester trains that go and pick up only what is required for their module. At each unloading zone, I connected all the chests and a Constant Combinator with some negative values of everything being unloaded, then connected the train. It runs on the condition ([Anything] < 0) so if something drops below the threshold in the Constant Combinator it triggers the train to go pick up more, and I don't have trains pointlessly running about when they don't need to pick up anything. Loading area is a separate station so nothing is held up.

Something else I'll be using is a little memory cell to remember the lowest value of something, then plug it in to a roboport monitoring bots. If available bots drops below 5%, even for a moment, the count will be remembered and an appropriate number of robots will be added to make it back up to 5% availability.

Also with science now using a lot more science packs, I think I'll be using a single controlled belt loop to distribute research packs. As each science pack is taken off the belt, it triggers another one of the same type to be put on it. Alternatively I'll link a belt up to a memory cell and counter to ensure something like there is at least one (adjustable) of each type of science pack crossing the belt per second.

Not really advanced stuff but it is an extremely useful tool for these sort of micromanagement projects.
Money might be the root of all evil, but ignorance is the heart.

nr2117
Long Handed Inserter
Long Handed Inserter
Posts: 52
Joined: Tue Dec 13, 2016 9:24 pm
Contact:

Re: Can I use circuits to automate this?

Post by nr2117 »

Yoyobuae wrote:
nr2117 wrote:Which leads me to wonder, apart from soem very clever stuff with circuits, what else can you use them for?
Around two months ago I was asking myself a similar question. Have been tinkering with circuit network stuff ever since. :D

I made this a few days ago (used a mod to allow changing assembler recipe via circuit network):
https://youtu.be/cGfAFxHplnE

But yeah, that took a looot of tinkering to make it work correctly. :lol: That kind of clockwork like precision is really hard to achieve (and easy to throw off).

More realistic applications are much simpler and for specific purposes, like managing oil or trains or back-up steam power and such. Trying to apply circuit networks to stuff which shouldn't really be done with circuit networks will just bring you headaches. Unless you really enjoy logical puzzles, on which case help yourself into loads of fun. ;)
Man, that's hella cool, and would use a lot less space than all the base factories needed to make the intermediate products. But, what mods are included, what functionality did it give you that you can't get in the base game?

And, it's not just because I'm lazy, but please could someone show what a sensor is, how you put it on a conveyor belt, and how you hook it up to an inserter. As in, when green flask=1, pick up conveyor/inserter from the belt, when green flask=0, turn on the blue inserters and put components onto the belt.

User avatar
Deadly-Bagel
Smart Inserter
Smart Inserter
Posts: 1498
Joined: Wed Jul 13, 2016 10:12 am
Contact:

Re: Can I use circuits to automate this?

Post by Deadly-Bagel »

You just craft a Red Wire or Green Wire, use it, click the belt then click the inserter. Then open up the belt's GUI and it has an option on the right to be in enable/disable mode, and/or read belt contents with the option of pulse or hold.

Pulse mode sends a signal of that item for 1 tick regardless of how long it is on the belt. This is used for memory cells and is the most precise way of counting something. Hold sends every item that is on the belt constantly, as long as it is on the belt. This is the most reliable method as it is not affected by power outages, unlike memory cells which lose their memory.

If you're going for hold (probably the easiest setup), you'll want to connect several belts before and after the inserter (can connect in any order, doesn't have to be directly to the inserter). Remember you can Shift+Right Click to copy settings and Shift+Left Click to paste them. Say you connect 10 belts. You can then set the inserters to work only when their specified science pack (or other item) is less than however many you would want across 10 belts.
Money might be the root of all evil, but ignorance is the heart.

Yoyobuae
Filter Inserter
Filter Inserter
Posts: 499
Joined: Fri Nov 04, 2016 11:04 pm
Contact:

Re: Can I use circuits to automate this?

Post by Yoyobuae »

nr2117 wrote:Man, that's hella cool, and would use a lot less space than all the base factories needed to make the intermediate products. But, what mods are included, what functionality did it give you that you can't get in the base game?
Mods used are Crafting Combinator to allow switching assembler recipes, and Creative Mode just for convenience (generate iron/copper belt and getting rid of green bottle output). The assemblers, inserters, chests, combinators are all plain vanilla.

The crafting combinator is the one that looks like a constant combinator near the assemblers. You send a circuit network signal to it and it changes the recipe of the assembler. Whatever is inside the assembler when recipe change is "lost" (it can be recovered via bots, if those are used), otherwise it's no different than manual recipe switch. My control circuit logic tries to avoid leaving stuff inside the assemblers before recipe switches.

The circuits is designed to enable/disable inserters in just the right patterns to control production. When copper wire is being made the input inserter is turned off at the right time to ensure 288 wires are made. And then green circuit production controlled similarly, then iron gear wheels (which must match green circuit quantity), and so on.

mergele
Fast Inserter
Fast Inserter
Posts: 158
Joined: Sat Aug 20, 2016 5:45 am
Contact:

Re: Can I use circuits to automate this?

Post by mergele »

Yoyobuae wrote:
nr2117 wrote:Which leads me to wonder, apart from soem very clever stuff with circuits, what else can you use them for?
Around two months ago I was asking myself a similar question. Have been tinkering with circuit network stuff ever since. :D

I made this a few days ago (used a mod to allow changing assembler recipe via circuit network):
https://youtu.be/cGfAFxHplnE

But yeah, that took a looot of tinkering to make it work correctly. :lol: That kind of clockwork like precision is really hard to achieve (and easy to throw off).

More realistic applications are much simpler and for specific purposes, like managing oil or trains or back-up steam power and such. Trying to apply circuit networks to stuff which shouldn't really be done with circuit networks will just bring you headaches. Unless you really enjoy logical puzzles, on which case help yourself into loads of fun. ;)
That is a beutiful idea. I must try to find a use for that idea myself.
Back to OP, Circuit networcks can do amazing things but you can also compleltly skip them and most of the stuff I so far used them for have turned out pretty mundane. Turning off steam engines when my accs still have a good amount of power left, shining big red lamps in more frequented areas of the base when outposts run out of ammo, railroad crossings and for some reason I can't remember right now in my last game I viewed them as instrumental for my barreled oil transportation (Haven't reached that point again yet, Bob's mod).

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

Re: Can I use circuits to automate this?

Post by mrvn »

Your case doesn't scream for circuit networks. The opposite in fact. As you noticed you can simply side load items onto the belt so items from the chest are only used when the belt is empty. The same can be done by using 2 chest alongside the belt. Feed the first chest with a filter inserter, feed the second chest from the first and feed the belt from the second chest. Now you have 2 buffer chests and they will only be used when there is space on the belt.

Generally I would say that circuits are better for turning things off early which runs contrary to buffer chests. With buffer chests you want to produce as much as possible ahead of time so that later demand can be met. But what if you are resource starved. You don't want to use up 100k iron ores to produce red science flasks and have nothing left to build your first pump jack. So you get rid of the buffer chest so production backstops earlier. You still have a lot of items on the belts. Long belts are a buffer of their own. Now what you can do is connect the belt right before the science labs via electrical poles to the belts feeding iron plates and copper plates to the science production complex (or where you split of electric circuits if that production shared). Set the belt at the science labs to report and hold. Set the belts leading to the red science production to turn on when red science flasks == 0 and the belts leading to the green science production to turn on when green science flasks == 0. Now instead of over producing 500 science flask before the backlog stops production it will stop much sooner.

This might not seem so useful for science production since you will need a lot of it for a very long time anyway. But think about other items. A good example would assembler 3. You might produce them somewhere and have a long belt going to a central supply place or train station. You don't want to have 500 assembler 3 sitting on the belt before production stops. Better to stop production as soon as there are e.g. 50 assembler 3 in the buffer chest.

vanatteveldt
Filter Inserter
Filter Inserter
Posts: 945
Joined: Wed Nov 25, 2015 11:44 am
Contact:

Re: Can I use circuits to automate this?

Post by vanatteveldt »

Like mrvn said, for controlling production you normally don't really need circuit networks.

What I use circuit networks for:
- switching off parts of the base with a power switch if storage is full (to save energy from beacons)
- priority splitters (i.e. send everything to A unless A is fully backed up, then send it to B)
- balanced station loading
- train control (ore train departs if an empty one arrives, via circuit condition on a signal)

What I used circuits for in the past:
- smart smelting: insert the ore into the smelter for which more plates are needed
- logistic bot control: create/insert a new bot into the roboport if # of available bots < X

Post Reply

Return to “Gameplay Help”