#include <usb/dev/request.h>
#include <errno.h>
#include <assert.h>
#include <usb/debug.h>
Go to the source code of this file.
Defines | |
#define | MAX_DATA_LENGTH ((size_t)(0xFFFF)) |
Functions | |
int | usb_control_request_get (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint8_t request, uint16_t value, uint16_t index, void *data, size_t data_size, size_t *actual_data_size) |
Generic wrapper for GET requests using standard control request format. | |
int | usb_control_request_set (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint8_t request, uint16_t value, uint16_t index, void *data, size_t data_size) |
Generic wrapper for SET requests using standard control request format. | |
int | usb_pipe_clear_halt (usb_pipe_t *ctrl_pipe, usb_pipe_t *target_pipe) |
Clear halt bit of an endpoint pipe (after pipe stall). | |
int | usb_request_clear_endpoint_halt (usb_pipe_t *pipe, uint16_t ep_index) |
Clear halt bit of an endpoint pipe (after pipe stall). | |
int | usb_request_clear_feature (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint16_t feature_selector, uint16_t index) |
Clear or disable specific device feature. | |
int | usb_request_get_bare_configuration_descriptor (usb_pipe_t *pipe, int index, usb_standard_configuration_descriptor_t *descriptor) |
Retrieve configuration descriptor of a USB device. | |
int | usb_request_get_configuration (usb_pipe_t *pipe, uint8_t *configuration_value) |
Get current configuration value of USB device. | |
int | usb_request_get_descriptor (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint8_t descriptor_type, uint8_t descriptor_index, uint16_t language, void *buffer, size_t size, size_t *actual_size) |
Retrieve USB descriptor of a USB device. | |
int | usb_request_get_descriptor_alloc (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint8_t descriptor_type, uint8_t descriptor_index, uint16_t language, void **buffer_ptr, size_t *buffer_size) |
Retrieve USB descriptor, allocate space for it. | |
int | usb_request_get_device_descriptor (usb_pipe_t *pipe, usb_standard_device_descriptor_t *descriptor) |
Retrieve standard device descriptor of a USB device. | |
int | usb_request_get_endpoint_status (usb_pipe_t *ctrl_pipe, usb_pipe_t *pipe, uint16_t *status) |
Get endpoint status. | |
int | usb_request_get_full_configuration_descriptor (usb_pipe_t *pipe, int index, void *descriptor, size_t descriptor_size, size_t *actual_size) |
Retrieve full configuration descriptor of a USB device. | |
int | usb_request_get_full_configuration_descriptor_alloc (usb_pipe_t *pipe, int index, void **descriptor_ptr, size_t *descriptor_size) |
Retrieve full configuration descriptor, allocate space for it. | |
int | usb_request_get_interface (usb_pipe_t *pipe, uint8_t interface_index, uint8_t *alternate_setting) |
Get selected alternate setting for USB interface. | |
int | usb_request_get_status (usb_pipe_t *pipe, usb_request_recipient_t recipient, uint16_t index, uint16_t *status) |
Retrieve status of a USB device. | |
int | usb_request_get_string (usb_pipe_t *pipe, size_t index, l18_win_locales_t lang, char **string_ptr) |
Get string (descriptor) from USB device. | |
int | usb_request_get_supported_languages (usb_pipe_t *pipe, l18_win_locales_t **languages_ptr, size_t *languages_count) |
Get list of supported languages by USB device. | |
int | usb_request_set_address (usb_pipe_t *pipe, usb_address_t new_address) |
Change address of connected device. | |
int | usb_request_set_configuration (usb_pipe_t *pipe, uint8_t configuration_value) |
Set configuration of USB device. | |
int | usb_request_set_descriptor (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint8_t descriptor_type, uint8_t descriptor_index, uint16_t language, void *buffer, size_t size) |
Update existing or add new USB descriptor to a USB device. | |
int | usb_request_set_feature (usb_pipe_t *pipe, usb_request_type_t request_type, usb_request_recipient_t recipient, uint16_t feature_selector, uint16_t index) |
Set or enable specific device feature. | |
int | usb_request_set_interface (usb_pipe_t *pipe, uint8_t interface_index, uint8_t alternate_setting) |
Select alternate setting for USB interface. |
Definition in file request.c.