Skip to content

Commit

Permalink
Filtering out arrow keys from the USB keyboard on the nano6502
Browse files Browse the repository at this point in the history
  • Loading branch information
venomix666 committed Oct 12, 2024
1 parent 0c92f7b commit 10ed7df
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/arch/nano6502/nano6502.S
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ zproc tty_conin
lda pending_key
zif_eq
tty_input_wait:
lda #IO_page_uart
lda #IO_page_uart
sta IO_page_reg
lda uart_rx_avail
beq tty_input_keyb
Expand All @@ -326,6 +326,11 @@ tty_input_keyb:
lda keyb_data_avail
beq tty_input_wait
lda keyb_data
; Filter out arrow keys
cmp #$80
zif_cs
lda #0
zendif
clc
rts
zendif
Expand Down

0 comments on commit 10ed7df

Please sign in to comment.