This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
croswat's profile picture

Redstone Logic Gates

Started by croswat, 06 May 2013 - 11:37 PM
croswat #1
Posted 07 May 2013 - 01:37 AM
Hello Everyone!

Me and VikeStep have created a program that is 9 different logic gates in 1!

In this program, the computer is the gate and it acts just like the RedPower logic gates except that you can choose your outputs/inputs from all 6 sides.

Features:
AND, OR, NOT, NOR , NAND, XOR, XNOR, Repeater and Timer (More is planned in future versions)
Choose which sides are inputs/outputs
Timer and Repeater Delay is easy to enter
Optimised to be less laggy than existing RedPower Gates (especially timers)
PLEASE NOTE: Walking away from a computer turns it off, when you walk back in range the computer will resume what it had before

How to install it:
1. Place your computer and type: pastebin get zP73LSsm startup
2. Hold ctrl+r for 2 seconds to reboot your computer
3. Follow the instructions from there

Want to see the code before you download it? View it here

Planned Features:
Toggle Latch
Pulse Former
Multiplexer
Synchronizer
Sequencer
Counter
Comparator
Redstone Torch with toggleable sides
NOR Latch
State Cell
Null Cell
Randomizer
Transparent Latch
Invert Cell
Non-Invert Cell
Light Sensor

Pictures:

Starting Menu:
http://i.imgur.com/kvmyOwn.png
Choosing Inputs/Outputs:
http://i.imgur.com/cBnd5R7.png
AND Gate with left and front as inputs, right as output. Off
http://i.imgur.com/Syy5aho.png
Same gate as above but on
http://i.imgur.com/HRIE7rz.png

Changelog:
v1 Initial Release Comes with AND, OR, NOT, NOR , NAND, XOR, XNOR, Repeater and Timer

Other information/FAQ:
Why should we use this instead of RedPower Logic Gates?
Firstly, some people don't use RedPower, secondly, it adds the ability to input/output from sides of your choice (including on top and bottom of the computer) and thirdly, this is every logic gate in one providing much better ease of access


Will i need to retype the information when the computer shuts down?
If you followed the instructions and saved this to startup it should automatically resume what you had

I have a bug?! or Can you please add this?!
Please post it in this thread

Why is the conditions in a 3-input XOR gate that it must have an odd number of "on" inputs?
XOR means in literal terms one or the other, but not neither nor both. However this is true for two inputs, a 3 input xor gate is the result of the first two combined with the third input. So if all inputs are on, the first two will combine to create an off value and then this result combines with the third input which is on and since both inputs differ the result is on. This pattern can be summarised to having an odd number of "on" inputs

Can I use this in my YouTube LP or on my server?
Go ahead, as long as you don't claim it as your own work and if possible, link to this page so that others can use it too
M4sh3dP0t4t03 #2
Posted 07 May 2013 - 09:08 AM
looks nice. i have made something like this, just look in my signature
Dlcruz129 #3
Posted 08 May 2013 - 11:01 AM
Very nice! Good job on the cube.
svdragster #4
Posted 08 May 2013 - 04:07 PM
Cool! But can you add the function to automatically start a gate with custom settings? Would of course need some fs.open() stuff.