Template:Mcrs diagrams
WARNING: Since now I am part of AngryCookieGames team, I am rolling a YouTube series that explain everything about redstone. Further in the series, I will get to the calculator how-to.
This is my first big Minecraft project, and also it is the first time I will be explaining this to others. If I will not explain clearly, you should check the tutorials I am based on.
簡歷
這是我已經建立了目前的計算機的計劃: 文件:計算器plan.png的 計算器計劃 文件“:Calcplan.png” 計算器計劃
當然,所有編譯的二進制代碼。這就是為什麼我們有很多不同的解碼器。
目前的零件
I will try to go in a somewhat logic order to describe the parts.
我会努力的去用点逻辑顺序来描述零件。
Control Panel (room)控制面板(室)
The control panel is the room from which you set the inputs and decide of the operation 控制面板的房间,你设置输入和操作的决定
Numbers Input Panel数字输入面板
Numbers Input Panel
Here, the user will decide what numbers he wants to use. Right now, I am using a lever-based binary input system, so the user has to decompose the numbers he wants to use into powers of two. 【[文件:输入面板。PNG | 250px |拇指|右|数字输入面板] ]在这里,用户将决定他要用什么号码。现在,我使用基于二进制输入系统的杠杆,所以用户必须分解,他想用为权力两个数。
Operation Panel
操作面板从这个面板,用户选择操作,他要用之间:加(+),减(-),乘(*)、除(/)。再次,现在,我使用的杠杆系统。【[文件:操作面板。PNG | 250px |拇指|左|操作面板] ]
From this panel, the user chooses between the operations he is going to use : add (+), subtract (-), multiply (*) and divide (/). Again, right now, I am using the lever system.
Operation Panel
Input Wires (white and orange)
输入线(白色和橙色) 这些电线连接输入面板和不同的逻辑单元的操作面板。试着去改变他们的方式相同的价值观去一起。所以,你的电线看起来应该像这样,从左到右:A1,A2 B2 B1;;;;A4 B4;… These wires link the input panel and the operation panel to the different logic units. Try to rearrange them in a manner where the same values go together. So, your wires should look like, from left to right: A1; B1; A2; B2; A4; B4; ...
Logic Units
逻辑单元 这是执行的操作的机器。 These are the machines that perform the operations.
Adder/Subtractor (yellow and red)
====加法器/减法器(黄色和红色)= = = =
注:这个计划,减法器和加法器是分开的。我会尽量尽快我可以修复它。”我已经建立了自己的版本的一个加法器/减法器。它的结构是简单的因为它是调制(由许多相同的部件)。这意味着,如果你使用更多的位,你可以添加更多的部分就在身边,但你不得不改变一些链接。
【[文件:加减器。PNG | 330px |拇指|加法器/减法器,左| ] ]在这台机器上,您的输入(二进制代码)进入底(黄色)[ [教程/ advanced_redstone_circuits # alternate_full_adder |全加器] ]。
每一个加法器需要两个输入(A和B)具有相同的值。而且,最重要的一点要在左边,所以他们都应该由他们进行连接。基本上,你的输入如丝在[ [ #输入线(白色和橙色)] ]部分。使用基本的桥梁,通过导线连接在别人。你的一个输入(左)是被减数(x在X-Y = Z),走在加法器。B你输入,减数(Y在X-Y = Z),必须通过一个多路复用器,由一个[ [ redstone_circuits # xor_gate_修改后的版本。28。e2.8a。BB。29 |异或门] ]给加法器的反转信号在一个减法的案例。多路复用器是由一个开关控制(图上,开关在左边)。和进入另一个多路复用器,其中,再次,给出了一个反相输入在减法案例。这是一个[ [ redstone_circuits # implies_gate_控制。28。e2.86.92.29 |意味着门] ](右上方)给出了一个真实的输出,如果开关在“减法”,如果最后一把是真的。这是因为在一个减法,最后进行实际上意味着“-”(减号)标志。
白色的机器是[ [教程/ advanced_redstone_circuits # half_adder |半加法器] ],使用,作为输入,最后的加法器的进位和各自的全加法器的总和。我们需要这个因为,如果答案是否定的,它使用的方程”a!一个(倒一)+ 1”,正如[ [维基百科:加法器–减法器|这里] ]。最后的输出是所有的最上方的电线可以观察,加钢丝在右侧(从最后的全加法器进位)和携带,在第一(左)半加法器,为否定符号。
NOTE: On the plan, the subtractor and the adder are separated. I will try to fix it as soon as I can.
I've built my own version of an adder/subtractor. Its construction is simple because it is modulated (made of many same parts). That means that if you use more bits, you can just add more parts on the side, but you'll have to change some links.
2-in-1 Adder/Substractor
In this machine, your inputs (in binary code) goes into the bottom (yellow) full adders. Each adder needs the two inputs (A and B) with the same values. Also, the least significant bit has to be on the left, so they should all be connected by their carries. Basically, your inputs look like the wires in the #Input Wires (white and orange) section. Use basic bridges to pass wires over the others without connecting them. Your A inputs (left) are the minuend (X in X-Y=Z), and go straight in the adders. The B inputs, your subtrahend (Y in X-Y=Z), have to pass through a multiplexer, made out of a modified version of a XOR gate which gives to the adder an inverted signal in case of a subtraction. The multiplexer is controlled by a switch (on the picture, that switch is on the left). The sums go into another multiplexer, which, again, gives an inverted input in case of a subtraction. This is controlled by an IMPLIES gate (in the top right) which gives a true output if the switch is on "Subtraction" AND if the last carry is true. This is required because on a subtraction, that last carry actually means the "-" (minus) sign.
The white machines are half-adders, that use, as inputs, the carry of the last adder and the sum of their respective full adder. We need this because, if the answer is negative, it uses the equation " -A = !A (inverted A)+ 1 ", as explained here.
The final outputs are all of the top-most wires you can observe, plus the wire on the right (the carry from the last full adder) and the carry that goes in the first (left) half-adder, as the negation sign.
Multiplier (light blue)
Let's start with the basics here, because this is the most complicated part. As you should know, if you went to school, multiplication is a repeated addition. That means that, once again, we will use adders here.
Before them, you actually have to set up an AND gate (not including the control one). Its use is simple : in binary multiplication, because we only use 0's and 1's, the only way that we can have an output is by multiplying 1 by 1.
I will go in order from the least to the most significant bits.
Least significant bits :
1*1 = 1. That means that the output of the second AND gate (the control one) goes straight to the output collective wires.
Second to last:
1*2 = 2 and 2*1 = 2.
Those two outputs meet in a full adder. The sum goes to the output, and the carry goes to the next bit.
Next:
1*4 = 4; 2*2 = 4; and 4*1 = 4
The carry from the last bit goes in the first adder as the carry input. The two normal inputs are 2 of the 3 AND gates. The sum of this goes in a second adder, where the second input is the third AND gate. Both carry outs go to the next stage, and the sum goes to the output.
You continue like this until you run out of AND gates, or equations.
Divider (pink)
This one is an easy one compared to the multiplication. Again, we will be using the full adders. Basically, for each A input, set up n adders where n=number of B inputs. Also, this time, you have to "reverse them". Now the most significant bit should pass its carry downwards.
Output wires
These have to get every output from every machine and redirect them to the next part.
Binary-to-decimal decoder
This transforms your binary code into a decimal output. The size of it will be (Binary inputs*2)*(Decimal outputs*2).