Defines |
#define | USB_HOST_DEVICEADDRESS 1 |
#define | USB_HOST_TIMEOUT_MS 1000 |
#define | HOST_DEVICE_SETTLE_DELAY_MS 1000 |
Enumerations |
enum | USB_Host_States_t {
HOST_STATE_WaitForDeviceRemoval = 0,
HOST_STATE_WaitForDevice = 1,
HOST_STATE_Unattached = 2,
HOST_STATE_Powered = 3,
HOST_STATE_Powered_WaitForDeviceSettle = 4,
HOST_STATE_Powered_WaitForConnect = 5,
HOST_STATE_Powered_DoReset = 6,
HOST_STATE_Powered_ConfigPipe = 7,
HOST_STATE_Default = 8,
HOST_STATE_Default_PostReset = 9,
HOST_STATE_Default_PostAddressSet = 10,
HOST_STATE_Addressed = 11,
HOST_STATE_Configured = 12,
HOST_STATE_Suspended = 15
} |
enum | USB_Host_ErrorCodes_t { HOST_ERROR_VBusVoltageDip = 0
} |
enum | USB_Host_EnumerationErrorCodes_t {
HOST_ENUMERROR_NoError = 0,
HOST_ENUMERROR_WaitStage = 1,
HOST_ENUMERROR_NoDeviceDetected = 2,
HOST_ENUMERROR_ControlError = 3,
HOST_ENUMERROR_PipeConfigError = 4
} |
Functions |
static uint16_t | USB_Host_GetFrameNumber (void) |
static void | USB_Host_EnableSOFEvents (void) ATTR_ALWAYS_INLINE |
static void | USB_Host_DisableSOFEvents (void) ATTR_ALWAYS_INLINE |
static void | USB_Host_ResetBus (void) ATTR_ALWAYS_INLINE |
static bool | USB_Host_IsBusResetComplete (void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE |
static void | USB_Host_ResumeBus (void) ATTR_ALWAYS_INLINE |
static void | USB_Host_SuspendBus (void) ATTR_ALWAYS_INLINE |
static bool | USB_Host_IsBusSuspended (void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE |
static bool | USB_Host_IsDeviceFullSpeed (void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE |
static bool | USB_Host_IsRemoteWakeupSent (void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE |
static void | USB_Host_ClearRemoteWakeupSent (void) ATTR_ALWAYS_INLINE |
static void | USB_Host_ResumeFromWakeupRequest (void) ATTR_ALWAYS_INLINE |
static bool | USB_Host_IsResumeFromWakeupRequestSent (void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE |
uint8_t | USB_Host_SetDeviceConfiguration (const uint8_t ConfigNumber) |
uint8_t | USB_Host_GetDeviceDescriptor (void *const DeviceDescriptorPtr) |
uint8_t | USB_Host_GetDeviceStringDescriptor (const uint8_t Index, void *const Buffer, const uint8_t BufferLength) |
uint8_t | USB_Host_ClearPipeStall (const uint8_t EndpointIndex) |
Этот файл содержит сруктуры, прототипы функций и макросы, связанные с режимом хоста USB.
- Note:
- Этот файл не должен включаться (include) самостоятельно. Он автоматически подключается при необходимости диспетчером заголовков драйвера USB, находящемся в LUFA/Drivers/USB/USB.h.