| ← BC25 | Map | BCB9 → |
BCAD: Wait until no key is pressed
|
Loops until all keys are released.
|
|||
| wait_no_key | BCAD | LD BC,$00FE | Select all keyboard half-rows at once. |
| BCB0 | IN A,(C) | Read them. | |
| BCB2 | AND $1F | Keep the five key bits. | |
| BCB4 | XOR $1F | Invert the value read, then loop while any key is still down. | |
| BCB6 | JR NZ,wait_no_key | ||
| BCB8 | RET | ||
| ← BC25 | Map | BCB9 → |
