Page 1 of 1

keyboard irq only firing once (sending EOI)

Posted: Sun Mar 06, 2016 1:21 pm
by erwinm
Hey guys,

I am a beginner, setting up a hobby OS. I am running into a weird problem to which I can't seem to find the solution. My keyboard interrupt only fires once.

This is what does work:
- timer interrupts are firing, before and after the single kbd irq
- system calls are working as well

To me that is saying I got my IDT setup correctly. I am sending 'end of interrupt' after the keyboard handler returns..

What am I missing here?

Thanks a lot,
Erwin

Re: keyboard irq only firing once (sending EOI)

Posted: Sun Mar 06, 2016 1:29 pm
by gerryg400
Are you reading the key from within the handler ?

Re: keyboard irq only firing once (sending EOI)

Posted: Sun Mar 06, 2016 1:30 pm
by erwinm
Nope,

I am only printing a string to see if the handler is firing. And it is doing so only once.

Re: keyboard irq only firing once (sending EOI)

Posted: Sun Mar 06, 2016 1:32 pm
by gerryg400
That's most likely your problem. Until you read the key the controller doesn't know that you've serviced the interrupt. Just do an inportb(0x60) from within your ISR and see what happens.

Re: keyboard irq only firing once (sending EOI)

Posted: Sun Mar 06, 2016 1:36 pm
by erwinm
That was it! Thx a lot!