Added stdio.h stream examples for the virtual CDC UART in the CDC host demos.
[pub/USBasp.git] / LUFA / Drivers / USB / HighLevel / ConfigDescriptor.h
index 9f7b1f6..c0ebe09 100644 (file)
                         *  This value's meaning depends on the descriptor's placement in the descriptor, but standard type\r
                         *  values can be accessed in the \ref USB_DescriptorTypes_t enum.\r
                         */\r
                         *  This value's meaning depends on the descriptor's placement in the descriptor, but standard type\r
                         *  values can be accessed in the \ref USB_DescriptorTypes_t enum.\r
                         */\r
-                       #if defined(USE_NONSTANDARD_DESCRIPTOR_NAMES) || defined(__DOXYGEN__)\r
-                               #define DESCRIPTOR_TYPE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).Type\r
-                       #else\r
-                               #define DESCRIPTOR_TYPE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).bDescriptorType                       \r
-                       #endif\r
+                       #define DESCRIPTOR_TYPE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).Type\r
                        \r
                        /** Returns the descriptor's size, expressed as the 8-bit value indicating the number of bytes. */\r
                        \r
                        /** Returns the descriptor's size, expressed as the 8-bit value indicating the number of bytes. */\r
-                       #if defined(USE_NONSTANDARD_DESCRIPTOR_NAMES) || defined(__DOXYGEN__)\r
-                               #define DESCRIPTOR_SIZE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).Size\r
-                       #else\r
-                               #define DESCRIPTOR_SIZE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).bLength\r
-                       #endif\r
+                       #define DESCRIPTOR_SIZE(DescriptorPtr)    DESCRIPTOR_CAST(DescriptorPtr, USB_Descriptor_Header_t).Size\r
 \r
                /* Type Defines: */\r
                        /** Type define for a Configuration Descriptor comparator function (function taking a pointer to an array\r
 \r
                /* Type Defines: */\r
                        /** Type define for a Configuration Descriptor comparator function (function taking a pointer to an array\r
                        uint8_t USB_GetNextDescriptorComp(uint16_t* BytesRem, uint8_t** CurrConfigLoc, ConfigComparatorPtr_t ComparatorRoutine);\r
                        \r
                /* Enums: */\r
                        uint8_t USB_GetNextDescriptorComp(uint16_t* BytesRem, uint8_t** CurrConfigLoc, ConfigComparatorPtr_t ComparatorRoutine);\r
                        \r
                /* Enums: */\r
+                       /** Enum for the possible return codes of the \ref USB_GetDeviceConfigDescriptor() function. */\r
                        enum USB_Host_GetConfigDescriptor_ErrorCodes_t\r
                        {\r
                                HOST_GETCONFIG_Successful       = 0, /**< No error occurred while retrieving the configuration descriptor */\r
                        enum USB_Host_GetConfigDescriptor_ErrorCodes_t\r
                        {\r
                                HOST_GETCONFIG_Successful       = 0, /**< No error occurred while retrieving the configuration descriptor */\r
                        static inline void USB_GetNextDescriptor(uint16_t* const BytesRem,\r
                                                                 uint8_t** const CurrConfigLoc)\r
                        {\r
                        static inline void USB_GetNextDescriptor(uint16_t* const BytesRem,\r
                                                                 uint8_t** const CurrConfigLoc)\r
                        {\r
-                               #if defined(USE_NONSTANDARD_DESCRIPTOR_NAMES)\r
                                uint16_t CurrDescriptorSize = DESCRIPTOR_CAST(*CurrConfigLoc, USB_Descriptor_Header_t).Size;\r
                                uint16_t CurrDescriptorSize = DESCRIPTOR_CAST(*CurrConfigLoc, USB_Descriptor_Header_t).Size;\r
-                               #else\r
-                               uint16_t CurrDescriptorSize = DESCRIPTOR_CAST(*CurrConfigLoc, USB_Descriptor_Header_t).bLength;                         \r
-                               #endif\r
 \r
                                *CurrConfigLoc += CurrDescriptorSize;\r
                                *BytesRem      -= CurrDescriptorSize;\r
 \r
                                *CurrConfigLoc += CurrDescriptorSize;\r
                                *BytesRem      -= CurrDescriptorSize;\r