1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- #ifndef _DESCRIPTORS_H_
- #define _DESCRIPTORS_H_
-
- #include <LUFA/Drivers/USB/USB.h>
- #include <avr/pgmspace.h>
-
-
- typedef struct
- {
- USB_Descriptor_Configuration_Header_t Config;
-
- USB_Descriptor_Interface_t HID_Interface;
- USB_HID_Descriptor_HID_t HID_KeyboardHID;
- USB_Descriptor_Endpoint_t HID_ReportINEndpoint;
- USB_Descriptor_Endpoint_t HID_ReportOUTEndpoint;
- } USB_Descriptor_Configuration_t;
-
- enum InterfaceDescriptors_t
- {
- INTERFACE_ID_Keyboard = 0,
- };
-
- enum StringDescriptors_t
- {
- STRING_ID_Language = 0,
- STRING_ID_Manufacturer = 1,
- STRING_ID_Product = 2,
- };
-
-
- #define KEYBOARD_IN_EPADDR (ENDPOINT_DIR_IN | 1)
-
- #define KEYBOARD_OUT_EPADDR (ENDPOINT_DIR_OUT | 2)
-
- #define KEYBOARD_EPSIZE 8
-
- uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
- const uint16_t wIndex,
- const void** const DescriptorAddress)
- ATTR_WARN_UNUSED_RESULT ATTR_NON_NULL_PTR_ARG(3);
- #endif
|