diff options
-rw-r--r-- | tmk_core/protocol/vusb/vusb.c | 116 |
1 files changed, 58 insertions, 58 deletions
diff --git a/tmk_core/protocol/vusb/vusb.c b/tmk_core/protocol/vusb/vusb.c index 7c1f4ca7f..2d2e5ca5c 100644 --- a/tmk_core/protocol/vusb/vusb.c +++ b/tmk_core/protocol/vusb/vusb.c | |||
@@ -211,22 +211,22 @@ uchar usbFunctionWrite(uchar *data, uchar len) { | |||
211 | *------------------------------------------------------------------*/ | 211 | *------------------------------------------------------------------*/ |
212 | 212 | ||
213 | const PROGMEM uchar keyboard_hid_report[] = { | 213 | const PROGMEM uchar keyboard_hid_report[] = { |
214 | 0x05, 0x01, // Usage Page (Generic Desktop) | 214 | 0x05, 0x01, // Usage Page (Generic Desktop) |
215 | 0x09, 0x06, // Usage (Keyboard) | 215 | 0x09, 0x06, // Usage (Keyboard) |
216 | 0xA1, 0x01, // Collection (Application) | 216 | 0xA1, 0x01, // Collection (Application) |
217 | // Modifiers (8 bits) | 217 | // Modifiers (8 bits) |
218 | 0x05, 0x07, // Usage Page (Keyboard/Keypad) | 218 | 0x05, 0x07, // Usage Page (Keyboard/Keypad) |
219 | 0x19, 0xE0, // Usage Minimum (Keyboard Left Control) | 219 | 0x19, 0xE0, // Usage Minimum (Keyboard Left Control) |
220 | 0x29, 0xE7, // Usage Maximum (Keyboard Right GUI) | 220 | 0x29, 0xE7, // Usage Maximum (Keyboard Right GUI) |
221 | 0x15, 0x00, // Logical Minimum (0) | 221 | 0x15, 0x00, // Logical Minimum (0) |
222 | 0x25, 0x01, // Logical Maximum (1) | 222 | 0x25, 0x01, // Logical Maximum (1) |
223 | 0x95, 0x08, // Report Count (8) | 223 | 0x95, 0x08, // Report Count (8) |
224 | 0x75, 0x01, // Report Size (1) | 224 | 0x75, 0x01, // Report Size (1) |
225 | 0x81, 0x02, // Input (Data, Variable, Absolute) | 225 | 0x81, 0x02, // Input (Data, Variable, Absolute) |
226 | // Reserved (1 byte) | 226 | // Reserved (1 byte) |
227 | 0x95, 0x01, // Report Count (1) | 227 | 0x95, 0x01, // Report Count (1) |
228 | 0x75, 0x08, // Report Size (8) | 228 | 0x75, 0x08, // Report Size (8) |
229 | 0x81, 0x03, // Input (Constant) | 229 | 0x81, 0x03, // Input (Constant) |
230 | // Keycodes (6 bytes) | 230 | // Keycodes (6 bytes) |
231 | 0x05, 0x07, // Usage Page (Keyboard/Keypad) | 231 | 0x05, 0x07, // Usage Page (Keyboard/Keypad) |
232 | 0x19, 0x00, // Usage Minimum (0) | 232 | 0x19, 0x00, // Usage Minimum (0) |
@@ -238,17 +238,17 @@ const PROGMEM uchar keyboard_hid_report[] = { | |||
238 | 0x81, 0x00, // Input (Data, Array, Absolute) | 238 | 0x81, 0x00, // Input (Data, Array, Absolute) |
239 | 239 | ||
240 | // Status LEDs (5 bits) | 240 | // Status LEDs (5 bits) |
241 | 0x05, 0x08, // Usage Page (LED) | 241 | 0x05, 0x08, // Usage Page (LED) |
242 | 0x19, 0x01, // Usage Minimum (Num Lock) | 242 | 0x19, 0x01, // Usage Minimum (Num Lock) |
243 | 0x29, 0x05, // Usage Maximum (Kana) | 243 | 0x29, 0x05, // Usage Maximum (Kana) |
244 | 0x95, 0x05, // Report Count (5) | 244 | 0x95, 0x05, // Report Count (5) |
245 | 0x75, 0x01, // Report Size (1) | 245 | 0x75, 0x01, // Report Size (1) |
246 | 0x91, 0x02, // Output (Data, Variable, Absolute) | 246 | 0x91, 0x02, // Output (Data, Variable, Absolute) |
247 | // LED padding (3 bits) | 247 | // LED padding (3 bits) |
248 | 0x95, 0x01, // Report Count (1) | 248 | 0x95, 0x01, // Report Count (1) |
249 | 0x75, 0x03, // Report Size (3) | 249 | 0x75, 0x03, // Report Size (3) |
250 | 0x91, 0x03, // Output (Constant) | 250 | 0x91, 0x03, // Output (Constant) |
251 | 0xC0 // End Collection | 251 | 0xC0 // End Collection |
252 | }; | 252 | }; |
253 | 253 | ||
254 | const PROGMEM uchar mouse_hid_report[] = { | 254 | const PROGMEM uchar mouse_hid_report[] = { |
@@ -260,46 +260,46 @@ const PROGMEM uchar mouse_hid_report[] = { | |||
260 | 0x09, 0x01, // Usage (Pointer) | 260 | 0x09, 0x01, // Usage (Pointer) |
261 | 0xA1, 0x00, // Collection (Physical) | 261 | 0xA1, 0x00, // Collection (Physical) |
262 | // Buttons (5 bits) | 262 | // Buttons (5 bits) |
263 | 0x05, 0x09, // Usage Page (Button) | 263 | 0x05, 0x09, // Usage Page (Button) |
264 | 0x19, 0x01, // Usage Minimum (Button 1) | 264 | 0x19, 0x01, // Usage Minimum (Button 1) |
265 | 0x29, 0x05, // Usage Maximum (Button 5) | 265 | 0x29, 0x05, // Usage Maximum (Button 5) |
266 | 0x15, 0x00, // Logical Minimum (0) | 266 | 0x15, 0x00, // Logical Minimum (0) |
267 | 0x25, 0x01, // Logical Maximum (1) | 267 | 0x25, 0x01, // Logical Maximum (1) |
268 | 0x95, 0x05, // Report Count (5) | 268 | 0x95, 0x05, // Report Count (5) |
269 | 0x75, 0x01, // Report Size (1) | 269 | 0x75, 0x01, // Report Size (1) |
270 | 0x81, 0x02, // Input (Data, Variable, Absolute) | 270 | 0x81, 0x02, // Input (Data, Variable, Absolute) |
271 | // Button padding (3 bits) | 271 | // Button padding (3 bits) |
272 | 0x95, 0x01, // Report Count (1) | 272 | 0x95, 0x01, // Report Count (1) |
273 | 0x75, 0x03, // Report Size (3) | 273 | 0x75, 0x03, // Report Size (3) |
274 | 0x81, 0x03, // Input (Constant) | 274 | 0x81, 0x03, // Input (Constant) |
275 | 275 | ||
276 | // X/Y position (2 bytes) | 276 | // X/Y position (2 bytes) |
277 | 0x05, 0x01, // Usage Page (Generic Desktop) | 277 | 0x05, 0x01, // Usage Page (Generic Desktop) |
278 | 0x09, 0x30, // Usage (X) | 278 | 0x09, 0x30, // Usage (X) |
279 | 0x09, 0x31, // Usage (Y) | 279 | 0x09, 0x31, // Usage (Y) |
280 | 0x15, 0x81, // Logical Minimum (-127) | 280 | 0x15, 0x81, // Logical Minimum (-127) |
281 | 0x25, 0x7F, // Logical Maximum (127) | 281 | 0x25, 0x7F, // Logical Maximum (127) |
282 | 0x95, 0x02, // Report Count (2) | 282 | 0x95, 0x02, // Report Count (2) |
283 | 0x75, 0x08, // Report Size (8) | 283 | 0x75, 0x08, // Report Size (8) |
284 | 0x81, 0x06, // Input (Data, Variable, Relative) | 284 | 0x81, 0x06, // Input (Data, Variable, Relative) |
285 | 285 | ||
286 | // Vertical wheel (1 byte) | 286 | // Vertical wheel (1 byte) |
287 | 0x09, 0x38, // Usage (Wheel) | 287 | 0x09, 0x38, // Usage (Wheel) |
288 | 0x15, 0x81, // Logical Minimum (-127) | 288 | 0x15, 0x81, // Logical Minimum (-127) |
289 | 0x25, 0x7F, // Logical Maximum (127) | 289 | 0x25, 0x7F, // Logical Maximum (127) |
290 | 0x95, 0x01, // Report Count (1) | 290 | 0x95, 0x01, // Report Count (1) |
291 | 0x75, 0x08, // Report Size (8) | 291 | 0x75, 0x08, // Report Size (8) |
292 | 0x81, 0x06, // Input (Data, Variable, Relative) | 292 | 0x81, 0x06, // Input (Data, Variable, Relative) |
293 | // Horizontal wheel (1 byte) | 293 | // Horizontal wheel (1 byte) |
294 | 0x05, 0x0C, // Usage Page (Consumer) | 294 | 0x05, 0x0C, // Usage Page (Consumer) |
295 | 0x0A, 0x38, 0x02, // Usage (AC Pan) | 295 | 0x0A, 0x38, 0x02, // Usage (AC Pan) |
296 | 0x15, 0x81, // Logical Minimum (-127) | 296 | 0x15, 0x81, // Logical Minimum (-127) |
297 | 0x25, 0x7F, // Logical Maximum (127) | 297 | 0x25, 0x7F, // Logical Maximum (127) |
298 | 0x95, 0x01, // Report Count (1) | 298 | 0x95, 0x01, // Report Count (1) |
299 | 0x75, 0x08, // Report Size (8) | 299 | 0x75, 0x08, // Report Size (8) |
300 | 0x81, 0x06, // Input (Data, Variable, Relative) | 300 | 0x81, 0x06, // Input (Data, Variable, Relative) |
301 | 0xC0, // End Collection | 301 | 0xC0, // End Collection |
302 | 0xC0, // End Collection | 302 | 0xC0, // End Collection |
303 | 303 | ||
304 | #ifdef EXTRAKEY_ENABLE | 304 | #ifdef EXTRAKEY_ENABLE |
305 | // Extrakeys report descriptor | 305 | // Extrakeys report descriptor |