Hello:)
I would like to know how to change the bitresoultion to 8 bits for the keil usb audio descriptors
I have tried to change bSubFrameSize to 0x01 bBitResolution to 8 then WBVAL to 34 and I get bsod error on computer and it does not work I am running winxp.
I would like to run the usb speaker at 8bit resolution and 32000khz could you please help me make the changes to the descriptors
/* Audio Type I Format */ AUDIO_FORMAT_TYPE_I_DESC_SZ(1), /* bLength */ AUDIO_INTERFACE_DESCRIPTOR_TYPE, /* bDescriptorType */ AUDIO_STREAMING_FORMAT_TYPE, /* bDescriptorSubtype */ AUDIO_FORMAT_TYPE_I, /* bFormatType */ 0x01, /* bNrChannels */ 0x02, /* bSubFrameSize */ 16, /* bBitResolution */ 0x01, /* bSamFreqType */ B3VAL(32000), /* tSamFreq */ /* Endpoint - Standard Descriptor */ AUDIO_STANDARD_ENDPOINT_DESC_SIZE, /* bLength */ USB_ENDPOINT_DESCRIPTOR_TYPE, /* bDescriptorType */ USB_ENDPOINT_OUT(3), /* bEndpointAddress */ USB_ENDPOINT_TYPE_ISOCHRONOUS, /* bmAttributes */ WBVAL(64), /* wMaxPacketSize */ 0x01, /* bInterval */ 0x00, /* bRefresh */ 0x00, /* bSynchAddress */
/* Audio Definitions */ #define DATA_FREQ 32000 /* Audio Data Frequency */ #define P_S 32 /* Packet Size */ #if USB_DMA #define P_C 4 /* Packet Count */ #else #define P_C 1 /* Packet Count */ #endif #define B_S (8*P_C*P_S) /* Buffer Size */
thanks Mike pisces.
It would help if you explain what needs to be done in the code to make16bit resolution then I may understand what needs to be done to 8bit. I did not write these example myself, how can you possible except me to know these things.
I am not a student I can't ask teacher.
PCM (0x0001) means 2's complementary binary data. PCM8 (0x0002) means offset binary data.