Krolyxon
Commit 2fb5bba

Branches

Tags

Refs →

bench512fb5bba

add examples

Author
krolxon
Date
2026-01-05 00:11 +0530
Parent
49e6897
Commit
2fb5bbaa8d97a390b3175026040709c762cb93ec

+10 −12

4 files changed

  1. M README.md +2 −2
  2. A examples/addition.asm +4 −0
  3. A examples/subtraction.asm +4 −0
  4. D program.asm +0 −10
M README.md View
@@ -1,6 +1,6 @@
11 # 8-Bit CPU Emulator
22
3−## Added instructions
3+## Supported Instructions
44 1. MOV
55 2. ADD
66 3. SUB
@@ -11,7 +11,7 @@
1111
1212 # Usage
1313 ```bash
14−cargo run -- --f <filename.asc>
14+cargo run -- --f <examples/filename.asc>
1515 ```
1616
1717 ## Todo
A examples/addition.asm View
@@ -0,0 +1,4 @@
1+mov a, 10
2+mov b, 5
3+add a, b
4+hlt
A examples/subtraction.asm View
@@ -0,0 +1,4 @@
1+mov a, 15
2+mov b, 15
3+sub a, b
4+hlt
D program.asm View
@@ -1,10 +0,0 @@
1−; add
2−mov a, 10
3−mov b, 5
4−add a, b
5−
6−; sub
7−mov a, 15
8−mov b, 15
9−sub a, b
10−hlt