After making many changes, it seems that the instruction set is now finally stable. The instruction set is now very orthogonal. An instruction map was made, that clearly shows the meaning of the upper 8 bits of the instruction (Click on it for a readable version. Excel file is in the file section).
There are four addressing modes:
- (An+d) Register indirect with 4-bit displacement, includes 16 bit immediates. The result can optionally be incremented by 1.
- (zpage) One of 128 locations in the zero page (lowest bits in instruction)
- An+d The value of an address register, incremented with 5 bit constant. Also used for short jumps.
- Imm-8 an 8-bit constant (lowest bits in instruction)
Almost all instructions write the result to one of the four 16-bit data registers, or one of the four address registers (this includes the PC).
The most used instructions have a color in the map, from top to bottom:
- Green, logical NOR and MOV-Complement.
- Pink, 16-bit ADD
- Blue, MOV instructions (including jumps)
- Yellow, MOV to memory (store)
- Orange, conditional MOV instructions (including conditional jumps)
There are several empty positions in the map, so there is room for an extended version that has more instructions.