Graphing power usage

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
kangirigungi
Manual Inserter
Manual Inserter
Posts: 1
Joined: Sun Jun 24, 2018 6:10 am
Contact:

Graphing power usage

Post by kangirigungi »

This one is fairly simple, but practical. I made my factory to rely completely on solar panels and batteries for power production. I was practically building them blindly, the only indication to extend the system is an alarm that sets off when the battery level goes below 25%. So I decided to create a graph that shows battery levels in time.

Here is what a typical output looks like.
Image

And this happens after I dispatch thousands of construction robots deconstructing an area with lots of supplies (moral of the story: build much more accumulators).
Image

How does it work? The combinator on the lower right with green wires is a clock, as it is described in the tutorial on the wiki. The output of the battery is connected to the column of lamps, which light up when the battery level reaches certain thresholds (10%, 20%, ..., 100%). The other combinators make up the shift register that shift the output left each time the clock resets itself.

This has a fairly good resolution, but slows down the game significantly while it is visible. So for longer periods, I made another one that displays daily minimum levels.

Image

The shift register is the same, but there is a somewhat more complex logic at the input. The clock is set to one day. The other combinators read the input, and holds the lowest value encountered. It is done by holding the output when it is lower than the input, otherwise outputting the input. When the clock resets, a pulse of 100 is added to the output, resetting the minimum.

Here are the blueprints.
normal
daily minimum

Post Reply

Return to “Combinator Creations”