craigthomas / Chip8Java

A Super Chip 8 emulator written in Java
MIT License
27 stars 2 forks source link

Load Subset of Registers #24

Closed craigthomas closed 1 month ago

craigthomas commented 2 months ago

Currently, the Fx65 instruction will load the number of registers specified by x into the memory space pointed to by index. The index register is then post-incremented by the number of registers loaded (or not, depending on which quirk mode is activated).

The XO Chip specification calls for a subset load command as follows:

Fxy3

This will load a subset of registers from memory space pointed to by index starting in register x and ending in register y. Note that the index is not post-incremented. If x is larger than y - for example x=6 and y=2 - then registers are loaded from memory in reverse order (e.g. 6, 5, 4, 3, 2). The registers are include the start and end registers.