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

Fix FX0A GET KEY #8

Open
guilherme-puida opened this issue Feb 21, 2024 · 0 comments
Open

Fix FX0A GET KEY #8

guilherme-puida opened this issue Feb 21, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@guilherme-puida
Copy link
Owner

guilherme-puida commented Feb 21, 2024

The test rom describes the following behavior:

Fx0A waits for a key press and returns the pressed key in vX.

The test asks you to press a key on the CHIP-8 keypad. When you do, it checks for two issues that are easy to accidentally introduce when implementing this opcode. If all is well, you should be seeing a checkmark and "all good" on the screen:

Otherwise, you can get either of these errors:

NOT HALTING - Your implementation immediately returns the value of any currently pressed keys in vX, instead of halting the interpreter until a key is pressed (note that this needs timer support to be accurate)
NOT RELEASED - Your implementation doesn't wait for the pressed key to be released before resuming

See this article for more information.

The current output is x not released, when it should be ✓ all good.

@guilherme-puida guilherme-puida added the bug Something isn't working label Feb 21, 2024
@guilherme-puida guilherme-puida changed the title Fix 'FX0A GET KEY` Fix FX0A GET KEY Feb 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant