discoverpixy
usbh_hcs.h
Go to the documentation of this file.
1 
22 /* Define to prevent recursive ----------------------------------------------*/
23 #ifndef __USBH_HCS_H
24 #define __USBH_HCS_H
25 
26 /* Includes ------------------------------------------------------------------*/
27 #include "usbh_core.h"
28 
29 
30 
47 #define HC_MAX 8
48 
49 #define HC_OK 0x0000
50 #define HC_USED 0x8000
51 #define HC_ERROR 0xFFFF
52 #define HC_USED_MASK 0x7FFF
53 
83 uint8_t USBH_Alloc_Channel(USB_OTG_CORE_HANDLE *pdev, uint8_t ep_addr);
84 
85 uint8_t USBH_Free_Channel (USB_OTG_CORE_HANDLE *pdev, uint8_t idx);
86 
88 
90  uint8_t ch_num,
91  uint8_t dev_address,
92  uint8_t speed,
93  uint8_t ep_type,
94  uint16_t mps);
95 
97  uint8_t hc_num,
98  uint8_t dev_address,
99  uint8_t speed,
100  uint8_t ep_type,
101  uint16_t mps);
108 #endif /* __USBH_HCS_H */
109 
110 
123 /******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE****/
124 
125 
uint8_t USBH_DeAllocate_AllChannel(USB_OTG_CORE_HANDLE *pdev)
USBH_DeAllocate_AllChannel Free all USB host channel.
Definition: usbh_hcs.c:203
Header file for usbh_core.c.
uint8_t USBH_Modify_Channel(USB_OTG_CORE_HANDLE *pdev, uint8_t hc_num, uint8_t dev_address, uint8_t speed, uint8_t ep_type, uint16_t mps)
USBH_Modify_Channel Modify a pipe.
Definition: usbh_hcs.c:134
uint8_t USBH_Alloc_Channel(USB_OTG_CORE_HANDLE *pdev, uint8_t ep_addr)
USBH_Alloc_Channel Allocate a new channel for the pipe.
Definition: usbh_hcs.c:168
Definition: usb_core.h:287
uint8_t USBH_Free_Channel(USB_OTG_CORE_HANDLE *pdev, uint8_t idx)
USBH_Free_Pipe Free the USB host channel.
Definition: usbh_hcs.c:187
uint8_t USBH_Open_Channel(USB_OTG_CORE_HANDLE *pdev, uint8_t ch_num, uint8_t dev_address, uint8_t speed, uint8_t ep_type, uint16_t mps)
USBH_Open_Channel Open a pipe.
Definition: usbh_hcs.c:96