[Solved] Snips being deaf or something after 0.62.3 update

So, I’m opening a dedicated thread to this issue. Not sure this is in the right category, though.

Symptoms: using the Snips dev kit, after updating both sam, the platform (apt upgrade), deploying a freshly rebuilt assistant, and rebooting… Snips won’t react any more.

Even when pressing the button on the hat, I will ask a simple intent but the hat LEDs keep flashing in blue like it’s still waiting for an order.

sam watch output:

[11:13:51] [Dialogue] was asked to start a session on site bureau
[11:13:51] [Asr] was asked to stop listening on site bureau
[11:13:51] [Hotword] was asked to toggle itself 'off' on site bureau
[11:13:51] [Dialogue] session with id 'c1496e2b-33d3-45c0-82a1-e1bc49f2917b' was queued on site bureau
[11:13:51] [Dialogue] session with id 'c1496e2b-33d3-45c0-82a1-e1bc49f2917b' was started on site bureau
[11:13:51] [Asr] was asked to listen on site bureau
[11:14:07] [Dialogue] session with id 'c1496e2b-33d3-45c0-82a1-e1bc49f2917b' was ended on site bureau. The session was ended because one of the component didn't respond in a timely manner
[11:14:07] [Asr] was asked to stop listening on site bureau
[11:14:07] [Hotword] was asked to toggle itself 'on' on site bureau

The logs on the Pi:

mars 24 11:12:52 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Site [bureau]: reset site -> turn off ASR and turn off Hotword
mars 24 11:12:52 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Session [a4c22dfd-0425-4b6a-aa73-547a4d00f913]: The session has been created because the site "bureau" is free
mars 24 11:12:52 snips-base snips-hotword[516]: INFO:snips_hotword_lib::audio    : Audio thread for site bureau stopped.
mars 24 11:13:08 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Session [a4c22dfd-0425-4b6a-aa73-547a4d00f913]: closing session which was active: Timeout
mars 24 11:13:08 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Site [bureau]: reset site -> turn off ASR and turn on Hotword
mars 24 11:13:08 snips-base snips-hotword[516]: INFO:snips_hotword_lib::audio    : Audio thread for site bureau started.
mars 24 11:13:51 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Site [bureau]: reset site -> turn off ASR and turn off Hotword
mars 24 11:13:51 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Session [c1496e2b-33d3-45c0-82a1-e1bc49f2917b]: The session has been created because the site "bureau" is free
mars 24 11:13:51 snips-base snips-hotword[516]: INFO:snips_hotword_lib::audio    : Audio thread for site bureau stopped.
mars 24 11:14:07 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Session [c1496e2b-33d3-45c0-82a1-e1bc49f2917b]: closing session which was active: Timeout
mars 24 11:14:07 snips-base snips-dialogue[510]: INFO:snips_dialogue_lib::coordinator::coordinator: Site [bureau]: reset site -> turn off ASR and turn on Hotword
mars 24 11:14:07 snips-base snips-hotword[516]: INFO:snips_hotword_lib::audio    : Audio thread for site bureau started.

I also watched the logs after restarting “snips-*”, I spotted no error.

I already tried sam test microphone, the speaker will play the sample back. The sound is quite clear, just the usual hiss in the background.

I also did sam setup again.

So maybe there’s just a miscommunication between the audio interface and the Snips platform?

/etc/asound.conf:

pcm.!default {
    type asym
    playback.pcm {
        type plug
        slave.pcm "hw:1,0"
    }
    capture.pcm {
        type plug
        slave.pcm "hw:1,0"
    }
}

Now let’s make Snips say something using mosquitto_pub -t 'hermes/tts/say' -m '{"siteId": "bureau", "text": "Bonjour", "lang": "fr-FR"}':

sam watch output:
[11:24:25] Watching on localhost:1883 (MQTT)
[11:24:38] [Tts] was asked to say “Theo!”
[11:24:38] [AudioServer] was asked to play a wav of 32.2 kB with id ‘0fb8c620-3b93-4130-9f27-4d912ddfa9ff’ on site bureau

But I didn’t hear anything. No logs on the Pi.

The hat LEDs flash in purple as expected, but they won’t stop, even after several minutes.

What can I check or try after that?

I had this kind of trouble and Cedcox kindly helped me solve it: it was a problem with pulsaudio which is superimposed on / etc / asound.conf on a raspberry PI3.

I can not say how he solved the problem, I just know it’s a multitake audio output problem instead of monotech …

Then finally I lost the sound with each reboot, and he made me add to the service snips-audio-server:
ExecStartPre = / bin / sleep 3

Thank you for a synthesis of how to solve this problem if you understand the protocol to achieve …

That sleep 3 workaround reminded me of the docs about setting up Snips along with PulseAudio: https://docs.snips.ai/articles/other-platforms/respeaker-core-2.0#RespeakerCorev2-soundconfig

But I don’t have PulseAudio installed on this machine, just libpulse0 as a dependency to many packages.

And if the mic was already taken up by another process, how could sam test microphone worked as expected? :thinking:

My issue is now fixed, the error was between the keyboard and the chair, as too often. :smiley:

I forgot to change a line when configuring the base for satellites, and the hotword and audio services were not speaking about the same site ID, so nothing would match.

I guess the new version of the platform is more strict, which is always a good thing.

1 Like

Hi borsltd

Have the feeling I’ve got the same issue. Can you please explain what you did to correct it?

Thanks