Routines |
Prev: 02BF | Up: Map | Next: 0333 |
The key value is tested and a return made if 'no-key' or 'shift-only'; otherwise the 'main code' for that key is found.
|
||||||||||||||||
K_TEST | 031E | LD B,D | Copy the shift byte. | |||||||||||||
031F | LD D,$00 | Clear the D register for later. | ||||||||||||||
0321 | LD A,E | Move the key number. | ||||||||||||||
0322 | CP $27 | Return now if the key was 'CAPS SHIFT' only or 'no-key'. | ||||||||||||||
0324 | RET NC | |||||||||||||||
0325 | CP $18 | Jump forward unless the E key was SYMBOL SHIFT. | ||||||||||||||
0327 | JR NZ,K_MAIN | |||||||||||||||
0329 | BIT 7,B | However accept SYMBOL SHIFT and another key; return with SYMBOL SHIFT only. | ||||||||||||||
032B | RET NZ | |||||||||||||||
The 'main code' is found by indexing into the main key table.
|
||||||||||||||||
K_MAIN | 032C | LD HL,$0205 | The base address of the main key table. | |||||||||||||
032F | ADD HL,DE | Index into the table and fetch the 'main code'. | ||||||||||||||
0330 | LD A,(HL) | |||||||||||||||
0331 | SCF | Signal 'valid keystroke' before returning. | ||||||||||||||
0332 | RET |
Prev: 02BF | Up: Map | Next: 0333 |