Functions | |
cy_en_usb_dev_status_t | Cy_USB_Dev_RegisterClass (cy_stc_usb_dev_class_ll_item_t *classItem, cy_stc_usb_dev_class_t *classObj, void *classContext, cy_stc_usb_dev_context_t *context) |
Registers device class that will be supported by USB Device. More... | |
__STATIC_INLINE void | Cy_USB_Dev_RegisterClassBusResetCallback (cy_cb_usb_dev_bus_reset_t callback, cy_stc_usb_dev_class_t *classObj) |
Registers a callback function to notify a certain class about a Bus Reset event. More... | |
__STATIC_INLINE void | Cy_USB_Dev_RegisterClassSetConfigCallback (cy_cb_usb_dev_set_config_t callback, cy_stc_usb_dev_class_t *classObj) |
Registers a callback function to notify a certain class that SET_CONFIGURATION request was received from USB Host. More... | |
__STATIC_INLINE void | Cy_USB_Dev_RegisterClassSetInterfaceCallback (cy_cb_usb_dev_set_interface_t callback, cy_stc_usb_dev_class_t *classObj) |
Registers a callback function to notify a certain class that SET_INTERFACE request was received from the USB Host. More... | |
__STATIC_INLINE void | Cy_USB_Dev_RegisterClassRequestRcvdCallback (cy_cb_usb_dev_request_received_t callback, cy_stc_usb_dev_class_t *classObj) |
Registers a callback function to notify a certain class that setup packet was received from USB Host but was not recognized. More... | |
__STATIC_INLINE void | Cy_USB_Dev_RegisterClassRequestCmpltCallback (cy_cb_usb_dev_request_cmplt_t callback, cy_stc_usb_dev_class_t *classObj) |
Registers a callback function to notify a certain class that the USB Device received data from the USB Host as part of current request processing. More... | |
cy_en_usb_dev_status_t Cy_USB_Dev_RegisterClass | ( | cy_stc_usb_dev_class_ll_item_t * | classItem, |
cy_stc_usb_dev_class_t * | classObj, | ||
void * | classContext, | ||
cy_stc_usb_dev_context_t * | context | ||
) |
Registers device class that will be supported by USB Device.
The USB Device provides a hooks to implement required class support.
classItem | The pointer to class linked list element. |
classObj | The pointer to the class structure. |
classContext | The pointer to the context class structure allocated by the user. The structure is used during the custom class operation for internal configuration and data retention. |
context | The pointer to the context structure cy_stc_usb_dev_context_t allocated by the user. The structure is used during the USB Device operation for internal configuration and data retention. The user must not modify anything in this structure. |
__STATIC_INLINE void Cy_USB_Dev_RegisterClassBusResetCallback | ( | cy_cb_usb_dev_bus_reset_t | callback, |
cy_stc_usb_dev_class_t * | classObj | ||
) |
Registers a callback function to notify a certain class about a Bus Reset event.
To remove the callback function, pass NULL as the function pointer.
callback | The pointer to a callback function. |
classObj | The pointer to the class structure. |
__STATIC_INLINE void Cy_USB_Dev_RegisterClassSetConfigCallback | ( | cy_cb_usb_dev_set_config_t | callback, |
cy_stc_usb_dev_class_t * | classObj | ||
) |
Registers a callback function to notify a certain class that SET_CONFIGURATION request was received from USB Host.
To remove the callback function, pass a NULL as the function pointer.
callback | The pointer to a callback function. |
classObj | The pointer to the class structure. |
__STATIC_INLINE void Cy_USB_Dev_RegisterClassSetInterfaceCallback | ( | cy_cb_usb_dev_set_interface_t | callback, |
cy_stc_usb_dev_class_t * | classObj | ||
) |
Registers a callback function to notify a certain class that SET_INTERFACE request was received from the USB Host.
To remove the callback function, pass a NULL as the function pointer.
callback | The pointer to a callback function. |
classObj | The pointer to the class structure. |
__STATIC_INLINE void Cy_USB_Dev_RegisterClassRequestRcvdCallback | ( | cy_cb_usb_dev_request_received_t | callback, |
cy_stc_usb_dev_class_t * | classObj | ||
) |
Registers a callback function to notify a certain class that setup packet was received from USB Host but was not recognized.
Therefore, this might require manual class processing. To remove the callback function, pass a NULL as the function pointer.
callback | The pointer to a callback function. |
classObj | The pointer to the class structure. |
__STATIC_INLINE void Cy_USB_Dev_RegisterClassRequestCmpltCallback | ( | cy_cb_usb_dev_request_cmplt_t | callback, |
cy_stc_usb_dev_class_t * | classObj | ||
) |
Registers a callback function to notify a certain class that the USB Device received data from the USB Host as part of current request processing.
The class setup packet callback function must enable notification to trigger this event. This makes sense only when class request processing requires a data stage. To remove callback function pass NULL as function pointer.
callback | The pointer to a callback function. |
classObj | The pointer to the class structure. |