hfp: skip hci_bcm_write_i2spcm_interface_param if HAVE_BCM_PCM_NBS_16KHZ

Custom firmware can up/downsample NBS to 16 kHz which uses fixed 16 khz sample rate
This commit is contained in:
Matthias Ringwald 2023-09-24 18:30:35 +02:00
parent 6fbaff2f50
commit 08a78038ba
2 changed files with 8 additions and 0 deletions

View File

@ -72,6 +72,12 @@ POSIX platform properties:
<!-- a name "lst:btstackFeatureConfiguration"></a-->
<!-- -->
Chipset properties:
| \#define | Description |
|------------------------|-------------------------------------------------------|
| HAVE_BCM_PCM_NBS_16KHZ | NBS is up/downsampled, use 16 kHz sample rate for NBS |
### ENABLE_* directives {#sec:enableDirectives}
BTstack properties:

View File

@ -2198,7 +2198,9 @@ void hfp_prepare_for_sco(hfp_connection_t * hfp_connection){
#endif
#ifdef ENABLE_BCM_PCM_WBS
#ifndef HAVE_BCM_PCM_NBS_16KHZ
hfp_connection->bcm_send_write_i2spcm_interface_param = true;
#endif
if (hfp_connection->negotiated_codec == HFP_CODEC_MSBC){
hfp_connection->bcm_send_enable_wbs = true;
}