keyboard table fix
This commit is contained in:
1 parent
da90717ab2
commit
325eb90f33
1 file changed
+10
-10
@@ -13,21 +13,21 @@ m65_scnkey_set_keytab:
|
|||||||
; Calculate table index
|
; Calculate table index
|
||||||
|
|
||||||
lda SHFLAG
|
lda SHFLAG
|
||||||
asl ; multiply by 2 - keyboard matrix lookup table consists of words
|
and #KEY_FLAG_CAPSL ; isolate CAPS LOCK bit
|
||||||
and #$2E ; we are interested in SHIFT, VENDOR, CTRL and CAPS LOCK keys only
|
php
|
||||||
tax
|
lda SHFLAG
|
||||||
and #$20 ; isolate CAPS LOCK bit
|
and #%00000111 ; take SHIFT, VENDOR, CTRL, cancel the rest
|
||||||
|
plp
|
||||||
beq @1
|
beq @1
|
||||||
txa ; we have to move the CAPS LOCK bit (only) by one position down
|
ora #%00001000 ; apply CAPS lock bit at convenient position
|
||||||
and #$0E
|
|
||||||
ora #$10
|
|
||||||
tax
|
|
||||||
@1:
|
@1:
|
||||||
|
asl ; multiply by 2 - we have a list of addresses
|
||||||
|
|
||||||
; Set KEYTAB
|
; Set KEYTAB
|
||||||
|
|
||||||
ldx kb_matrix_lookup+0, x
|
lda kb_matrix_lookup+0, x
|
||||||
sta KEYTAB+0
|
sta KEYTAB+0
|
||||||
ldx kb_matrix_lookup+1, x
|
lda kb_matrix_lookup+1, x
|
||||||
sta KEYTAB+1
|
sta KEYTAB+1
|
||||||
|
|
||||||
; Fall back to original routine
|
; Fall back to original routine
|
||||||
|
|||||||
Reference in new issue
Block a user