Fun with Factorization Servos

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

Broomstone

New Member
Jul 29, 2019
38
0
0
Greetings everyone,

After being a creeper on foruns for some time, I have noticed that very few people make posts about the factorization servos. So after finally making a profile I actually start on a conversation about them which made me want to start this thread. Let's give them servos some love.

I'll start: here is how I automated Crystallizer's with only servos (I say "I" but I got the programming from somewhere else actually)

T9kzHZu.png

(The servo gets the chunks from the slag furnace - which is only decorative here - via a item shifter and goes its merry way in a anti-clockwise loop. It then inputs the chunks in the crystallizer through parasieves, which are basically filters that are saying "this kind of chunk can go here". There are hoppers below the criystallizers that are all pointing into the last two parasieves on the chest. Parasieves also act as extended acess to a inventory.)

here is what you will see in this build:
  1. 16 crystallizers
  2. 18 parasieves
  3. 17 hoppers - taking things out of the crystallyzers and the slag furnace
  4. a bunch o servo rails
  5. a socket and a servo
  6. two item shifters
  7. 16 aqua regia put on slot 5 of the crystallizer (sorry, forgot picture)
  8. Instructions for the servo:
    • Integer;
    • Sum;
    • Product;
    • Compare;
    • Duplicate;
    • item shifter control;
    • socket control;
    • drop;
    • redstone pulse;
    • jump;
    • entry control; and
    • point top.
you will need a logic matrix controller.

This setup especifically is based on processing lead and silver. I do admit it may still require some polishing but it works quite well for me.


Now onward to programming!
(Warning: I highly suggest you take a look at "http://purpleposeidon.github.io/FzDocs/html/" it is documentation on all machines and instructions by Neptunepink up-to-date with version 0.8.29, at least as I am writing this)

2T67xDv.png

(in this picture: the chunks are loaded on the servo via the item shifter. Immedietly after starts the process of changing the slot where it put things.)

Let us say that this is the first run. The chunks will be loaded into the servo, compare will do nothing, jump - set to jump next - will make an error message, but that is only a message that says that there wasn't any information loaded on the servo that it could pull from for it to do its thing. It then will enter the set direction and go in that direction. From then on information will be loaded.
This should be a good time to explain that some instructions generate information and others use them. Generated information stays in a stack, which is made visible if you look at a servo with the logic matrix controller. A instruction that uses information will take the newest generated one for its purpose, and I mean literally take the information out of the stack.
So, continuing: "1" wil add a number 1 to the stack, sum will try to add the last two information and generate a new one, in this case add 1 to nothing and you get 1. last on the line you have a duplicate function, which will duplicate that the newest information and add it again to the stack.

The entry control is there to make the servo prefer to go that way instead of the other. this instruction is on a diferent category which basically deals with movimentation of the servo.



2j8XQPv.png


This part is easier to explain, I believe. after passing by the entry control the servo will go up and the point up instruction will make the direction of the socketed item face that direction.
them you have the item shifter control (there is a picture of the gui of a item shifter below) set to change the targeted slot, it will pull one of the "1''s of the stack and make the item shifter target slot 1 of a inventory (I also cover how to set it up down below)
Last on this picture, the item shifter requires redstone pulse to work which is the job of all those socket controls (the red dots).
I also would like to take the oportunity to explain something. socket control will interact ONLY with the servo, as far as i'm aware, use a redstone pulse instruction for actual sockets ( like in the second picture).

MNN7L3r.png


So after inputing the chunks into the crystallizers, we need to change the targeted slot on the shifter. This part here is basically preparation for reseting the targeted slot. As the servo goes round and round it will put chunks on slot 1, 2, 3 and 4, slot 5 should have the aqua regia, which means that the only slot left is slot 0.
Maybe this is a little confusing but let me get on with the first run example.
Prior to this part you most likely have only a number 1 on your stack. This part here will duplicate that number and right after, it will generate a number "4" on your stack.

R1lwdHk.png


