- Why did power-buttons disappear on keyboards?
- Am I correct in how to shut down a host using usb peripherals?
- Can a usb peripheral turn on a host? If so, what bytes does it send?
Why do I never see power buttons anymore on USB keyboards? I feel like they were very common on PS/2 keyboards.
Is it a limitation in the USB-protocol, i.e. no suitable packet "ok host, power off" exists?
I did find "system controls" in the HID Usage Tables (v1.12, section 4.5.1), but the HID itself (v.11, section 4.2) remains too vague for me.
"Because the parser for the Report descriptor represents a significant amount of code, a simpler method is needed to identify the device protocol for devices requiring BIOS support (Boot Devices). HID class devices use the Subclass part to indicate devices that support a predefined protocol for either mouse devices or keyboards (that is, the device can be used as a Boot Device). The boot protocol can be extended to include additional data not recognized by the BIOS, or the device may support a second preferred protocol for use by the HID class driver.The bInterfaceSubClass member declares whether a device supports a boot interface, otherwise it is 0."
Subclass Code Description:
- 0 NoSubclass
- 1 Boot Interface
- Subclass 2-255 Reserved"
So if I get this correctly, a keyboard needs to send a descriptor with
bInterfaceSubClass set to 1, as well as protocol code 1 (keyboard)?
And when a power button is pressed, it sends scancode 0x66 (KEY_POWER).
Am I correct in my assertions? If so it doesn't seem like a big deal, so why do I never find keyboards with power buttons anymore?
Still, that's just for shutting down a pc. Is there a way a usb device can turn on a host? This used to be possible with ps2 keyboards (granted, you often had to enable it in the BIOS, but still).
P.s. the reason for asking is because I'm annoyed to have to reach over the the power button. I'd much rather have a power button than a useless scroll lock or pause break.