X-Git-Url: http://git.linex4red.de/pub/USBasp.git/blobdiff_plain/7f9f97c792dee6875fbca9806422bdd7d6c5a657..fc31973daffea3506051ce51a5f79383ce0867d6:/LUFA/Drivers/USB/LowLevel/Host.h diff --git a/LUFA/Drivers/USB/LowLevel/Host.h b/LUFA/Drivers/USB/LowLevel/Host.h index 07ff0fce7..97d908dea 100644 --- a/LUFA/Drivers/USB/LowLevel/Host.h +++ b/LUFA/Drivers/USB/LowLevel/Host.h @@ -28,6 +28,15 @@ this software. */ +/** \file + * \brief USB host mode definitions. + * + * This file contains structures, function prototypes and macros related to USB host mode. + * + * \note This file should not be included directly. It is automatically included as needed by the USB driver + * dispatch header located in LUFA/Drivers/USB/USB.h. + */ + /** \ingroup Group_USB * @defgroup Group_Host Host Management * @@ -46,15 +55,20 @@ #include #include "../../../Common/Common.h" - #include "../HighLevel/USBInterrupt.h" #include "../HighLevel/StdDescriptors.h" #include "Pipe.h" + #include "USBInterrupt.h" /* Enable C linkage for C++ Compilers: */ #if defined(__cplusplus) extern "C" { #endif + /* Preprocessor Checks: */ + #if !defined(__INCLUDE_FROM_USB_DRIVER) + #error Do not include this file directly. Include LUFA/Drivers/USB/USB.h instead. + #endif + /* Public Interface - May be used in end-application: */ /* Macros: */ /** Indicates the fixed USB device address which any attached device is enumerated to when in @@ -215,7 +229,7 @@ * * \return A value from the \ref USB_Host_SendControlErrorCodes_t enum to indicate the result. */ - uint8_t USB_Host_GetDeviceStringDescriptor(uint8_t Index, void* const Buffer, uint8_t BufferLength); + uint8_t USB_Host_GetDeviceStringDescriptor(const uint8_t Index, void* const Buffer, const uint8_t BufferLength); /** Clears a stall condition on the given pipe, via a ClearFeature request to the attached device. * @@ -231,7 +245,9 @@ /** Enum for the various states of the USB Host state machine. Only some states are * implemented in the LUFA library - other states are left to the user to implement. * - * For information on each state, refer to the USB 2.0 specification. Some states have + * For information on each possible USB host state, refer to the USB 2.0 specification. + * Several of the USB host states are broken up further into multiple smaller sub-states, + * so that they can be internally implemented inside the library in an efficient manner. * * \see \ref USB_HostState, which stores the current host state machine state. */ @@ -397,7 +413,7 @@ void USB_Host_ProcessNextHostState(void); uint8_t USB_Host_WaitMS(uint8_t MS); - #if defined(INCLUDE_FROM_HOST_C) + #if defined(__INCLUDE_FROM_HOST_C) static void USB_Host_ResetDevice(void); #endif #endif