An Enigma Machine written in 6502 assembly
Read the blog post about this project here
Install for Mac here https://formulae.brew.sh/formula/xa
More info here https://www.floodgap.com/retrotech/xa/
Step 2: Clone x6502 (6502 emulator)
git clone https://github.com/haldean/x6502
cd x6502
gcc -o x6502.bin -O3 -lpthread -Wall -lncurses -Werror -Wimplicit-function-declaration *.c
⚠️ You might get an error likedebug.c:2:10: fatal error: 'debug-names.h' file not found
. I solved it by commenting out thedump_cpu
function inx6502/debug.c
and line 2 with#include "debug-names.h"
. You don't need this stuff to run the program (who needs debug functionality?)
While being in ./x6502
run:
xa -w -Istdlib/ ../src/main.asm && ./x6502 a.o65
Tip:
^C
to exit program
If you want to look at a more easily comprehensible program, there is a file called caesar-cipher.asm
in this repository.
xa -w -Istdlib/ ../caesar-cipher.asm && ./x6502 a.o65
Tip: Type
e
(as the first thing) to choose encryption ord
to choose decryption
This project is licensed under the MIT License - see the LICENSE file for details.