1# Global configuration section: 2# - lists input and output devices always present on the device 3# as well as the output device selected by default. 4# Devices are designated by a string that corresponds to the enum in audio.h 5# - defines whether the speaker output path uses DRC 6# "TRUE" means DRC is enabled, "FALSE" or omission means DRC isn't used. 7 8global_configuration { 9 attached_output_devices AUDIO_DEVICE_OUT_EARPIECE|AUDIO_DEVICE_OUT_SPEAKER|AUDIO_DEVICE_OUT_TELEPHONY_TX 10 default_output_device AUDIO_DEVICE_OUT_SPEAKER 11 attached_input_devices AUDIO_DEVICE_IN_BUILTIN_MIC|AUDIO_DEVICE_IN_BACK_MIC|AUDIO_DEVICE_IN_REMOTE_SUBMIX|AUDIO_DEVICE_IN_TELEPHONY_RX 12 speaker_drc_enabled TRUE 13} 14 15# audio hardware module section: contains descriptors for all audio hw modules present on the 16# device. Each hw module node is named after the corresponding hw module library base name. 17# For instance, "primary" corresponds to audio.primary.<device>.so. 18# The "primary" module is mandatory and must include at least one output with 19# AUDIO_OUTPUT_FLAG_PRIMARY flag. 20# Each module descriptor contains one or more output profile descriptors and zero or more 21# input profile descriptors. Each profile lists all the parameters supported by a given output 22# or input stream category. 23# The "channel_masks", "formats", "devices" and "flags" are specified using strings corresponding 24# to enums in audio.h and audio_policy.h. They are concatenated by use of "|" without space or "\n". 25 26audio_hw_modules { 27 primary { 28 outputs { 29 primary { 30 sampling_rates 44100|48000 31 channel_masks AUDIO_CHANNEL_OUT_STEREO 32 formats AUDIO_FORMAT_PCM_16_BIT 33 devices AUDIO_DEVICE_OUT_EARPIECE|AUDIO_DEVICE_OUT_SPEAKER|AUDIO_DEVICE_OUT_WIRED_HEADSET|AUDIO_DEVICE_OUT_WIRED_HEADPHONE|AUDIO_DEVICE_OUT_LINE|AUDIO_DEVICE_OUT_ALL_SCO 34 flags AUDIO_OUTPUT_FLAG_FAST|AUDIO_OUTPUT_FLAG_PRIMARY 35 } 36 raw { 37 sampling_rates 48000 38 channel_masks AUDIO_CHANNEL_OUT_STEREO 39 formats AUDIO_FORMAT_PCM_16_BIT 40 devices AUDIO_DEVICE_OUT_EARPIECE|AUDIO_DEVICE_OUT_SPEAKER|AUDIO_DEVICE_OUT_WIRED_HEADSET|AUDIO_DEVICE_OUT_WIRED_HEADPHONE|AUDIO_DEVICE_OUT_LINE|AUDIO_DEVICE_OUT_ALL_SCO 41 flags AUDIO_OUTPUT_FLAG_FAST|AUDIO_OUTPUT_FLAG_RAW 42 } 43 deep_buffer { 44 sampling_rates 8000|11025|12000|16000|22050|24000|32000|44100|48000 45 channel_masks AUDIO_CHANNEL_OUT_STEREO 46 formats AUDIO_FORMAT_PCM_16_BIT 47 devices AUDIO_DEVICE_OUT_SPEAKER|AUDIO_DEVICE_OUT_EARPIECE|AUDIO_DEVICE_OUT_WIRED_HEADSET|AUDIO_DEVICE_OUT_WIRED_HEADPHONE|AUDIO_DEVICE_OUT_LINE|AUDIO_DEVICE_OUT_ALL_SCO 48 flags AUDIO_OUTPUT_FLAG_DEEP_BUFFER 49 } 50 compress_offload { 51 sampling_rates 8000|11025|12000|16000|22050|24000|32000|44100|48000 52 channel_masks AUDIO_CHANNEL_OUT_MONO|AUDIO_CHANNEL_OUT_STEREO 53 formats AUDIO_FORMAT_MP3|AUDIO_FORMAT_AAC_LC|AUDIO_FORMAT_AAC_HE_V1|AUDIO_FORMAT_AAC_HE_V2 54 devices AUDIO_DEVICE_OUT_SPEAKER|AUDIO_DEVICE_OUT_WIRED_HEADSET|AUDIO_DEVICE_OUT_WIRED_HEADPHONE|AUDIO_DEVICE_OUT_LINE 55 flags AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING 56 } 57 voice_tx { 58 sampling_rates 8000|16000|48000 59 channel_masks AUDIO_CHANNEL_OUT_STEREO|AUDIO_CHANNEL_OUT_MONO 60 formats AUDIO_FORMAT_PCM_16_BIT 61 devices AUDIO_DEVICE_OUT_TELEPHONY_TX 62 } 63 tts { 64 sampling_rates 48000 65 channel_masks AUDIO_CHANNEL_OUT_STEREO 66 formats AUDIO_FORMAT_PCM_16_BIT 67 devices AUDIO_DEVICE_OUT_SPEAKER 68 flags AUDIO_OUTPUT_FLAG_TTS 69 } 70 } 71 inputs { 72 primary { 73 sampling_rates 8000|11025|12000|16000|22050|24000|32000|44100|48000 74 channel_masks AUDIO_CHANNEL_IN_MONO|AUDIO_CHANNEL_IN_STEREO|AUDIO_CHANNEL_IN_FRONT_BACK|AUDIO_CHANNEL_INDEX_MASK_3 75 formats AUDIO_FORMAT_PCM_16_BIT 76 devices AUDIO_DEVICE_IN_BUILTIN_MIC|AUDIO_DEVICE_IN_WIRED_HEADSET|AUDIO_DEVICE_IN_BLUETOOTH_SCO_HEADSET|AUDIO_DEVICE_IN_VOICE_CALL|AUDIO_DEVICE_IN_BACK_MIC 77 } 78 voice_rx { 79 sampling_rates 8000|16000|48000 80 channel_masks AUDIO_CHANNEL_IN_STEREO|AUDIO_CHANNEL_IN_MONO 81 formats AUDIO_FORMAT_PCM_16_BIT 82 devices AUDIO_DEVICE_IN_TELEPHONY_RX 83 } 84 } 85 } 86 a2dp { 87 outputs { 88 a2dp { 89 sampling_rates 44100 90 channel_masks AUDIO_CHANNEL_OUT_STEREO 91 formats AUDIO_FORMAT_PCM_16_BIT 92 devices AUDIO_DEVICE_OUT_ALL_A2DP 93 } 94 } 95 inputs { 96 a2dp { 97 sampling_rates 44100|48000 98 channel_masks AUDIO_CHANNEL_IN_MONO|AUDIO_CHANNEL_IN_STEREO 99 formats AUDIO_FORMAT_PCM_16_BIT 100 devices AUDIO_DEVICE_IN_BLUETOOTH_A2DP 101 } 102 } 103 } 104 usb { 105 outputs { 106 usb_accessory { 107 sampling_rates 44100 108 channel_masks AUDIO_CHANNEL_OUT_STEREO 109 formats AUDIO_FORMAT_PCM_16_BIT 110 devices AUDIO_DEVICE_OUT_USB_ACCESSORY 111 } 112 usb_device { 113 sampling_rates dynamic 114 channel_masks dynamic 115 formats dynamic 116 devices AUDIO_DEVICE_OUT_USB_DEVICE 117 } 118 } 119 inputs { 120 usb_device { 121 sampling_rates dynamic 122 channel_masks dynamic 123 formats dynamic 124 devices AUDIO_DEVICE_IN_USB_DEVICE 125 } 126 } 127 } 128 r_submix { 129 outputs { 130 submix { 131 sampling_rates 48000 132 channel_masks AUDIO_CHANNEL_OUT_STEREO 133 formats AUDIO_FORMAT_PCM_16_BIT 134 devices AUDIO_DEVICE_OUT_REMOTE_SUBMIX 135 } 136 } 137 inputs { 138 submix { 139 sampling_rates 48000 140 channel_masks AUDIO_CHANNEL_IN_STEREO 141 formats AUDIO_FORMAT_PCM_16_BIT 142 devices AUDIO_DEVICE_IN_REMOTE_SUBMIX 143 } 144 } 145 } 146} 147