Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorganizing #3

Merged
merged 4 commits into from
Aug 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,43 @@ Expected output:
0610: fb 60 00
```

## Data types
Compiler works with primative date types.

### Byte
It takes up one byte of space. It is written in three different ways depending on the number type.
Examples:
```assembly
$01 ; in hexadecimal format
$CC ; in hexadecimal format

%00000000 ; in binary format
%01010011 ; in binary format

128 ; in decimal format
2 ; in decimal format
```

### Word
It takes up two bytes of space. It is written in three different ways depending on the number type.
Examples:
```assembly
$0122 ; in hexadecimal format
$CC33 ; in hexadecimal format

%0000000000000000 ; in binary format
%0101001100000000 ; in binary format

123456 ; in decimal format
888888 ; in decimal format
```

### Ascii
It takes up different sizes of space depending on the definition. The text must be written between double quotes.
```assembly
"Hello world" ; in decimal format
```

## Available directives

### .org
Expand Down Expand Up @@ -105,6 +142,17 @@ Print warning message on compilation time.
22:05:16 [WARN] timu6502asm compiler works partial
```

### .include
Import another file.
```assembly
.include "header.asm"
.include "body.asm"
.include "footer.asm"
```
```
22:05:16 [WARN] timu6502asm compiler works partial
```

There are many things to do. Here are the some todos:
- [ ] Case insensitivity
- [ ] Rom file generation
Expand Down
Loading
Loading