All instructions are given in uint8_t
.
Code | Name | Description | Parameters |
---|---|---|---|
0x00 |
END |
Ends the program | 1: Error code as 8-bit value |
0x01 |
PRINT |
Prints a string of characters | 1: Length; 2: Characters to write as 8-bit ASCII values |
0x02 |
MOV1 |
Moves 1 byte from a register into the destination | 1: destination; 2: source register |
0x03 |
MOV2 |
Moves 2 bytes from a register into the destination | 1: destination; 2: source register |
0x04 |
LET1 |
Moves 1 byte into a destination | 1: destination; 2: source value |
0x05 |
LET2 |
Moves 2 big-endian bytes into a destination | 1: destination; 2: source value first 8 bits; 3: source value last 8 bits |
0x06 |
ADD |
Adds x to the destination registry | 1: registry; 2: x to add |
0x07 |
SUB |
Subtracts x from the destination registry | 1: registry; 2: x to subtract |
0x08 |
MUL |
Multiplies x with the destination registry | 1: registry; 2: x to multiply |
0x09 |
DIV |
||
0x0A |
MOD |
||
0x0B |
CMP |
||
0x0C |
NEQ |
||
0x0D |
EQ |
||
0x0E |
GT |
||
0x0F |
LT |