Cleaned up Font
Startet working on Keyboard Routines
This commit is contained in:
parent
fdacbb1deb
commit
f4fdca7fee
BIN
assets/ASCII.bin
BIN
assets/ASCII.bin
Binary file not shown.
BIN
assets/ASCII.bmf
BIN
assets/ASCII.bmf
Binary file not shown.
BIN
assets/font.bin
Executable file
BIN
assets/font.bin
Executable file
Binary file not shown.
BIN
assets/thin.bmf
Executable file
BIN
assets/thin.bmf
Executable file
Binary file not shown.
@ -28,49 +28,6 @@ keyboard_scan:
|
|||||||
sta soft_system_register
|
sta soft_system_register
|
||||||
sta system_register
|
sta system_register
|
||||||
|
|
||||||
ldy #$00 ; Result Index
|
|
||||||
ldx #$00 ; Row Counter
|
|
||||||
|
|
||||||
keyboard_scan_load:
|
|
||||||
lda #$fe ; Bit shifter
|
|
||||||
|
|
||||||
keyboard_scan_loop:
|
|
||||||
cmp keyboard_port
|
|
||||||
beq keyboard_scan_return
|
|
||||||
iny
|
|
||||||
rol
|
|
||||||
cmp #$fe
|
|
||||||
bne keyboard_scan_loop
|
|
||||||
inx
|
|
||||||
cpx #$08 ; Checking if Counted to 7
|
|
||||||
beq keyboard_scan_return
|
|
||||||
|
|
||||||
|
|
||||||
inc soft_system_register
|
|
||||||
lda soft_system_register
|
|
||||||
sta system_register
|
|
||||||
|
|
||||||
jmp keyboard_scan_load
|
|
||||||
|
|
||||||
keyboard_scan_return:
|
|
||||||
sty k0
|
|
||||||
lda soft_system_register
|
|
||||||
ora #$05
|
|
||||||
sta system_register
|
|
||||||
lda keyboard_port
|
|
||||||
tax
|
|
||||||
and #$0f
|
|
||||||
tay ; => Arrow Keys
|
|
||||||
txa
|
|
||||||
rol
|
|
||||||
rol
|
|
||||||
rol
|
|
||||||
rol
|
|
||||||
and #$07
|
|
||||||
|
|
||||||
tax ; => Modifier Keys
|
|
||||||
lda k0 ; => Scancode
|
|
||||||
rts
|
|
||||||
|
|
||||||
keyboard_translate:
|
keyboard_translate:
|
||||||
; Keyboard Translate
|
; Keyboard Translate
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
.org $f700
|
.org $f700
|
||||||
charset: .incbin "assets/UTF-8.bin"
|
charset: .incbin "assets/font.bin"
|
||||||
|
|
||||||
.org $ff00
|
.org $ff00
|
||||||
reset: sei
|
reset: sei
|
||||||
@ -87,6 +87,7 @@ lp:
|
|||||||
bne lp
|
bne lp
|
||||||
|
|
||||||
loop:
|
loop:
|
||||||
|
|
||||||
jmp loop
|
jmp loop
|
||||||
|
|
||||||
irq_jump: jmp (irq_vector)
|
irq_jump: jmp (irq_vector)
|
||||||
|
Loading…
Reference in New Issue
Block a user