Changeset 1880c65 in mainline


Ignore:
Timestamp:
2010-10-13T22:14:05Z (14 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
40b965d
Parents:
7da3219
Message:

Add USB key codes

Started rewritting USB key codes (scan codes).

Location:
uspace
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/virtusbkbd/keys.h

    r7da3219 r1880c65  
    4545typedef uint8_t kb_key_code_t;
    4646
    47 #define KB_KEY_A 4
    48 #define KB_KEY_B 5
    49 #define KB_KEY_C 6
    50 #define KB_KEY_D 7
    51 #define KB_KEY_E 8
    52 #define KB_KEY_F 9
    53 #define KB_KEY_G 10
    54 #define KB_KEY_H 11
    55 #define KB_KEY_I 12
    56 #define KB_KEY_J 13
    57 #define KB_KEY_K 14
    58 #define KB_KEY_L 15
    59 #define KB_KEY_M 16
    60 #define KB_KEY_N 17
    61 #define KB_KEY_O 18
    62 #define KB_KEY_P 19
    63 #define KB_KEY_Q 20
    64 #define KB_KEY_R 21
    65 #define KB_KEY_S 22
    66 #define KB_KEY_T 23
    67 #define KB_KEY_U 24
    68 #define KB_KEY_V 25
    69 #define KB_KEY_W 26
    70 #define KB_KEY_X 27
    71 #define KB_KEY_Y 28
    72 #define KB_KEY_Z 29
     47#define USB_HIDUT_KBD_KEY(name, usage_id, l, lc, l1, l2) \
     48        KB_KEY_##name = usage_id,
     49/** USB key code. */
     50typedef enum {
     51        #include <usb/hidutkbd.h>
     52} key_code_t;
    7353
    7454/** Modifier type. */
  • uspace/app/virtusbkbd/virtusbkbd.c

    r7da3219 r1880c65  
    168168        /* Switch to VT6 (Alt+F6) */
    169169        M_DOWN(KB_MOD_LEFT_ALT),
    170         K_PRESS(63),
     170        K_PRESS(KB_KEY_F6),
    171171        M_UP(KB_MOD_LEFT_ALT),
    172172        /* Type the word 'Hello' */
Note: See TracChangeset for help on using the changeset viewer.