I built an ALU by using Henke9600's adder. (Thanks to the RDF's Plot O' Logic). It's small (tiny really), fast (4 ticks), and has the XOR output on the top and the AND gates at the bottom.
To turn that into an ALU requires:
1) A multiplexer to select which output to use (XOR, ADD, or AND).
2) Selectively invert or block the A and B inputs.
3) Selectively invert the output.
4) Optionally add left and right shift and rotate.
This will allow ADD, SUB, AND, NAND, OR, NOR, XOR, XNOR, Increment, Decrement, A, !A, B, !B, etc...
Mr.Denco - I hope you're right about my next ALU being smaller, because my current one is about 50 blocks long! It's 7 ticks though, so that's not too bad.
- Registered Member
Member for 9 years, 7 months, and 24 days
Last active Tue, Dec, 25 2012 12:38:38
- 0 Followers
- 62 Total Posts
- 1 Thank
Dec 20, 2012One of the key pieces of a computer (and in my opinion one of the trickiest) is the Program Counter.Posted in: Redstone Discussion and Mechanisms
A good program counter has the ability to Increment, Load a value, and Reset.
The clock usually drives the program counter. To perform a JUMP instruction, the P.C. needs to load a value, and this will usually limit how fast the clock can go. If you increment the program counter before the load finishes, you will be at the wrong instruction.
Nov 26, 2012SkyshockX posted a message on Things People Want In Minecraft But Aren't AlreadyI would like longer wires. Something in the 63 block range would be very useful. The wiring in redpower is just AWESOME and blows away all of the limitations of basic game. Do you think Mojang could give us a little of that?Posted in: Suggestions
Nov 26, 2012By the time I can make a large automatic farm, I'm no longer very resource limited, so I don't need a large farm.Posted in: Redstone Discussion and Mechanisms
I find several small farms are much more useful. (They're still automated of course.)
Nov 26, 2012SkyshockX posted a message on I discovered a way to automatically make phantom blocksThat would make a wicked "draw bridge" for an adventure map. Cross it the first time and fall in, then on the way back it could use solid blocks.Posted in: Redstone Discussion and Mechanisms
Thanks for the simple to understand version.
Nov 25, 2012I would rather see redstone travel further between repeaters. 15 blocks is really short. Redpower allows signals to go 255 blocks.Posted in: Redstone Discussion and Mechanisms
I don't think it needs to go the that extreme, but 63 seems like a reasonable length.
Nov 24, 2012SkyshockX posted a message on Light Show Concept - Control Beacons To Make Amazing Light ShowsThat's really cool.Posted in: Redstone Discussion and Mechanisms
Nov 11, 2012My recommendation is to start with a simplified 4 bit prototype computer. This lets you get you head around all the main pieces, and how they all fit together, without wasting a ton of time on bus layout early on.Posted in: Redstone Discussion and Mechanisms
Most MC computers use the Harvard architecture http://en.wikipedia.org/wiki/Harvard_architecture - meaning the program is in a ROM that is distinct from the RAM. These are usually on separate address buses.
Computers have the following components:
Clock - Drives the program counter.
PC = Program counter - Keeps track of what instruction to execute next. Hans Lemurson has a nice tutoriial about his at: http://www.minecraftforum.net/topic/1064957-high-quality-components-branching-program-counter/#entry13157615
Address Decoder = Takes the output from the PC and selects 1 line from the ROM.
ROM = Read Only Memory. Where the program and constants are stored.
That's the easy stuff out of the way. Next is:
Instruction Decode = This is what lets the instructions in the ROM have meaning. You'll have to decide you want a computer to be able to do (the "Instruction Set") before you can build this piece.
Address Bus and Decoder: Some computers can Read and Write simultaneously. This takes two separate address busses.
Data Bus: Because repeaters only send signals one way, MC computers have a Read data bus, and a Write data bus. Sometimes these are connected.
RAM = Read Only Memory - This stores input values, intermediate calculations and final results. Hans Lemurson has designed RAM that is 2x2x14. The more compact the RAM, the fewer repeaters you can use, and the faster the computer can run.
ALU = Arithmetic Logic Unit. For this part you can start with a good Adder, and then extend it. Henke9600 made a compact 4 tick insta-carry adder that has the XOR outputs on top and the AND results on the bottom. Add selective inverting of the inputs, the outputs, a way to block the inputs, multiplexers to select between XOR, ADDER, or AND, and tack left and right shift to complete your ALU.
Finally, the fun stuff:
7 Segment Display.
tl;dr: A lot of YouTube, MC forums, Wikipedia, and Google in the near future, but the information is out there and you can do it.
Nov 6, 2012SkyshockX posted a message on Multiple signals over one wire by pulse length encodingThat is a very clever system you've developed. Very nice.Posted in: Redstone Discussion and Mechanisms
Nov 4, 2012SkyshockX posted a message on 1 Block Wide Redstone Clock (Super Compact) (tutorial)That is a nice, compact, and simple design. A torch on the output would let the output be off when the clock is not running.Posted in: Redstone Discussion and Mechanisms
Nov 4, 2012SkyshockX posted a message on 1-tick pulse limiter: Why doesn't a 2-tick delay work?henke9600 - That video is BRILLIANT! Perfectly shows how idiosyncratic, and problematic redstone behavior is.Posted in: Redstone Discussion and Mechanisms
Oct 13, 2012I'm not sure, but I think this may be related.Posted in: Redstone Discussion and Mechanisms
I've found some odd behavior with fast clocks and repeaters.
If you have a 2 clock with opposing repeaters feeding into a repeater at the output you will get the expected 1 On, 1 Off behavior.
HOWEVER if the 2 clock feeds into a piece of redstone dust, then a repeater you will get a 3 On, 1 Off behavior.
This seems to happen in directions f1, f2, and f3. f0 seems to always produce the 3 on, 1 off behavior.
- To post a comment, please login.