As it continues its path it will start the loop.
The chunks will be loaded into the servo, compare as it is, will pull the last two information on the stack, and see if they are equal. After that it will generate a new type of information that is called boolean. There are two types of booleans: true or false. On the first run it will compare if 4 is equal to 1 and obviously will generate false.
Jump - set to jump next - will try to get a boolean from the stack. Note that instructions, as far as I know, will always check the last generated information on the stack, they will not look through the stack for the last inputed information they can use. If the boolean is true the servo will skip the next instruction, if not, it won't jump the next instruction.
In our first run example the boolean jump got was "false" which means it will NOT "jump" the direction set instruction, which is the next one, so it will go in that direction,"1" wil add a number 1 to the stack, sum will add the last two information, so 1+1=2, so 2 will be generated on the stack and go forth to be set as the target slot.
When compare generates the boolean "true", the direction set instruction will be skiped and the servo will take the longest route around. It will pass over the drop instruction, which drops the latest information from the stack, at this point there should have only be one information on the stack, and now that you dropped it, the stack should be clean. "0" will generate the number 0 on the stack, duplicate will duplicate it and then the slot 0 will be filled.

nI1Zmaw.png

(For this build to work the best, please remember so set "Amount" to 8.)

sKcwAiX.png

("Transfer Mode - stream single item" will make the amount unchangeable)


I will post pictures for how I am doing things, if you have any questions please post it here and I will do my best to answer then for you!

I will be posting some other builds with servos.

And finally, If you say I'm a giant noob and am doing it wrong, well... I am very interested on how you're doing it please post it down below. :)
 
Last edited:

casilleroatr

New Member
Jul 29, 2019
1,360
0
0
Thanks for posting this, I look forward to trying it out.

Could you write captions for the pictures please. Maybe a list of all the instructions one will need at the top as well. That would make this even better. You don't have to post it in mod discussion, you can leave it here. It is a showcase after all.

One thing that I would really like to be explained. What is the significance of the numbers in the yellow stack?
 
  • Like
Reactions: Meirlean

Meirlean

New Member
Jul 29, 2019
3
0
0
Can't tell you how long I've been waiting to see exactly this kind of setup :)
Thank you!

Would love if you could explain what all the instructions do, and why it is set up in this way?

I'm really happy seeing more interest in using Servo's recently.
 

Broomstone

New Member
Jul 29, 2019
38
0
0
Thanks for posting this, I look forward to trying it out.

Could you write captions for the pictures please. Maybe a list of all the instructions one will need at the top as well. That would make this even better. You don't have to post it in mod discussion, you can leave it here. It is a showcase after all.

One thing that I would really like to be explained. What is the significance of the numbers in the yellow stack?

Updated the first post. Is this confusing enough? lol

Instructions with a yellow font (1 and 0, Sum, Product, Compare, Duplicate, Drop and also the instruction boolean which I did not use on this build) have in commom that they generate information on the servos yellow "stack" as how they are called. This information is important because other instructions can pull that information and use it to influence the servos movement, or change configurations specially regarding the item shifter.
 
  • Like
Reactions: casilleroatr

Broomstone

New Member
Jul 29, 2019
38
0
0
Can't tell you how long I've been waiting to see exactly this kind of setup :)
Thank you!

Would love if you could explain what all the instructions do, and why it is set up in this way?

I'm really happy seeing more interest in using Servo's recently.

I updated the first post, so hopefully that is understandable?
 

masterzh

Forum Addict
Jan 6, 2013
292
408
168
Slovakia
Stopping by just to say thanks for sharing. I have no experience with servos and almost forgot they exist.
 

Meirlean

New Member
Jul 29, 2019
3
0
0
I updated the first post, so hopefully that is understandable?
Very much so! This is exactly the kind of info I wish there was more of. Thank you! :)
Can't wait to give this a shot in my world...

Sent from my GT-I9500 using Tapatalk
 

Broomstone

New Member
Jul 29, 2019
38
0
0
Never used Servos. They look really complicated to use.. Are they?

Nice build btw. Thanks for sharing!

Not really, it takes a little while to get used to the "stacks' system, at least it took me, and I'm no programmer nor anything, but I find it very simple, not easy to use though. The only thing you might find yourself sayng is "okay, I know how this works now... but how do I make it do my homework?"


