Conditional Lab Activation
Conditional Lab Activation
Hi,
i have searched quite a bit, but not found anything helpful:
I have built a large research Complex with Labs and beacons, and it is using about half of my total power consumption (modded game - Angels+Bobs and some minor mods).
So i am looking for a way to switch the complex on only when a research is actually in progress, but cannot find a way to get that information. Labs cannot be wired to the circuit network and i cannot think of another not too complicated way of getting this information. I think there might be a way using a seperate "Sensor" lab and an energy consumption detector, but there has to be some better way.
i have searched quite a bit, but not found anything helpful:
I have built a large research Complex with Labs and beacons, and it is using about half of my total power consumption (modded game - Angels+Bobs and some minor mods).
So i am looking for a way to switch the complex on only when a research is actually in progress, but cannot find a way to get that information. Labs cannot be wired to the circuit network and i cannot think of another not too complicated way of getting this information. I think there might be a way using a seperate "Sensor" lab and an energy consumption detector, but there has to be some better way.
- impetus maximus
- Smart Inserter
- Posts: 1299
- Joined: Sat Aug 20, 2016 10:07 pm
- Contact:
Re: Conditional Lab Activation
if you have access to accumulators, i would use an SR latch.
[edit] the beacons should be on a different network from the labs but switch off with the labs. use the labs to draw from the accumulator.blueprint string
Re: Conditional Lab Activation
Honestly I do not see other way than manually switching power off here. There is no way you can get info about science or labs at all.
Re: Conditional Lab Activation
It can be read with some mod and available with special constant combinator.PacifyerGrey wrote:Honestly I do not see other way than manually switching power off here. There is no way you can get info about science or labs at all.
Re: Conditional Lab Activation
You can detect that an inserter is putting science into a lab. If you time the interval between insertions then you can detect when it exceeds some upper-bound to determine when research has stopped.
Re: Conditional Lab Activation
The point is if you disable power the whole research facility will not start again everCaine wrote:You can detect that an inserter is putting science into a lab. If you time the interval between insertions then you can detect when it exceeds some upper-bound to determine when research has stopped.
Only if you make a standalone lab which will turn the resl of the complex on/off
Re: Conditional Lab Activation
Check the last chest or belt for science packs. If it has them, you know the rest of the labs have them too.
- impetus maximus
- Smart Inserter
- Posts: 1299
- Joined: Sat Aug 20, 2016 10:07 pm
- Contact:
Re: Conditional Lab Activation
labs don't have any 'drain'.
- Deadly-Bagel
- Smart Inserter
- Posts: 1498
- Joined: Wed Jul 13, 2016 10:12 am
- Contact:
Re: Conditional Lab Activation
Ahah you know I was about to say that same thing but decided to read over the OP again - he's using a ton of Beacons, and they do have drain.
Money might be the root of all evil, but ignorance is the heart.
- impetus maximus
- Smart Inserter
- Posts: 1299
- Joined: Sat Aug 20, 2016 10:07 pm
- Contact:
Re: Conditional Lab Activation
right, so that is what we need to switch off.Deadly-Bagel wrote:Ahah you know I was about to say that same thing but decided to read over the OP again - he's using a ton of Beacons, and they do have drain.
Re: Conditional Lab Activation
Inserters have drain too.
So it makes sense to have one isolated lab which is always on with the inserter wired up to a count down clock. Every time the inserter has something in its hand you reset the clock. If the clock reaches 0 you turn off the remaining huge science complex.
So it makes sense to have one isolated lab which is always on with the inserter wired up to a count down clock. Every time the inserter has something in its hand you reset the clock. If the clock reaches 0 you turn off the remaining huge science complex.
Re: Conditional Lab Activation
mrvn wrote:Inserters have drain too.
So it makes sense to have one isolated lab which is always on with the inserter wired up to a count down clock. Every time the inserter has something in its hand you reset the clock. If the clock reaches 0 you turn off the remaining huge science complex.
Turning beacons on/off without touching labs is nearly impossible as power poles most likely intersect. Unless devs will finally implement circuit network connection for beacons...PacifyerGrey wrote:Only if you make a standalone lab which will turn the resl of the complex on/off
So switching the whole facility is a way to go.
However introducing timer is not too accurate as research times will increase over time which means you will probably have labs working invane for quite a time after research is finished.
Re: Conditional Lab Activation
Bit of a kludge but:PacifyerGrey wrote:mrvn wrote:Inserters have drain too.
So it makes sense to have one isolated lab which is always on with the inserter wired up to a count down clock. Every time the inserter has something in its hand you reset the clock. If the clock reaches 0 you turn off the remaining huge science complex.Turning beacons on/off without touching labs is nearly impossible as power poles most likely intersect. Unless devs will finally implement circuit network connection for beacons...PacifyerGrey wrote:Only if you make a standalone lab which will turn the resl of the complex on/off
So switching the whole facility is a way to go.
However introducing timer is not too accurate as research times will increase over time which means you will probably have labs working invane for quite a time after research is finished.
Have one extra lab, unboosted, outside of the main research cluster.
Use a 120 second timer to set the "power off" to the research cluster, excluding this one unboosted lab. Use an SR latch for this.
Set the Reset of the SR latch to trigger on any input, then hook it up to the inserter that is feeding the unboosted lab and set the inserter to read hand content in hold mode.
Effect: Shortly after starting a research the main labs will be kicked online when the unboosted lab gets fed. When research ends, the extra labs will shut off after at most a 120 second timeout.
Re: Conditional Lab Activation
I think you can improve on the timeout.
You still need one lab that runs all the time but don't connect to the inserter for that lab.
Instead connect to the belt(s) running into your science complex (before the always on lab) set to pulse mode and use that to reset the timeout.
If you also set your labs up with some labs chained to others you should get a lot more pulses than with just the inserter from a single lab.
Note: The chaining of labs is there to get and keep them out of sync. Otherwise you might get 1000 pulses close together with a 100s gap and science would shut down while needed till the always on lab reactivates it again.
You still need one lab that runs all the time but don't connect to the inserter for that lab.
Instead connect to the belt(s) running into your science complex (before the always on lab) set to pulse mode and use that to reset the timeout.
If you also set your labs up with some labs chained to others you should get a lot more pulses than with just the inserter from a single lab.
Note: The chaining of labs is there to get and keep them out of sync. Otherwise you might get 1000 pulses close together with a 100s gap and science would shut down while needed till the always on lab reactivates it again.
Last edited by mrvn on Tue Feb 27, 2018 10:05 am, edited 1 time in total.
Re: Conditional Lab Activation
That is an interesting approach i will try out. I am right now trying something like in the first answer, buit with a seperate lab where the power consumption is measured, but it still needs some tuning.
- Deadly-Bagel
- Smart Inserter
- Posts: 1498
- Joined: Wed Jul 13, 2016 10:12 am
- Contact:
Re: Conditional Lab Activation
Set Inserter Stack Size to 1, timeout can then be set to say 65s without chaining. Inserters will use a bit more power moving things around but it shouldn't be a massive difference compared to the energy making those Science Packs.mrvn wrote:Note: The chaining of labs is there to get and keep them out of sync. Otherwise you might get 1000 pulses close together with a 100s gap and science would should down while needed till the always on lab reactivates it again.
Money might be the root of all evil, but ignorance is the heart.
Re: Conditional Lab Activation
I got a good working solution:
The falling edge is then detected by comparing the level to a delayed signal and this pulse is then lengthened with the use of another belt loop. It is working really good. To make it work at night, the accumulator of course needs to be steam powered because the accumulators from the main network cannot charge the others, but in a modded game, this limitation can be overcome with electric boilers and a dedicated steam engine for this contraption. I can provide further information if anyone is interested.
The single probe lab is connected to the power pole on the right. Basically, it detects power consumtion by falling signal levels in a accumulator. Do do so accurately it swaps it around - one accumulator is charged all the time and the other is discharged from, swapping at an interval (The circuit connected belts are the clock for this, there is an item circulating which is either on the top or on the bottom side. This is a clock which hardly looses timing on power loss)The falling edge is then detected by comparing the level to a delayed signal and this pulse is then lengthened with the use of another belt loop. It is working really good. To make it work at night, the accumulator of course needs to be steam powered because the accumulators from the main network cannot charge the others, but in a modded game, this limitation can be overcome with electric boilers and a dedicated steam engine for this contraption. I can provide further information if anyone is interested.
Re: Conditional Lab Activation
Can't just replace your clock by a logic clock and some dedicated panels/accus?Boldar wrote: (The circuit connected belts are the clock for this, there is an item circulating which is either on the top or on the bottom side. This is a clock which hardly looses timing on power loss)
The falling edge is then detected by comparing the level to a delayed signal and this pulse is then lengthened with the use of another belt loop. It is working really good. To make it work at night, the accumulator of course needs to be steam powered because the accumulators from the main network cannot charge the others, but in a modded game, this limitation can be overcome with electric boilers and a dedicated steam engine for this contraption. I can provide further information if anyone is interested.
Re: Conditional Lab Activation
Hahaha...
it would be so much simpler if Twinsen would just add a circuit network signal to the labs which outputs if it is currently researching or not. Someone should probably tell them that this is an issue.
I tried so many times doing it with Circuit Network contraptions trying to measure the power draw or inserter movements and failed with it that I gave up on it honestly. I just let the beacons around the labs draw power even when idle and don't give much of a damn about it. The few beacons aren't the world anyway compared to the rest of the factory... and if it is due to mods then just switch them off manually or look for a mod that allows for circuit network connection to labs.
Hell, my roboports draw 200MW idle. What are a bunch of beacons around labs compared to that. Though I already consider rigging the "excess roboports" also to power gates that turn on when the affiliated factory module comes online, and otherwise leaving only a "backbone" of corner roboports always on to keep the logistic network without gaps.
Everything else in the factory is shut down though when idle, not only the beacons but even the machines and inserters. Don't give much of a damn to seperate the machines from the beacons. it's not possible to seperate them anyway due to power pole coverage overlapping with beacons/assemblers.
And honestly being able to switch off beacons over Circuit network would seem nice on paper, but wouldn't be of any more advantage than just shutting down the entire factory module including the machines and inserters. On the contrary... shutting down the entire factory module even kills the idle power draw of machines and inserters... so even more power is saved.
it would be so much simpler if Twinsen would just add a circuit network signal to the labs which outputs if it is currently researching or not. Someone should probably tell them that this is an issue.
I tried so many times doing it with Circuit Network contraptions trying to measure the power draw or inserter movements and failed with it that I gave up on it honestly. I just let the beacons around the labs draw power even when idle and don't give much of a damn about it. The few beacons aren't the world anyway compared to the rest of the factory... and if it is due to mods then just switch them off manually or look for a mod that allows for circuit network connection to labs.
Hell, my roboports draw 200MW idle. What are a bunch of beacons around labs compared to that. Though I already consider rigging the "excess roboports" also to power gates that turn on when the affiliated factory module comes online, and otherwise leaving only a "backbone" of corner roboports always on to keep the logistic network without gaps.
Everything else in the factory is shut down though when idle, not only the beacons but even the machines and inserters. Don't give much of a damn to seperate the machines from the beacons. it's not possible to seperate them anyway due to power pole coverage overlapping with beacons/assemblers.
And honestly being able to switch off beacons over Circuit network would seem nice on paper, but wouldn't be of any more advantage than just shutting down the entire factory module including the machines and inserters. On the contrary... shutting down the entire factory module even kills the idle power draw of machines and inserters... so even more power is saved.
Re: Conditional Lab Activation
If you want to turn off power for research because you don't have enough science packs then there is something much simpler that can be done:
Put all science packs into chests and then back onto belts to the science labs. Then enable the beacons when you have >100 science packs in each chest and disable them when you have 0.
Put all science packs into chests and then back onto belts to the science labs. Then enable the beacons when you have >100 science packs in each chest and disable them when you have 0.