vimwiki/games/tis-100/TIS-100.wiki

75 lines
1.7 KiB
Plaintext

= TIS-100 =
TIS-100 is an assembly programming game. The following are notes that I have
taken regarding the game. I do not plan to use these, only to type them to help
commit to memory
== Important ==
== Registers ==
* ACC - accumulator
- Is the implicit source/destination of many operations
* BAK - Bakup
- Non-addressable, used as tmp for ACC.
* NIL - zero register
- Stores zero
* LEFT, RIGHT, UP, DOWN
- Corespond to the four directions around the node
* ANY - Any destination
- Send the result to any destination that accepts it first. Reading from this
register will read in the first result given on any port
* LAST - Last port used
== Instruction Set ==
NOTE: Instruction set generally follows AT&T syntax standard of
<SRC>, <DEST>
* Labels
- These operate the same as standard labels. Labels can have an instruction
on the same line
* NOP
- No operation.
* MOV
- Moves from SRC to DEST register/memory address
* SWP
- The values in ACC and BAK are switched
* SAV
- The value in ACC is written to BAK
* ADD
- Value provided via SRC is added to ACC and stored there
* SUB
- VAlue provided via SRC is subtracted from ACC and stored there
* NEG
- Value in ACC is negated
* JMP
- Uncoditional Jump
* JEZ
- Jump if ACC is zero
* JNZ
- Jump if ACC is not zero
* JGZ
- Jump if ACC is greater than zero
* JLZ
- Jump if ACC is less than zero
* JRO
- Jump uncodnitionally by offset of SRC
- JRO 2 executes skips next instructions
- JRO ACC executes based on ACC
A '!' Before an instruction will set a break point
== Display ==
Display has a top left origin, XYRGB\0 Syntax. The display is 30x18
RGB values can be
* 0 - Black
* 1 - Dark Grey
* 2 - Bright Grey
* 3 - White
* 4 - Red