Daylight sensor

This board is to show, discuss and archive useful combinator- and logic-creations.
Smart triggering, counters and sensors, useful circuitry, switching as an art :), computers.
Please provide if possible always a blueprint of your creation.
Post Reply
judos
Filter Inserter
Filter Inserter
Posts: 266
Joined: Mon Dec 08, 2014 11:17 am
Contact:

Daylight sensor

Post by judos »

I created a small combinator circuit to measure the daylight with vanilla entities.

Output
One Signal N with a number between 1 and 101 (I didn't like 0 because then I can't see whether the signal is present anywhere or not)

Short explanation
The circuit uses the fact that combinators run slower the less power they have. So I connect one solar panel to entities such that a bit more than 60kW is used. During the day the combinator has enough power and runs on 60ticks. If solar only produces 30kW during dawn the combinator will run only 30 calculations. The transform is almost linear, less power -> less ticks on the combinator.
Meanwhile the main calculation (image on the right side) must always have enough power (main base power, or uninterrupted power supply)


Building requirements
17 Lamps
18 combinators (5 constant, 4 arithemtic, 9 decider)
2 electric poles (small do, if using medium make sure the one with the solar panel doesn't connect anywhere)
1 Solar panel

Additionally if you want the calculation on an uninterrupted power supply:
1 solar panel + 1 accumulator
daylight sensor vanilla.PNG
daylight sensor vanilla.PNG (1.07 MiB) Viewed 6192 times
Demo video 2MB mp4
Long combinator explanation
Blueprint string
Attachments
demo-see-spoiler-in-text.mp4
(2.29 MiB) Downloaded 206 times

AngledLuffa
Fast Inserter
Fast Inserter
Posts: 187
Joined: Fri Jan 05, 2018 5:18 pm
Contact:

Re: Daylight sensor

Post by AngledLuffa »

I love it!

If it's not too much trouble to ask, would you post the blueprint with the red/yellow/green lights as well?

judos
Filter Inserter
Filter Inserter
Posts: 266
Joined: Mon Dec 08, 2014 11:17 am
Contact:

Re: Daylight sensor

Post by judos »

Sure thing.
Hope it helps your base and you have fun with it :)
blueprint with lamps

AngledLuffa
Fast Inserter
Fast Inserter
Posts: 187
Joined: Fri Jan 05, 2018 5:18 pm
Contact:

Re: Daylight sensor

Post by AngledLuffa »

Definitely had fun with it!

I added an S-R latch and a pulse combinator so that it ticks once per day. I counted the number of ticks and added a constant for how many days I've been on the planet before starting the combinators.

I combined it with this display:

https://factorioprints.com/view/-LCBqlZMQrvROJunHaAU

As it turned out, I'm just a couple days away from 10000!

Actually, it's kind of horrifying to think my engineer has been stuck here for 27 years. Maybe days really are just 4 minutes long and his life hasn't been a meaningless existence of launching rockets.

judos
Filter Inserter
Filter Inserter
Posts: 266
Joined: Mon Dec 08, 2014 11:17 am
Contact:

Re: Daylight sensor

Post by judos »

Short update: since the circuitry is not very exact there is also a mod "Time Tools" which has a Clock Combinator which outputs the lightness as value between 0-100, additionally the mod has some gui to speed up time, if you don't need that it's also possible to disable:
/c remote.call( "timetools", "off" )

https://mods.factorio.com/mod/TimeTools

hf!

dmikalova
Manual Inserter
Manual Inserter
Posts: 1
Joined: Thu Nov 26, 2020 7:48 am
Contact:

Re: Daylight sensor

Post by dmikalova »

Thanks, this worked for setting up Krastorio's transceiver in an all solar base. The transceiver acts as an accumulator that loses power when not being charged, and just putting it on an isolated network with a power switch that turns off when accumulators are less than 100% and with a few wind turbines to always have power doesn't work. It seems like in the same tick that the accumulators start losing power, the transceiver sees itself as not being powered which breaks it.

Post Reply

Return to “Combinator Creations”