Skip to content

moocf/4004-assembler.nodejs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Assembler for Intel 4004 microprocessor, written in javascript. Despite being the first 4-bit microprocessor from Intel, the 4004 has a surprisingly complex opcodes. However, the opcode table is simple enough. Also, it is important to mention that this assembler only accepts numbers for registers and conditions, instead of names or symbols. It is a very crude assembler.

Image
The source file test.asm with 4004 instructions.

Image
Run assembler as node main <destination> <source>.
Here it is node main test.bin test.asm.

Image
test.asm is converted into test.bin.

Image
test.bin contains machine code for 4004.

Image

About

Intel 4004 assembler, for learning.

Resources

Stars

Watchers

Forks