small C128 keyboard handling optimization
This commit is contained in:
1 parent
fb2e13f9a9
commit
a7cb7eb52e
2 files changed
+2
-8
No files matched your search
@@ -119,7 +119,7 @@ Needs 70-250 more space in KERNAL segment (depending on the features enabled for
|
|||||||
|
|
||||||
Allows to use additional keys found on the C128 keyboard.
|
Allows to use additional keys found on the C128 keyboard.
|
||||||
|
|
||||||
Needs 128 bytes more space in KERNAL segment. If unsure - disable.
|
Needs about 125 bytes more space in KERNAL segment. If unsure - disable.
|
||||||
|
|
||||||
### `CONFIG_KEY_REPEAT_DEFAULT`
|
### `CONFIG_KEY_REPEAT_DEFAULT`
|
||||||
|
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ scnkey_matrix_128_loop_inner:
|
|||||||
tya // now .A contains key offset within a row
|
tya // now .A contains key offset within a row
|
||||||
clc
|
clc
|
||||||
adc kb_matrix_row_offsets, x // now .A contains key offset from the matrix start
|
adc kb_matrix_row_offsets, x // now .A contains key offset from the matrix start
|
||||||
|
adc #$40 // now .A contains fully normalized offset
|
||||||
tay
|
tay
|
||||||
jmp scnkey_matrix_128_loop_next
|
jmp scnkey_matrix_128_loop_next
|
||||||
!:
|
!:
|
||||||
@@ -52,13 +53,6 @@ scnkey_matrix_128_loop_next:
|
|||||||
cpy #$FF
|
cpy #$FF
|
||||||
beq scnkey_128_done
|
beq scnkey_128_done
|
||||||
|
|
||||||
// Shift the matrix code
|
|
||||||
|
|
||||||
clc
|
|
||||||
tya
|
|
||||||
adc #$40
|
|
||||||
tay
|
|
||||||
|
|
||||||
// Continue with C64 keyboard scanning
|
// Continue with C64 keyboard scanning
|
||||||
|
|
||||||
scnkey_128_done:
|
scnkey_128_done:
|
||||||
|
|||||||
Reference in new issue
Block a user