blob: d5e81828c65987c35c7eb2df73af83333ad15bff [file]
// Copyright 2021 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
{
include: [
"inspect/client.shard.cml",
"syslog/client.shard.cml",
],
program: {
runner: "elf",
binary: "bin/bt_hfp_audio_gateway",
},
capabilities: [
{
protocol: [
"fuchsia.bluetooth.hfp.Hfp",
"fuchsia.bluetooth.hfp.test.HfpTest",
],
},
],
use: [
{ service: "fuchsia.hardware.audio.DaiConnectorService" },
{
protocol: [ "fuchsia.bluetooth.bredr.Profile" ],
from: "parent",
},
{
protocol: [
// Used for partial stack registry (codec)
"fuchsia.audio.device.Provider",
// For pausing A2DP when HFP is active
"fuchsia.bluetooth.internal.a2dp.Controller",
// Used for full-stack audio (audio_core) devices
"fuchsia.media.AudioDeviceEnumerator",
"fuchsia.mediacodec.CodecFactory",
// If available, report battery levels
"fuchsia.power.battery.BatteryManager",
// Used for audio encoding (only audio_core)
"fuchsia.sysmem.Allocator",
"fuchsia.sysmem2.Allocator",
],
availability: "optional",
},
],
expose: [
{
protocol: [
"fuchsia.bluetooth.hfp.Hfp",
"fuchsia.bluetooth.hfp.test.HfpTest",
],
from: "self",
},
],
config: {
// Whether the Audio Gateway can reject incoming calls. Setting this to true will mean
// headsets can reject calls.
reject_incoming_voice_call: { type: "bool" },
// Three way calling support
// TODO(https://fxbug.dev/42153736): limited support for three-way calls implemented
three_way_calling: { type: "bool" },
// In band ringtone support
// TODO(https://fxbug.dev/42155342): in-band ringtone is not supported yet, setting to true will have no
// effect yet.
in_band_ringtone: { type: "bool" },
// Echo Cancelling and Noise Reduction
// This controls whether the headset connected can turn off echo cancelling (as an in-ear
// headset, for example)
echo_canceling_and_noise_reduction: { type: "bool" },
// Voice Recognition
// If set to true, the headset will be able to activate voice recognition actions
// TODO(https://fxbug.dev/42144778): unimplememented. setting this to true will be ignored
voice_recognition: { type: "bool" },
// Attach Phone Number to Voice Tag
// Controls the feature flag sent to the handsfree peer.
attach_phone_number_to_voice_tag: { type: "bool" },
// Enhanced Call Controls
// Whether the enhanced call controls are available. See HFP Spec v1.8 Sec 4.33
enhanced_call_controls: { type: "bool" },
// Enhanced Voice Recognition
// See HFP Spec v1.8 Sec 4.25
// TODO(https://fxbug.dev/42144778): unimplemented, ignored for now
enhanced_voice_recognition: { type: "bool" },
// Wide Band Speech
// Controls whether we will use higher quality codecs for audio. Highly recommended.
wide_band_speech: { type: "bool" },
// Enhanced Voice Recognition with text
// Provides textual versions of the voice responses, to be displayed on a visual screen for
// example.
// See HFP Spec v1.8 Sec 4.26
// TODO(https://fxbug.dev/42144778): unimplemented, ignored for now
enhanced_voice_recognition_with_text: { type: "bool" },
// Whether the controller on this product supports encoding in each of these codecs.
// Codecs that are not supported by the controller are encoded locally and sent through
// the BT transport.
controller_encoding_cvsd: { type: "bool" },
controller_encoding_msbc: { type: "bool" },
// What type of audio control to use for controller-encoded audio
// Types available:
// - dai - find and use DAI devices, and publish a StreamConfig to Audio Core (full_stack audio)
// - registry - publish a Codec device to the AudioDeviceRegistry (partial_stack audio)
offload_type: {
type: "string",
max_size: 8,
},
},
}