ESP32-audioI2S icon indicating copy to clipboard operation
ESP32-audioI2S copied to clipboard

connecttospeech followed by connecttohost doesent work?

Open stieneker opened this issue 1 year ago • 3 comments

Hello, i would like to use the i2s libary von Schreibfaul to ensure that the text is announced, but then a web radio station is received (example) (here in setup, same problem in loop)? Why does this not work?

// Connect MAX98357 I2S Amplifier Module audio.setPinout(I2S_BCLK, I2S_LRC, I2S_DOUT); // Set the volume audio.setVolume(12); audio.connecttospeech("Internet raadio", "de"); Serial.println("hier sollte sie geredet haben? ");

audio.setVolume(10); // audio.connecttohost(stations[StZaehler].c_str()); audio.connecttohost("http://streams.80s80s.de/web/mp3-192/streams.80s80s.de/");

By the way, what is? // audio.connecttomarytts("Hier ist Mary","de",HIGH); //audio.connecttomarytts()

Greetings Manfred

stieneker avatar Nov 10 '23 16:11 stieneker

you wait until connecttospeech(.....) is finished. Then the event audio_eof_speech(const char *info) is called. In the simplest case, you can use this to set up another connection.

void setup(){ ... audio.connecttospeech("Internet raadio", "en"); ... }

void loop(){ audio.loop(); }

void audio_eof_speech(const char *info){ audio.connecttohost("http://streams.80s80s.de/web/mp3-192/streams.80s80s.de/"); }

Mary is a speech synthesis with poor quality. It is no longer included in the new versions.

schreibfaul1 avatar Nov 10 '23 18:11 schreibfaul1

Oh, thanks a lot for this infos. Sometimes you get a knot in your Head. Greetings Manfred (DB3BP)

stieneker avatar Nov 13 '23 16:11 stieneker

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] avatar Jan 06 '24 02:01 github-actions[bot]