#include "conf_usb.h"
#include "conf_audio_player.h"
#include "usb_standard_request.h"
#include "usb_task.h"
#include "usb_audio.h"
Data Structures | |
struct | S_usb_ac_interface_descriptor |
A U D I O Specific Class-Specific AC Interface Descriptor. More... | |
struct | S_usb_as_interface_descriptor |
Class-Specific AS Interface Descriptor. More... | |
struct | S_usb_configuration_descriptor |
USB Configuration Descriptor. More... | |
struct | S_usb_device_descriptor |
USB Device Descriptor. More... | |
struct | S_usb_endpoint_audio_descriptor |
Usb Audio Endpoint Descriptor. More... | |
struct | S_usb_endpoint_audio_specific |
Endpoint AUDIO Specific descriptor. More... | |
struct | S_usb_endpoint_descriptor |
USB Endpoint Descriptor. More... | |
struct | S_usb_feature_unit_descriptor_micro |
Class-Specific Feature Unit Descriptor. More... | |
struct | S_usb_feature_unit_descriptor_speaker |
Class-Specific Feature Unit Descriptor. More... | |
struct | S_usb_format_type_microphone |
struct | S_usb_format_type_speaker |
Audio Format Type descriptor. More... | |
struct | S_usb_hid_descriptor |
struct | S_usb_in_ter_descriptor |
Class-Specific Input Terminal Descriptor. More... | |
struct | S_usb_interface_descriptor |
USB Interface Descriptor. More... | |
struct | S_usb_language_id |
USB Language Descriptor. More... | |
struct | S_usb_manufacturer_string_descriptor |
struct usb_st_manufacturer More... | |
struct | S_usb_out_ter_descriptor |
Class-Specific Output Terminal Descriptor. More... | |
struct | S_usb_product_string_descriptor |
struct usb_st_product More... | |
struct | S_usb_serial_number |
struct usb_st_serial_number More... | |
struct | S_usb_user_configuration_descriptor |
struct | S_UsbRequest |
USB Request. More... | |
#define AC_ALTERNATE 0 |
#define AC_INTERFACE_CLASS AUDIO_CLASS |
#define AC_INTERFACE_INDEX 0 |
#define AC_INTERFACE_NB 0 |
Referenced by check_audio_control_request().
#define AC_INTERFACE_PROTOCOL NO_PROTOCOL |
#define AC_INTERFACE_SUB_CLASS AUDIOCONTROL_SUBCLASS |
#define AC_NB_ENDPOINT 0 |
#define ALT0_AS_IN_INTERFACE_CLASS AUDIO_CLASS |
#define ALT0_AS_IN_INTERFACE_INDEX 0x00 |
#define ALT0_AS_IN_INTERFACE_PROTOCOL NO_PROTOCOL |
#define ALT0_AS_IN_INTERFACE_SUB_CLASS AUDIOSTREAMING_SUBCLASS |
#define ALT0_AS_IN_NB_ENDPOINT 0x00 |
#define ALT0_AS_OUT_INTERFACE_CLASS AUDIO_CLASS |
#define ALT0_AS_OUT_INTERFACE_INDEX 0x00 |
#define ALT0_AS_OUT_INTERFACE_PROTOCOL NO_PROTOCOL |
#define ALT0_AS_OUT_INTERFACE_SUB_CLASS AUDIOSTREAMING_SUBCLASS |
#define ALT0_AS_OUT_NB_ENDPOINT 0x00 |
#define ALT1_AS_IN_INTERFACE_CLASS AUDIO_CLASS |
#define ALT1_AS_IN_INTERFACE_INDEX 0x01 |
#define ALT1_AS_IN_INTERFACE_PROTOCOL NO_PROTOCOL |
#define ALT1_AS_IN_INTERFACE_SUB_CLASS AUDIOSTREAMING_SUBCLASS |
#define ALT1_AS_IN_NB_ENDPOINT 0x01 |
#define ALT1_AS_OUT_INTERFACE_CLASS AUDIO_CLASS |
#define ALT1_AS_OUT_INTERFACE_INDEX 0x01 |
#define ALT1_AS_OUT_INTERFACE_PROTOCOL NO_PROTOCOL |
#define ALT1_AS_OUT_INTERFACE_SUB_CLASS AUDIOSTREAMING_SUBCLASS |
#define ALT1_AS_OUT_NB_ENDPOINT 0x01 |
#define ALTERNATE_KBD 0 |
#define AS_IN_DELAY 0x01 |
#define AS_IN_FORMAT_TAG AUDIO_FORMAT_TI_PCM |
#define AS_IN_TERMINAL_LINK MICRO_OUTPUT_TERMINAL_ID |
#define AS_OUT_DELAY 0x01 |
#define AS_OUT_FORMAT_TAG AUDIO_FORMAT_TI_PCM |
#define AS_OUT_TERMINAL_LINK SPEAKER_INPUT_TERMINAL_ID |
#define AUDIO_CHANNEL_NAME |
#define AUDIO_EP_IN_ATRIBUTES 0x00 |
#define AUDIO_EP_IN_DELAY_UNIT 0x00 |
#define AUDIO_EP_IN_LOCK_DELAY 0x0000 |
#define AUDIO_EP_OUT_ATRIBUTES 0x01 |
#define AUDIO_EP_OUT_DELAY_UNIT 0x00 |
#define AUDIO_EP_OUT_LOCK_DELAY 0x0000 |
#define CONF_ATTRIBUTES USB_CONFIG_BUSPOWERED |
#define CONF_INDEX 0 |
#define CONF_NB 1 |
#define DEVICE_CLASS 0 |
#define DEVICE_PROTOCOL 0 |
#define DEVICE_STATUS BUS_POWERED |
#define DEVICE_SUB_CLASS 0 |
#define ENDPOINT_NB_IN (EP_AUDIO_IN | USB_ENDPOINT_IN) |
#define ENDPOINT_NB_KBD (EP_KBD_IN | USB_ENDPOINT_IN) |
#define ENDPOINT_NB_OUT (EP_AUDIO_OUT | USB_ENDPOINT_OUT) |
#define EP_ATTRIBUTES_IN TYPE_ISOCHRONOUS |
Referenced by usb_user_endpoint_init().
#define EP_ATTRIBUTES_KBD 0x03 |
#define EP_ATTRIBUTES_OUT (TYPE_ISOCHRONOUS | ( ENDPOINT_TYPE_ADAPTIVE << ENDPOINT_TYPE_OFFSET)) |
Referenced by usb_user_endpoint_init().
#define EP_CONTROL_LENGTH 64 |
Referenced by hid_get_descriptor(), usb_get_descriptor(), and usb_init_device().
#define EP_IN_LENGTH_KBD 8 |
#define EP_INTERVAL_IN 0x01 |
#define EP_INTERVAL_KBD 0x02 |
#define EP_INTERVAL_OUT 0x01 |
#define EP_SIZE_IN (128) |
Referenced by device_audio_task(), and usb_user_endpoint_init().
#define EP_SIZE_KBD EP_IN_LENGTH_KBD |
Referenced by usb_user_endpoint_init().
#define EP_SIZE_OUT (256) |
Referenced by usb_user_endpoint_init().
#define IN_FORMAT_BIT_RESOLUTION 0x10 |
#define IN_FORMAT_FRAME_SIZE 0x02 |
#define IN_FORMAT_LSBYTE_SAMPLE_FREQ 0xAC44 |
#define IN_FORMAT_MSBYTE_SAMPLE_FREQ 0x00 |
#define IN_FORMAT_NB_CHANNELS 0x01 |
#define IN_FORMAT_SAMPLE_FREQ_NB 0x01 |
#define IN_FORMAT_TYPE AUDIO_FORMAT_TYPE_I |
#define INTERFACE_CLASS_KBD HID_CLASS |
#define INTERFACE_INDEX_KBD 0 |
#define INTERFACE_NB_KBD 3 |
Referenced by usb_hid_get_idle(), and usb_hid_set_idle().
#define INTERFACE_PROTOCOL_KBD KEYBOARD_PROTOCOL |
#define INTERFACE_STATUS 0x00 |
Referenced by usb_get_status().
#define INTERFACE_SUB_CLASS_KBD NO_SUBCLASS |
#define LANG_ID 0x00 |
Referenced by usb_user_get_descriptor().
#define LANGUAGE_ID 0x0409 |
#define MAN_INDEX 0x01 |
Referenced by usb_user_get_descriptor().
#define MAX_POWER 50 |
#define MICRO_FEATURE_UNIT_CTRL_CH_1 0x00 |
#define MICRO_FEATURE_UNIT_CTRL_CH_MASTER (AUDIO_FU_CONTROL_CS_MUTE|AUDIO_FU_CONTROL_CS_VOLUME) |
#define MICRO_FEATURE_UNIT_ID 0x05 |
Referenced by check_audio_control_request().
#define MICRO_FEATURE_UNIT_SOURCE_ID MICRO_INPUT_TERMINAL_ID |
#define MICRO_INPUT_TERMINAL_ASSOCIATION 0x00 |
#define MICRO_INPUT_TERMINAL_CH_NAME_ID 0x00 |
#define MICRO_INPUT_TERMINAL_CHANNEL_CONF AUDIO_CHANNEL_NO_POSITION |
#define MICRO_INPUT_TERMINAL_ID 0x04 |
#define MICRO_INPUT_TERMINAL_NAME_ID 0x00 |
#define MICRO_INPUT_TERMINAL_NB_CHANNELS 0x01 |
#define MICRO_INPUT_TERMINAL_TYPE AUDIO_TE_TYPE_INPUT_MICROPHONE |
#define MICRO_OUTPUT_TERMINAL_ASSOCIATION 0x00 |
#define MICRO_OUTPUT_TERMINAL_ID 0x06 |
#define MICRO_OUTPUT_TERMINAL_NAME_ID 0x00 |
#define MICRO_OUTPUT_TERMINAL_SOURCE_ID MICRO_FEATURE_UNIT_ID |
#define MICRO_OUTPUT_TERMINAL_TYPE AUDIO_TE_TYPE_USB_STREAMING |
#define NB_CONFIGURATION 1 |
Referenced by usb_set_configuration().
#define NB_ENDPOINT_KBD 1 |
#define NB_INTERFACE 4 |
Referenced by usb_set_configuration().
#define NB_OF_STREAMING_INTERFACE 0x02 |
#define OUT_FORMAT_BIT_RESOLUTION 0x10 |
#define OUT_FORMAT_FRAME_SIZE 0x02 |
#define OUT_FORMAT_MSBYTE_SAMPLE_FREQ 0x00 |
#define OUT_FORMAT_NB_CHANNELS 0x02 |
#define OUT_FORMAT_SAMPLE_FREQ_NB 0x01 |
#define OUT_FORMAT_TYPE AUDIO_FORMAT_TYPE_I |
#define PROD_INDEX 0x02 |
Referenced by usb_user_get_descriptor().
#define PRODUCT_ID AUDIO_SPEAKER_MICRO_EXAMPLE_PID |
#define RELEASE_NUMBER 0x1000 |
#define SN_INDEX 0x03 |
Referenced by usb_user_get_descriptor().
#define SPEAKER_FEATURE_UNIT_CTRL_CH_1 0x00 |
#define SPEAKER_FEATURE_UNIT_CTRL_CH_MASTER (AUDIO_FU_CONTROL_CS_MUTE|AUDIO_FU_CONTROL_CS_VOLUME) |
#define SPEAKER_FEATURE_UNIT_ID 0x02 |
Referenced by check_audio_control_request().
#define SPEAKER_FEATURE_UNIT_SOURCE_ID SPEAKER_INPUT_TERMINAL_ID |
#define SPEAKER_INPUT_TERMINAL_ASSOCIATION 0x00 |
#define SPEAKER_INPUT_TERMINAL_CH_NAME_ID 0x00 |
#define SPEAKER_INPUT_TERMINAL_CHANNEL_CONF AUDIO_CHANNEL_NO_POSITION |
#define SPEAKER_INPUT_TERMINAL_ID 0x01 |
#define SPEAKER_INPUT_TERMINAL_NAME_ID 0x00 |
#define SPEAKER_INPUT_TERMINAL_NB_CHANNELS 0x01 |
#define SPEAKER_INPUT_TERMINAL_TYPE AUDIO_TE_TYPE_USB_STREAMING |
#define SPEAKER_OUTPUT_TERMINAL_ASSOCIATION 0x00 |
#define SPEAKER_OUTPUT_TERMINAL_ID 0x03 |
#define SPEAKER_OUTPUT_TERMINAL_NAME_ID 0x00 |
#define SPEAKER_OUTPUT_TERMINAL_SOURCE_ID SPEAKER_FEATURE_UNIT_ID |
#define SPEAKER_OUTPUT_TERMINAL_TYPE AUDIO_TE_TYPE_OUTPUT_SPEAKER |
#define STD_AS_IN_INTERFACE_NB 0x02 |
#define STD_AS_OUT_INTERFACE_NB 0x01 |
#define Usb_get_conf_desc_length | ( | ) | (sizeof (usb_conf_desc)) |
Referenced by usb_get_descriptor(), and usb_set_interface().
#define Usb_get_conf_desc_pointer | ( | ) | (&(usb_conf_desc.cfg.bLength)) |
Referenced by usb_get_descriptor(), and usb_set_interface().
#define Usb_get_dev_desc_length | ( | ) | (sizeof (usb_dev_desc)) |
Referenced by usb_get_descriptor().
#define Usb_get_dev_desc_pointer | ( | ) | (&(usb_dev_desc.bLength)) |
Referenced by usb_get_descriptor().
#define USB_MANUFACTURER_NAME |
#define USB_MN_LENGTH 5 |
#define USB_PN_LENGTH 20 |
#define USB_PRODUCT_NAME |
#define USB_SERIAL_NUMBER |
#define USB_SN_LENGTH 13 |
#define USB_SPECIFICATION 0x0200 |
#define Usb_unicode | ( | c | ) | (Usb_format_mcu_to_usb_data(16, (uint16_t)(c))) |
#define VENDOR_ID ATMEL_VID |