currently I'm working on a semi-automated (for now) wheat farm. One of the issues I still have to tackle is how to trigger the harvesting and replanting of seeds. I was going with a long timer but then comes a wild Neptunepink and points me that in version 0.8.33 there is a thing that can see the maturity of wheat.
I was like "say what now?" then I checked it out to see how it works. But i have not put anything to practice, will be my fun for the weekend.
 

Broomstone

New Member
Jul 29, 2019
38
0
0
Stopping by just to say thanks for sharing. I have no experience with servos and almost forgot they exist.

huh... why did that song "don't you... forget about me" (don't know the name) came into my mind?

You should definetly check them out they make factories much more lively.
 
  • Like
Reactions: masterzh

Khandy_Man

New Member
Jul 29, 2019
3
0
0
Quick question. If the amount is set to 8 on the Item Shifter that's attached to the Slag Furnace then won't the servo use up its available chunks on the first row of Crystallizers and have nothing to insert as it passes over the second row? It seems like the amount should be set to 16 unless I'm misunderstanding something.

Thanks very much for posting this.
 

Broomstone

New Member
Jul 29, 2019
38
0
0
Quick question. If the amount is set to 8 on the Item Shifter that's attached to the Slag Furnace then won't the servo use up its available chunks on the first row of Crystallizers and have nothing to insert as it passes over the second row? It seems like the amount should be set to 16 unless I'm misunderstanding something.

Thanks very much for posting this.

This processing line is built for silver and lead chunks. In the Factorization processing line for silver, you get both of them out of smelting the same item on the slag furnace. The parasieves (the blocks with the giant red cross pattern in them) are item filters. The first row of parasieves are filtering silver chunks and the second one lead chunks.

edit

You are right though. if you are processing only one item you don't need the parasieves and you can put the amount to 16. The amount of crystallizers can be tweaked at will really.
 
Last edited:

Broomstone

New Member
Jul 29, 2019
38
0
0
Holy chicken noises I did it! This took me a very long time to make but I did it! Oh man (or woman) expect some explanations soon because right now I'm just delighted that it works. (I feel goood tanananana... I knew that I would now tanananana..... I feeeel good.......)

Here is a fully automated harvesting and replanting wheat farm only with servos. As I was making this I took as a premise that you simply can't harvest wheat as it turns fully grown, so I designed it so that with a trigger all the wheat is harvested regardless of its maturity, much like a sugarcane farm with a (is it extra utilities?) BUD block (Block Update Detector) trigger and pistons.
Luckly in Factorization version 0.8.33 there is a method to measure the maturity state of wheat! I will go into details later. Basically the trigger is the entire first row of wheat, the one on the left of the first picture, when all the wheat of that row matures, the harvesting and replanting process will start, I'm really happy with this function because it should give the farm a good time to mature. also I've seen a video on vanilla mechanics that said wheat grows faster if planted in rows. Hopefully the servorails don't affect that. Everything harvested will end up in that doublechest.

83oNh1N.png


1O1MN2f.png


I'm a happy man today : )
 
Last edited:

Broomstone

New Member
Jul 29, 2019
38
0
0
MZIelgG.png


Picking up from my last post, I have gotten some feedback on my build from VladTubaka, on the Factorization thread on MCF. He is also a servo enthusiast (i'm going to use this word, yes) who has come up with some very nice builds. Check his blog to see what he has come up with.

So let me start with a finished product:

jf5JpyA.png

this was made using Factorization 0.8.33
I'm going to explain this in parts.

to harvest the wheat I needed to use the lacerator on a servo, however there is a small issue related to this version of Factorization. in this version the servos inventory slots were diminished from 4 slots to 1. But when the lacerator breaks the wheat it not only gets wheat but seeds as well. What happens is that whichever is picked second clogs the servo and the lacerator stops working. To work around that one can use a feature of the servo which is how the servo interacts with a hopper. Just like a chest minecart, I believe, one can "hopper" itens into a servo as well as out of it. So to lay down the harvesting this is what I did:

bNhemHu.png


FIKmnDh.png

As the lacerator travels through the rail the hoppers will continuously empty its inventory and bring the goods to the chest, this way it doesn't clog up and keeps harvesting all the wheat. I'm not sure how much I like this, but I'm okay with it. Now here is how I set up the instructions:

DkenJAE.png


Put the servo on the lone rail at the right of the picture, after that you can pretty much take that rail out.The lacerator servo will stay at the trap until it is triggered (more on how later) then it should go its way push the boolean true to the stack and go down. Now something that might look confusing is that I used a point top instruction instead of a direction set after the boolean instruction. That is because i take advantage of how servos move on rails.

They will always prefer to go straight, then they will try to go up (relative to the direction the socket part of the servo is facing), otherwise they will go randomly, however part of their nature is to always try and go in the same direction they were going before getting to a dead end.

So what the point top instruction is doing is basically setting the top of the servo to be in that direction, and since it is a dead end the servo will prefer to go to the newely set up. after that we set the speed to slow so that it won't skip any wheat. Those last ones are spin instructions they spin the servo 90° degress in the set direction.

Basically the lacerator servo will make two trips around the wheat. The first one should get the wheat inside the rail line and the second one the wheat outside of it.

iqJsiWx.png

Now for the second part I went for replanting. Because of the interactions of servo and hoppers I could not use the same rail for this. That is because the seeds would simply be "hoppered" out of the servo and almost nothing would be planted.So I made a railline that goes above the wheat:

VXwnI4r.png


jtxyUA7.png


nJ0yjxs.png

To plant the seeds you use the robotic arm. For each operation it requires a redstone signal (think about it as a dispenser). To plant in each farmland you need to set a socket signal instruction right above it. Don't worry to much about the places were the rails connect, remember the servo will prefer to go straight. But indeed there are three direction set instructions,as well as a two point top, I needed to place so that it would not get confused in its own rail. The only place you need to put some extra programming into is at the place where the servo will stay still right beside the lacerator:

RN9ZsDB.png


poomHdz.png


iTiM2ho.png

When the lacerator finishes harvesting and goes to its resting place it will pass by a restone pulse instruction that will infuence the robotic arm's trap instruction and let the servo go replant the hole field.

This post is getting a little long so I will finish it here. But basically this is a harvesting and replanting set up almost ready to go. The only thing missing is a automated trigger, and (sigh) this is the part which took me quite a little while to understand.

If I forgot something please let me know.

7nEl3IW.png
 

Nick Dellhall

New Member
Jul 29, 2019
34
0
0
This is awesome, thanks for posting this up. Was trying out servos awhile back but couldn't really wrap it around my head, this post really helps.
 

Broomstone

New Member
Jul 29, 2019
38
0
0
So to continue from my last post, I finished the harvesting and replanting of wheat, what is left is to create a trigger for the system to start. My first thought was to make a very long timer, however there is a feature on Factorization version 0.8.33 that could be used for a much more precise timing. that is a new Decorator, as it was descripted, called "Scan Color" that can read colors from wool, hardened clay and wheat! This adds a new type of information to mess around with, and this is a very important update because it makes use of this colors to access the different colored stacks of the servo!

A feature of these new stacks that is very, VERY, nice is that you can save information in them! And I mean save it forever, as long as you don't break the servo I think.

It will be really hard to explain what I did if I don't explain this, so let me start from there.

1qzWOZl.png

As you can see in the pictures above if a servo pass a scan color decorator with the socket pointed towards a green wool, the scan color will push green (as in the color of the wool) to the yellow stack. something worth noting is that the compare instruction can compare if two information colors are equal (did not try the other comparisons).

Next I'll talk about a new instructions that were added that interact with colors.

They are: Entry Action. Stack Transfer and Run Stack.

nzgwC5Z.png

In order, the first one is entry action. What this instruction does is it changes the behavior of servos towards instructions. It can set that instructions need to be executed immediatly, or that instructions are to be ignored completly. however it can also say that instructions need to be "read" to the I/O stack. I'm sorry if this is out of nowhere but the I/O stack is the white stack, and what I mean by reading is that every instruction the servo goes through will be pushed to the I/O stack as information. Last but not least, it can also tell the servo to write instructions into the servorail.

2dt4GTW.png


SG2aYbF.png

Next is Stack Transfer. This instruction allows you to transfer information from, or to, the I/O stack to, or from, any other colored stack.

Now some things need to be clarified here. Some stacks have diferent ways to deal with information. the black stack is a message board where error messages created by instructions not having any information to deal with will appear. So due to that, I did not even try to mess with it, so maybe it can recieve other information? I have no idea. The yellow stack is the place where information is generated by some instructions, and also is the place where other instructions will look to take information from, for their own purpose. The white stack is the I/O stack. It is especial in the way that it can recieve instructions as information as stated above as well as it is a middleman for inputing information into other stacks. The other colored stacks are information repositories. What this means is that any information transfered to them will be permanently saved into them. There is no way to erase the information they got (I am playing mostly in creative right now so everytime i break a servo, it is destroyed, so I do not know if you break the servo it will retain its information. My guess is no.). The red stack however has a extra feature that will be adressed later.

The stack transfer instruction will take a color to work, since it transfers information from the I/O stack to another or vice-versa.

In the example below I restart the servorail from the last spoiler with the addition of a stack transfer, check out the order from latest to last of the information in the colored stack. See anything different? I will let you find out by yourself.

WJuL9ao.png


DQtFXqp.png

The last Instruction to go over is Run Stack. This instruction will take a color from the yellow stack and push to it all the information and instructions from the corresponding colored stack.

For example, you have a number "1" in the green stack, if the servo scan for the color green and then pass by by Run stack, it will push a "1" to the yellow stack. on the other hand if you have sum in the green stack and two number "1"'s in the yellow stack, then the servo scan for green and goes through run stack, both "1" will be consumed and a 2 will be pushed to the yellow stack.

The red stack however does not need this instruction. Every block, the red stack will run its own stack.

XoPxcEM.png


j6OyaGL.png


Gr6Oerq.png

I would also like to take this time to correct something that I said before. I said that instructions would always look at the latest information for what they wanted, however I was told that this is not true to every instruction.instructions that need specific information will look through the stack for the latest information they can use.

Now, at last, onward to the wheat farm. I said above that scan color can scan the color of wheat right?

lnQYs8H.png


cThtw9d.png

Well from here on out is all about experimentation. The main goal was to find a way to make the harvest/replant cycle start after all the wheat had grown, since the idea is to harvest it all in lot. However that is not possible with the field size i was going for. mainly because a stack can only hold 16 information. Maybe there is a way? I'm not sure. So I conformed myself to make the check for 16 wheat, when all of this wheat are fully grown the harvest will start.

3r2j5dq.png


E0tOPFH.png


rv7PtHH.png


1YaHsge.png

With the servorail done all that was left was to program the servo.

fZZKrVf.png


srkXnPi.png


50gTCZI.png


TBeUA1I.png


XdwEban.png

There are 16 Sum instructions there.

And that is the build done! Having to wait for 16 wheat might be a little to long though, So I think I might tweak it but that is very simple, just take one scan color and one run stack per wheat I don't wnat to wait grow. And the wheat takes its sweet time growing up so I have already put a new part to it that comes in two flavors. One bonemeals it constantly, the other just bonemeals it once just to kickstart it. That is really optional at the end.
 
  • Like
Reactions: Lathanael

Lathanael

New Member
Jul 29, 2019
959
0
0
Impressive work you've done there :)

This really confirms my point that servos are while albeit a bit more complicated hands-down one of the most versatile automation tool in current modded minecraft.
 

Broomstone

New Member
Jul 29, 2019
38
0
0
Impressive work you've done there :)

This really confirms my point that servos are while albeit a bit more complicated hands-down one of the most versatile automation tool in current modded minecraft.

thanks! yeah I believe they have many uses more to come. After this I tried to give it a go at a sorting system, I came up with something fairly simple based on a 1.4.7 favourite, barrel room storage. Even found a way for a crude requesting system but although it is functional I think it is more of a nice thing to see then practical, compared to AE or logistics pipes.
 

Lathanael

New Member
Jul 29, 2019
959
0
0
thanks! yeah I believe they have many uses more to come. After this I tried to give it a go at a sorting system, I came up with something fairly simple based on a 1.4.7 favourite, barrel room storage. Even found a way for a crude requesting system but although it is functional I think it is more of a nice thing to see then practical, compared to AE or logistics pipes.
Hmm a request system with servos? sounds....interesting.

Ofc it can not be compared to either AE or LP as those are mods written specifically for that purpose. But i can think of something more RP2 like with its pneumatic pipes.