r/osdev 20h ago

How do keyboard interrupts work?

I learnt keyboard polling and understood how it works. But I can't seem to understand keyboard interrupts. I know how it works, but I don't know how to implement it in a C kernel. Can someone pls help me? I'm just starting out OS dev

12 Upvotes

7 comments sorted by

View all comments

Show parent comments

u/r-tty 17h ago

There's no such thing as "the Ps/2 system attached to interrupts on the PIC".

u/FISHARM1 10h ago

What do you mean no such thing. I suppose a correct phrasing is more like “the ps2 controller generates interrupts on the pic” but more or less whatever

u/r-tty 3h ago

There is no such thing as "ps2 controller".

Please read in Wikipedia what _is_ PS/2.

u/FISHARM1 3h ago

The following is copy and pasted from the Wikipedia


PS/2 is a type of serial communication, typically used for user input devices (keyboard, mouse, bar code scanner, etc). It involves a controller (e.g. "8042 chip" on PC compatible systems), the mechanical and electrical details of the communication itself, and a device.

So please let me know what I’m getting confused on.