summaryrefslogtreecommitdiff
path: root/README
blob: 6ca26b3cbdfae21c514d5247cf49e0af25bfca8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
=============================== nand2tetris ==============================

Nand to Tetris (https://www.nand2tetris.org/) is a course available online
that teaches you to build a modern architecture computer all the way up
from NAND gates. The course features 12 projects. I have completed the
first half, i.e. hardware and assembly.

List of projects completed thus far:

01 - Elementary logic gates, e.g. AND, XOR, and (De)Mux
02 - Combinatorial chips that do math, including ALU
03 - Sequential chips, e.g. Register, RAM, and program counter
04 - Assembly
05 - Computer
06 - Assembler

Directory structure:
projects/
	00/
		coursera-related meta files
	01/
	02/
	03/
		the three dirs above contain HDL files, with suffix ".hdl". The
		syntax is specific to this course, so your text editor may fail
		to highlight them. Each HDL file is accompanied by a ".cmp" and
		a ".out" file for debugging purposes.
	04/
		contains assembly, also specific syntax. Suffix is ".asm".
	05/
		HDL again.
	06/
		I wrote two implementations of the assembler: the first in C and
		the other in Python (I regret doing it in this order). You may
		compile the C program with:
		$ gcc hack-as.c -o hack-as
		Then invoke it with:
		$ ./hack-as <input.asm>
		which will output binary code in ASCII 0's and 1's to a file with
		suffix ".hack".
	07/
	08/
	09/
	10/
	11/
	12/
tools/
	This directory contains the software suite. Consult nand2tetris
	website for	details.