Keyboard duplicates the input

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
User avatar
CocaCola
Member
Member
Posts: 36
Joined: Fri Sep 07, 2012 9:11 am

Keyboard duplicates the input

Post by CocaCola »

Hello.
I've set up interrupts and the PIC, and registered a custom handler to IRQ1.
The problem is, when I press a key it is echoed twice on the screen.

I've read through these for a quick solution, with no luck:
http://forum.osdev.org/viewtopic.php?f= ... 0&start=15
http://wiki.osdev.org/PS2_Keyboard

If this is a "key K was released" event, what can I do to ignore it, or at least differentiate between it and "key K was pressed" event?
Casm
Member
Member
Posts: 221
Joined: Sun Oct 17, 2010 2:21 pm
Location: United Kingdom

Re: Keyboard duplicates the input

Post by Casm »

CocaCola wrote:Hello.
I've set up interrupts and the PIC, and registered a custom handler to IRQ1.
The problem is, when I press a key it is echoed twice on the screen.

I've read through these for a quick solution, with no luck:
http://forum.osdev.org/viewtopic.php?f= ... 0&start=15
http://wiki.osdev.org/PS2_Keyboard

If this is a "key K was released" event, what can I do to ignore it, or at least differentiate between it and "key K was pressed" event?
You get two interrupts - one for a keypress, and one for a key release. The release has bit seven of the scan code set, whilst the keypress has it clear.
Post Reply