split signals

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
fuinril
Burner Inserter
Burner Inserter
Posts: 15
Joined: Wed Feb 21, 2018 10:50 pm
Contact:

split signals

Post by fuinril »

Hello,

I have a little issue with my logic network.

Short summary : there's a command center where I setup my needs using constant emitters. Each item has an ID and an area.

So for exemple :
- copper wire | 101 | 1
- iron gear | 102 | 1

Then each signal is sent through a multiplexed network, and in this network the channel 11 (which correspond to area 1) transport the following values :
- copper wire = 101
- iron gear = 102

Now what I need is to transform this last signal to this :
- 0 = 101
- 1 = 102
- 2 = 0

etc....

Any idea how I could do ? I struggle to loop through the signals... any type of material signal can be on the channel with a hard limit to 30 single signals and the allotment signals are fixed (0-9A-T)

stenole
Manual Inserter
Manual Inserter
Posts: 4
Joined: Sun Apr 02, 2017 10:14 am
Contact:

Re: split signals

Post by stenole »

If I had to design this:

I would separate the multiplexed signal using 1 combinator per item. Each signal would then be on a separate wire. We will then have a "list" of signals where some signals are present and some are missing. Since the item is coded as a number, the signal type doesn't really matter. We are eventually piling the coded numbers into "1", "2"... "A", "B" etc anyway. But for now keep the item type for each row.

Our goal is to remove the gaps in the list. We can do this by checking each row above a list item. If the row is empty, move the signal up. This adds a whole set of new combinators. It removes one gap in the list.

If you repeat this step, eventually all the signals will be packed into the top rows of the list.

As a final step, make those signals into signal type "0", "1", "2" etc

---

However, as you can probably tell (if you can follow what I am suggesting), this is an awful amount of combinators for a task that combinators are not great at. There are probably clever ways to make the process less incremental or there exists different abstractions that eventually do the same thing with less combinators and complexity. I would still choose to do it this way because it would be easier to debug and the repeated steps can be copy/pasted.

I have no idea how you intend to use your output signal, but there is probably a more practical way to achieve what you are ultimately trying to do without placing your signals in the letter and number items. This is also why I have not bothered to concretely describe how to use the combinators. My advice is to rethink your grand design.

aober93
Filter Inserter
Filter Inserter
Posts: 453
Joined: Tue Aug 30, 2016 9:07 pm
Contact:

Re: split signals

Post by aober93 »

I dont understand the issue, what 0= 101 means?
If its copper wire, then you want to set copper wire = 101 instead of "0" if youre talking about the signal "0" but whatever. Then what is the purpose of trying to set 2 = 0. Thats no equation ..

You dont need to multiplex this at all, because you can send all items at once via 2 (green and red) networks. Each item in game can be sent via circuit. Makes sense to transmit copper ore values via the copper ore signal, instead of an arbitrary letter or number signal.

ExcessionOz
Burner Inserter
Burner Inserter
Posts: 14
Joined: Sun Sep 11, 2016 2:09 am
Contact:

Re: split signals

Post by ExcessionOz »

If you want to send multiple unique 'copper ore' values, then using the Copper signal is no good, since the values are summed.

Mine South: 1.2M copper Ore
Mine North 1.9M copper Ore

resultant Signal 3.1M Copper Ore ...

I am trying to do the same reporting and it's very difficult to wrap my head around it.

DaleStan
Filter Inserter
Filter Inserter
Posts: 368
Joined: Mon Jul 09, 2018 2:40 am
Contact:

Re: split signals

Post by DaleStan »

I don't know if this is at all what you're looking for, but you quite thoroughly nerd-sniped me by talking about signal multiplexing. I made a multiplexer/demultiplexer, which I'm hoping you can use: viewtopic.php?f=193&t=61722

You'll get better response time out of my demuxers if you keep the network IDs small. If you don't want to do that, and don't want the 2-second response time that comes with 120 network IDs, I think you should be able to add some combinators to the clock (constant+decider for each gap) to skip over the gaps.

Post Reply

Return to “Gameplay Help”