forked from xiaozhi/xiaozhi-esp32
FIX: 修复双声道声波配网失效, 添加屏幕打印SSID/密码 (#971)
* debug: 添加声波配网的log打印点display * fix: 修复双声道下声波配网失效的问题 * fix: codec可能为nullptr的问题(需要从单例board获取) * Update afsk_demod.cc fix coding style --------- Co-authored-by: yangkaiyue <yangkaiyue1@tenclass.com> Co-authored-by: Xiaoxia <terrence@tenclass.com>
This commit is contained in:
@@ -52,7 +52,14 @@ void WifiBoard::EnterWifiConfigMode() {
|
||||
application.Alert(Lang::Strings::WIFI_CONFIG_MODE, hint.c_str(), "", Lang::Sounds::P3_WIFICONFIG);
|
||||
|
||||
#if CONFIG_USE_ACOUSTIC_WIFI_PROVISIONING
|
||||
audio_wifi_config::ReceiveWifiCredentialsFromAudio(&application, &wifi_ap);
|
||||
auto display = Board::GetInstance().GetDisplay();
|
||||
auto codec = Board::GetInstance().GetAudioCodec();
|
||||
int channel = 1;
|
||||
if (codec) {
|
||||
channel = codec->input_channels();
|
||||
}
|
||||
ESP_LOGI(TAG, "Start receiving WiFi credentials from audio, input channels: %d", channel);
|
||||
audio_wifi_config::ReceiveWifiCredentialsFromAudio(&application, &wifi_ap, display, channel);
|
||||
#endif
|
||||
|
||||
// Wait forever until reset after configuration
|
||||
|
||||
Reference in New Issue
Block a user