void HIDDKeyboardInputReport_ReleaseModifierKey(HIDDKeyboardInputReport *report, unsigned char key) { ASSERT((key >= HIDDKeyboardDriverDescriptors_FIRSTMODIFIERKEY) && (key <= HIDDKeyboardDriverDescriptors_LASTMODIFIERKEY), "Invalid standard key code (%d)\n\r", key); // Clear corresponding bit unsigned char bit = key - HIDDKeyboardDriverDescriptors_FIRSTMODIFIERKEY; report->bmModifierKeys &= ~(1 << bit); }