Implement a minimal HID keyboard driver. We need to...
a.) Detect which kind of controller is available. (UHCI and OHCI for 1.0, EHCI for 2.0, xHCI for 3.0)
Nick's machine is a Pentium III machine (if I remember correctly) -- a architecture released before the release of USB2.0.
In order to guarantee this machine has a working keyboard, we need to support both USB1.0 controller types.
See relevant pages linked on the USB wiki page
b.) A transaction for USB devices is split into 3 packets:
The token packet: contains type of data, direction of transaction, device address and endpoint number
The data packet (optional): contains payload if data in token packet indicates that a payload is coming
The handshake packet: sent by the receiver to acknowledge that the data was received.
c.) Of the 4 endpoint types, the Interrupt Transfer type is what HID tends to use. It requires the host to poll the USB controller to obtain data from the device. We must, in the while loop or at a clock interrupt, poll these types of endpoints and act if we receive data.
NOTE: Requires #32
Implement a minimal HID keyboard driver. We need to...
a.) Detect which kind of controller is available. (UHCI and OHCI for 1.0, EHCI for 2.0, xHCI for 3.0)
Relevant OSDev Wiki Pages: https://wiki.osdev.org/Universal_Serial_Bus https://wiki.osdev.org/USB_Human_Input_Devices