USB Libraries Help > USB Host Libraries > USB Audio v1.0 Host Client Driver Library > Library Interface > b) Audio Stream Access Functions > USB_HOST_AUDIO_V1_0_StreamGetFirst Function
MPLAB Harmony USB Stack
USB_HOST_AUDIO_V1_0_StreamGetFirst Function

This function returns information about the first audio stream in the specified audio stream group. The stream group index is parameter to this function and it can be any value starting from zero to the number of stream groups minus one. Number of stream groups can be obtained by using the USB_HOST_AUDIO_V1_0_NumberOfStreamGroupsGet function. 

The streamInfo object is an out parameter to this function.

C
USB_HOST_AUDIO_V1_0_RESULT USB_HOST_AUDIO_V1_0_StreamGetFirst(
    USB_HOST_AUDIO_V1_0_OBJ audioDeviceObj, 
    uint8_t streamGroupIndex, 
    USB_HOST_AUDIO_V1_0_STREAM_INFO * streamInfo
);
Preconditions

The Audio v1.0 Device should have been attached to the Host.

Parameters
Parameters 
Description 
audioDeviceObj 
Audio v1.0 Client Driver object 
streamGroupIndex 
Stream group index 
streamInfo 
Pointer to the streamInfo object 
Returns
  • USB_HOST_AUDIO_V1_0_STREAM_RESULT_SUCCESS - The operation was successful
  • USB_HOST_AUDIO_V1_0_RESULT_OBJ_INVALID - The specified Audio v1.0 client driver object does not exist
  • USB_HOST_AUDIO_V1_0_STREAM_RESULT_FAILURE - An unknown failure occurred
Remarks

None.