Redstone: Difference between revisions

From Novylen Minecraft
Jump to navigation Jump to search
(Created page with "<!-- REDSTONE COMPUTING IN MINECRAFT --> = Redstone Computing in Minecraft = {{Infobox | title = Redstone Computing | image = 300px | caption = A basic redstone calculator in Minecraft | creator = Mojang Studios | introduced = Alpha v1.0.1 (2009) | complexity = ★★★★☆ | realworld_eq = Digital Logic Circuits }} '''Redstone computing''' in ''Minecraft'' represents one of the most fascinating in-ga...")
 
No edit summary
Line 1: Line 1:
<!-- REDSTONE COMPUTING IN MINECRAFT -->

= Redstone Computing in Minecraft =
= Redstone Computing in Minecraft =
<noinclude>{{DISPLAYTITLE:'''Redstone Computing in Minecraft'''}}</noinclude>
{{Infobox
<includeonly>{{#ifeq:{{NAMESPACE}}|Template|<!-- No header in template space -->|<div style="border:2px solid #AA0000; padding:10px; background:#111; color:#eee; font-family:monospace;">''An expert-level breakdown of Minecraft's most complex redstone systems.''</div>}}</includeonly>
| title = Redstone Computing
| image = [[File:Redstone_computer.png|300px]]
| caption = A basic redstone calculator in Minecraft
| creator = Mojang Studios
| introduced = Alpha v1.0.1 (2009)
| complexity = ★★★★☆
| realworld_eq = Digital Logic Circuits
}}


== ⛏️ Overview ==
'''Redstone computing''' in ''Minecraft'' represents one of the most fascinating in-game engineering systems, mimicking digital logic through in-game mechanics.
{{#tag:div|Redstone in Minecraft allows players to build in-game digital circuits that simulate real-world logic. This article explores how redstone achieves everything from basic gates to full Turing-complete machines.|class="mw-collapsible mw-collapsed"}}


== 🔍 Overview ==
== 🔣 Logic Gate Emulation ==
{{#tag:pre|
Redstone enables players to build:
===[ NAND Gate Layout ]===
* **Logic gates** (AND, OR, NOT)
INPUT A ●──────┐
* **Memory circuits**
* **Binary adders**
INPUT B ●──────┼────┐
* **ALUs (Arithmetic Logic Units)**
│ │
* Fully working **Turing-complete computers**
[BLOCK][TORCH] ───● OUTPUT (1 when A or B is 0)
|lang="text"}}


== 🧰 Components ==
== 🧠 Conditional Execution ==
<syntaxhighlight lang="text">
<div class="mw-collapsible mw-collapsed">
{{#ifexpr: {{CURRENTTIME}} < 1200 | Morning Redstone Check | Evening Tick Calibration }}
'''Basic Components'''
</syntaxhighlight>

== 🧮 Binary Addition Table ==
{{#tag:pre|
A B Cin | Sum Cout
---------+----------
0 0 0 | 0 0
0 0 1 | 1 0
0 1 0 | 1 0
0 1 1 | 0 1
1 1 1 | 1 1
|lang="text"}}

== 🧰 Components Overview ==
<templatedata>
{
"params": {
"Component": {
"label": "Component Name",
"description": "The redstone part",
"type": "string",
"required": true
}
}
}
</templatedata>

=== Main Parts (text-only, collapsible) ===
<div class="mw-collapsible mw-collapsed" style="border:1px dashed #ccc; padding:5px;">
'''Redstone Components:'''
* Redstone dust
* Redstone dust
* Repeater
* Redstone torch
* Comparator
* Redstone repeater
* Lever / Button
* Redstone comparator
* Torch
* Piston / Sticky piston
* Observer
* Observer
* Block update (BUD)
* Lever, button, pressure plate
</div>
</div>


== 🧠 Logic Gates ==
== 🔄 Tabbed Examples ==
=== NAND Gate Example ===
<syntaxhighlight lang="lua">
-- Pseudocode for NAND gate in Minecraft
InputA = lever1
InputB = lever2
Torch1 = NOT(InputA AND InputB)
Output = Torch1
</syntaxhighlight>

== 🏗️ Build Example: 4-bit Adder ==
=== Circuit Schematic ===
[[File:4-bit-adder-diagram.png|thumb|400px|4-bit ripple-carry adder]]

=== Truth Table ===
{| class="wikitable"
|+ 1-Bit Adder Truth Table
! A !! B !! Carry In !! Sum !! Carry Out
|-
| 0 || 0 || 0 || 0 || 0
|-
| 0 || 1 || 0 || 1 || 0
|-
| 1 || 1 || 1 || 1 || 1
|}

== 🔄 Tabs: Compare Real Logic vs Redstone ==
<tabs>
<tabs>
<tab name="Real Logic">
<tab name="Truth Table">
{{#tag:pre|
Uses transistors, voltage, silicon wafers.
A | B | OUT
---+---+-----
0 | 0 | 0
0 | 1 | 1
1 | 0 | 1
1 | 1 | 1
|lang="text"}}
</tab>
</tab>
<tab name="Redstone Logic">
<tab name="Tick Delay">
'''Repeaters'''
Uses torches, dust, blocks, and game ticks.
: Each set to 1–4 ticks (0.1s per tick)
'''Comparator'''
: Lagless delay, mostly for analog signal smoothing
</tab>
</tab>
</tabs>
</tabs>


== 🖼️ Gallery ==
== 🧬 Memory Cells ==
=== RS NOR Latch ===
<gallery mode="packed" heights="150">
{{#tag:pre|
File:Redstone_ALU.png|Redstone ALU
SET ●─────┐
File:Redstone_memory_cell.png|1-bit memory cell
File:Redstone_clock.png|Redstone clock circuit
└───[T]───● Q
</gallery>
RESET ●────┘ ⊕ (Q NOT)
|lang="text"}}


== 🏗️ ALU Configuration (ASCII Model) ==
== 🧮 Redstone Calculator ==
{{#tag:pre|
* Supports **addition**, **subtraction**, and limited multiplication
┌────[ XOR ]────┐
* Inputs are binary levers
A ───▶ ├───▶ SUM
* Outputs via lamp displays or droppers
└────[ AND ]────┘
B ───▶ ├───▶ CARRY
|lang="text"}}


== 🧾 Runtime Logic Using Parser Functions ==
=== Example: 3 + 2 ===
{{#ifexpr: {{CURRENTWEEK}} mod 2 = 0
<syntaxhighlight lang="javascript">
| '''Even Week''': Time to test ALU throughput
Input A: 011
| '''Odd Week''': Run memory cell regression tests
Input B: 010
}}
Output: 101
</syntaxhighlight>


== ⏱️ Tick Timing Analysis ==
== 🧬 Turing-Complete Machines ==
{| class="wikitable"
[[File:Redstone_Turing_Machine.gif|right|250px]]
|-
* Players have built entire CPUs and RAM arrays
! Circuit Type !! Delay !! Tick Count !! Game Time
* Capable of running **Brainfuck** or **assembly-style** code
|-
* Demonstrates real-world computing principles
| Pulse Extender || 4R + 2C || {{#expr: 4*2 + 2 }} || {{#expr: (4*2 + 2)*0.1 round 2}}s
|-
| T Flip-Flop || 3 || 3 || 0.3s
|}


== 🧩 Advanced Template Logic ==
== 🧠 Conditional Template Logic ==
{{#switch: {{CURRENTDAYNAME}}
{{#switch: {{uc:{{CURRENTDAYNAME}}}}
| MONDAY = '''Logic Gate Audit'''
| Monday = Today is logic gate maintenance day!
| TUESDAY = '''Tick Testing'''
| Tuesday = Today is comparator calibration day!
| WEDNESDAY = '''Memory Module Optimization'''
| #default = It's redstone playtime!
| #default = '''Experimental Mode Enabled'''
}}
}}


== 📦 Pseudo-BIOS (Logic Flow Simulation) ==
== ⌛ Tick Timing ==
{{#tag:pre|
Using {{#time:H:i, F j|now}} game ticks:
[BOOT] --> [CLK] --> [MUX] --+
* 1 redstone tick = 0.1 seconds
|
* Common pulse generators use repeaters set to 2-4 ticks
+------>[ALU]--->SUM
|
[REGISTERS]
|lang="text"}}


== 🔗 See Also ==
== 📚 Related Concepts ==
* [[Computational Universality]]
* [[Redstone]]
* [[Minecraft Engineering]]
* [[Turing Machine]]
* [[Redstone Simulator (External Tools)]]
* [[Computational Universality in Games]]


== 📚 References ==
== 🧠 See Also ==
* [[Logic Gates in Minecraft]]
<references>
* [[Timing Circuits]]
<ref name="wiki">https://minecraft.fandom.com/wiki/Redstone_circuit</ref>
* [[Analog Redstone Mechanics]]
<ref name="cpu">https://www.youtube.com/watch?v=wgJfVRhotlQ</ref>
</references>


== 📂 Categories ==
== 📂 Categories ==
[[Category:Redstone Engineering]]
[[Category:Redstone Engineering]]
[[Category:Minecraft Computing]]
[[Category:Minecraft Logic Design]]
[[Category:Game Logic Systems]]
[[Category:Turing-Complete Systems]]
[[Category:Expert Builds]]

== ⛓️ Navbox ==
{{Navbox
| name = Minecraft Engineering
| title = Minecraft Engineering Topics
| group1 = Mechanics
| list1 = [[Redstone]] • [[Pistons]] • [[Observers]]
| group2 = Advanced Builds
| list2 = [[Redstone Clock]] • [[Binary Adder]] • [[Turing Machine]]
}}

Revision as of 06:17, 2 May 2025

Redstone Computing in Minecraft

⛏️ Overview

Redstone in Minecraft allows players to build in-game digital circuits that simulate real-world logic. This article explores how redstone achieves everything from basic gates to full Turing-complete machines.

🔣 Logic Gate Emulation

===[ NAND Gate Layout ]===
INPUT A  ●──────┐
                 │
INPUT B  ●──────┼────┐
                 │    │
              [BLOCK][TORCH] ───● OUTPUT (1 when A or B is 0)

🧠 Conditional Execution

<syntaxhighlight lang="text"> {{#ifexpr: 02:07 < 1200 | Morning Redstone Check | Evening Tick Calibration }} </syntaxhighlight>

🧮 Binary Addition Table

 A B Cin 

🧰 Components Overview

<templatedata> {

"params": {
 "Component": {
  "label": "Component Name",
  "description": "The redstone part",
  "type": "string",
  "required": true
 }
}

} </templatedata>

Main Parts (text-only, collapsible)

Redstone Components:

  • Redstone dust
  • Repeater
  • Comparator
  • Lever / Button
  • Torch
  • Observer
  • Block update (BUD)

🔄 Tabbed Examples

<tabs> <tab name="Truth Table">

 A 

</tab> <tab name="Tick Delay"> Repeaters

Each set to 1–4 ticks (0.1s per tick)

Comparator

Lagless delay, mostly for analog signal smoothing

</tab> </tabs>

🧬 Memory Cells

RS NOR Latch

 SET ●─────┐
           │
           └───[T]───● Q
           │
RESET ●────┘         ⊕ (Q NOT)

🏗️ ALU Configuration (ASCII Model)

      ┌────[ XOR ]────┐
A ───▶                ├───▶ SUM
      └────[ AND ]────┘
B ───▶                ├───▶ CARRY

🧾 Runtime Logic Using Parser Functions

{{#ifexpr: 19 mod 2 = 0

 | Even Week: Time to test ALU throughput
 | Odd Week: Run memory cell regression tests

}}

⏱️ Tick Timing Analysis

Circuit Type Delay Tick Count Game Time
Pulse Extender 4R + 2C {{#expr: 4*2 + 2 }} {{#expr: (4*2 + 2)*0.1 round 2}}s
T Flip-Flop 3 3 0.3s

🧠 Conditional Template Logic

{{#switch: SUNDAY

| MONDAY = Logic Gate Audit
| TUESDAY = Tick Testing
| WEDNESDAY = Memory Module Optimization
| #default = Experimental Mode Enabled

}}

📦 Pseudo-BIOS (Logic Flow Simulation)

[BOOT] --> [CLK] --> [MUX] --+
                            

📚 Related Concepts

🧠 See Also

📂 Categories