From 2731c3a8aef715c2ea27d541e946200bd4fc189f Mon Sep 17 00:00:00 2001 From: Dean Camera Date: Fri, 3 Jun 2011 07:56:12 +0000 Subject: Added new callback to the Audio Class driver to allow for endpoint control manipulations such as data sample rates. Modified the Class Driver AudioInput and AudioOutput demos to support multiple sample rates. Fixed KeyboardHost and KeyboardHostWithParser demos displaying incorrect values when numerical keys were pressed. Fix broken LowLevel audio demo descriptors. Minor documentation fixes. --- Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c') diff --git a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c index 9b6125e6c..38af3a7c5 100644 --- a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c +++ b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c @@ -137,9 +137,13 @@ int main(void) PressedKey = (KeyCode - HID_KEYBOARD_SC_A) + 'A'; } else if ((KeyCode >= HID_KEYBOARD_SC_1_AND_EXCLAMATION) & - (KeyCode <= HID_KEYBOARD_SC_0_AND_CLOSING_PARENTHESIS)) + (KeyCode < HID_KEYBOARD_SC_0_AND_CLOSING_PARENTHESIS)) { - PressedKey = (KeyCode - HID_KEYBOARD_SC_1_AND_EXCLAMATION) + '0'; + PressedKey = (KeyCode - HID_KEYBOARD_SC_1_AND_EXCLAMATION) + '1'; + } + else if (KeyCode == HID_KEYBOARD_SC_0_AND_CLOSING_PARENTHESIS) + { + PressedKey = '0'; } else if (KeyCode == HID_KEYBOARD_SC_SPACE) { -- cgit v1.2.3