fix: 解决行空板df-k10麦克风收音太小的问题 (#357)

Fixes 78/xiaozhi-esp32#350
This commit is contained in:
Paul Xu
2025-03-18 00:51:23 +08:00
committed by GitHub
parent 423ddcb287
commit 349267ef23

View File

@ -176,7 +176,7 @@ void K10AudioCodec::EnableInput(bool enable) {
fs.channel_mask |= ESP_CODEC_DEV_MAKE_CHANNEL_MASK(1);
}
ESP_ERROR_CHECK(esp_codec_dev_open(input_dev_, &fs));
// ESP_ERROR_CHECK(esp_codec_dev_set_in_channel_gain(input_dev_, ESP_CODEC_DEV_MAKE_CHANNEL_MASK(0), 40.0));
ESP_ERROR_CHECK(esp_codec_dev_set_in_gain(input_dev_, 37.5)); //麦克风增益解决收音太小的问题
} else {
ESP_ERROR_CHECK(esp_codec_dev_close(input_dev_));
}
@ -223,4 +223,4 @@ int K10AudioCodec::Write(const int16_t* data, int samples) {
return bytes_written / sizeof(int32_t);
}
return samples;
}
}