No Audio Output on Picroft with Jabra 410


#41

Hello ,

Thank you for your answer
LOGS :

==> /var/log/mycroft/audio.log <==
audio.shutdown()
File “/home/pi/mycroft-core/mycroft/audio/audioservice.py”, line 494, in shutdown
self.bus.remove(‘mycroft.audio.service.play’, self._play)
File “/home/pi/mycroft-core/mycroft/messagebus/client/ws.py”, line 163, in remove
self.emitter.remove_listener(event_name, func)
File “/home/pi/mycroft-core/mycroft/messagebus/client/threaded_event_emitter.py”, line 57, in remove_listener
return super().remove_listener(event_name, func)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/pyee/init.py”, line 205, in remove_listener
self._events[event].pop(f)
KeyError: <bound method AudioService._play of <mycroft.audio.audioservice.AudioService object at 0x74f1baf0>>

==> /var/log/mycroft/audio.log.txt <==
audio.shutdown()
File “/home/pi/mycroft-core/mycroft/audio/audioservice.py”, line 494, in shutdown
self.bus.remove(‘mycroft.audio.service.play’, self._play)
File “/home/pi/mycroft-core/mycroft/messagebus/client/ws.py”, line 163, in remove
self.emitter.remove_listener(event_name, func)
File “/home/pi/mycroft-core/mycroft/messagebus/client/threaded_event_emitter.py”, line 57, in remove_listener
return super().remove_listener(event_name, func)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/pyee/init.py”, line 205, in remove_listener
self._events[event].pop(f)
KeyError: <bound method AudioService._play of <mycroft.audio.audioservice.AudioService object at 0x74f6fad0>>

==> /var/log/mycroft/bus.log <==
07:39:58.174 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.70ms
07:40:00.781 - tornado.access - INFO - 101 GET /core (127.0.0.1) 7.06ms
07:40:02.226 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.25ms
11:29:21.629 - mycroft.api:is_paired:445 - WARNING - Could not get device info: ConnectionError(MaxRetryError(“HTTPSConnectionPool(host=‘api.mycroft.ai’, port=443): Max retries exceeded with url: /v1/device/b5aec5d9-3b91-4e8f-8a49-24cf3f6e4f10 (Caused by NewConnectionError(’<urllib3.connection.VerifiedHTTPSConnection object at 0x7563cbd0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution’,))”,),)
11:29:22.085 - tornado.access - INFO - 101 GET /core (127.0.0.1) 5.05ms
11:29:22.138 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.69ms
11:29:22.146 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.97ms
11:29:22.823 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.80ms
11:29:25.926 - tornado.access - INFO - 101 GET /core (127.0.0.1) 2.76ms
11:29:26.787 - tornado.access - INFO - 101 GET /core (127.0.0.1) 4.23ms

==> /var/log/mycroft/enclosure.log <==
options.pop(‘socket’, None))
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 120, in connect
sock = _open_socket(addrinfo_list, options.sockopt, options.timeout)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 190, in _open_socket
raise err
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 170, in _open_socket
sock.connect(address)
ConnectionRefusedError: [Errno 111] Connection refused
11:30:45.448 - mycroft.messagebus.client.ws:on_error:81 - ERROR - Exception closing websocket: ConnectionRefusedError(111, ‘Connection refused’)
11:30:45.457 - mycroft.messagebus.client.ws:on_error:83 - WARNING - WS Client will reconnect in 60 seconds.

==> /var/log/mycroft/skills.log <==
options.pop(‘socket’, None))
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 120, in connect
sock = _open_socket(addrinfo_list, options.sockopt, options.timeout)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 190, in _open_socket
raise err
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/websocket/_http.py”, line 170, in _open_socket
sock.connect(address)
ConnectionRefusedError: [Errno 111] Connection refused
11:30:45.349 - mycroft.messagebus.client.ws:on_error:81 - ERROR - Exception closing websocket: ConnectionRefusedError(111, ‘Connection refused’)
11:30:45.365 - mycroft.messagebus.client.ws:on_error:83 - WARNING - WS Client will reconnect in 60 seconds.

==> /var/log/mycroft/voice.log <==
resp = self.send(prep, **send_kwargs)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/requests/sessions.py”, line 637, in send
r = adapter.send(request, **kwargs)
File “/home/pi/mycroft-core/.venv/lib/python3.5/site-packages/requests/adapters.py”, line 516, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host=‘github.com’, port=443): Max retries exceeded with url: /MycroftAI/precise-data/raw/dist/armv7l/latest (Caused by NewConnectionError(’<urllib3.connection.VerifiedHTTPSConnection object at 0x74ec1bb0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution’,))
11:29:21.382 - mycroft.client.speech.hotword_factory:load_module:277 - INFO - Loading “hey mycroft” wake word via pocketsphinx
11:29:21.878 - mycroft.client.speech.listener:create_wakeup_recognizer:269 - INFO - creating stand up word engine
11:29:21.883 - mycroft.client.speech.hotword_factory:load_module:277 - INFO - Loading “wake up” wake word via pocketsphinx
11:29:22.094 - mycroft.messagebus.client.ws:on_open:60 - INFO - Connected

Thanks


#42

Hi Elimane, I was just rereading your last post and when you said:

Does this mean it’s coming out of a different device? Are you hearing some sounds but not the dialogue spoken by Mycroft, or no sound at all?

Can I also confirm that you’ve already tried the steps djl listed above in post #26?

If so, it would be good to see the output of alsa-info. Running this should write to a txt file, something like /tmp/alsa-info.txt.sjZKu3eeLd. The contents of that file are probably quite long so you can upload this to termbin using:
cat /path/to/file.txt | nc termbin.com 9999


#43

Hello ,

-There is no sound coming out of the jabra. The microphone recognizes correctly my voice but the answer is only displayed in writing.

-I tried the setps djl but that does not change anything

-I ran alsa-info :

libkmod: ERROR …/libkmod/libkmod-config.c:635 kmod_config_parse: /etc/modprobe.d/alsa-base.conf line 1: ignoring bad line starting with ‘option’

libkmod: ERROR …/libkmod/libkmod-config.c:635 kmod_config_parse: /etc/modprobe.d/alsa-base.conf line 2: ignoring bad line starting with ‘option’

ALSA Information Script v 0.4.64


This script visits the following commands/files to collect diagnostic

information about your ALSA installation and sound related hardware.

dmesg

lspci

lsmod

aplay

amixer

alsactl

/proc/asound/

/sys/class/sound/

~/.asoundrc (etc.)

See ‘/usr/sbin/alsa-info --help’ for command line options.

libkmod: ERROR …/libkmod/libkmod-config.c:635 kmod_config_parse: /etc/modprobe.d/alsa-base.conf line 1: ignoring bad line starting with ‘option’

libkmod: ERROR …/libkmod/libkmod-config.c:635 kmod_config_parse: /etc/modprobe.d/alsa-base.conf line 2: ignoring bad line starting with 'op

-This actually created me a file alsa-info.2wGWCJmnyb , but this file is empty


#44

Have you double checked /etc/modprobe.d/alsa-base.conf?

There’s clearly something it doesn’t like about the two lines added in djl’s step 2. Can you post the contents of that file?


#45

The content of the file /etc/modprobe.d/alsa-base.conf

option snd_usb_audio index=0
option snd_bcm2835 index=-2


#46

Ah I think these two lines should start with “options” rather than “option”.

Hoping that makes a difference :crossed_fingers:


#47

Sorry for the long time offline, I have been busy and will be busy for some time. My summer holidays are coming up so by then I will look at it again. Thanks in advance


#48

Hello folks,
pinging @djl @KathyReid

I just wanted to put my 5 cents here. I spent the whole night yesterday trying to make Mycroft work with Jabra, and this thread has been invaluable, just like this random find:

I followed all the instructions and learnt a lot about pulseaudio and alsa in the process, but still can’t figure exactly out what’s wrong. So far Mycroft works, and the only differences with the approach mentioned above are:

  1. Used the config from gist, renaming hw:1,0 into hw:0,0.
  2. Replacing the /etc/asound.conf with the one from gist, with same changes.
  3. Adding a “-D sysdefault” flag to the “play_wav_cmdline” parameter

I would love to know however what’s the reason why the default call to aplay %1 ends up producing no sound, as opposed to a -D sysdefault call (which I d guess supposed to be the same?)

[EDIT]: I think i figured how to solve the default situation according to this ancient bug:
https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/295832

the solution is to go into /usr/share/alsa/pulse-alsa.conf and replace the pcm.!default with your devices of choice (in my case):

pcm.jabra {
type hw
card 0
device 0
rate 48000
}

pcm.!default {
type asym
playback.pcm {
type plug
slave.pcm “jabra”
}
capture.pcm {
type plug
slave.pcm “hw:0,0”
}
}

I also cannot figure out still how to adjust the volume; I get the error:

amixer: Unable to find simple control 'PCM',0

It is surprising and frustrating at the same time that Jabra Speaker is mentioned on the front page, and yet causes so much btt-hurt. Imagine my frustration coming here after spending a previous weekend realizing that Bluetooth speaker / mic combo does not work well either…


#49

I’m in the same boat, purchased a Jabra 410 because it was specifically listed as compatible. Spending a little over 4 hours this weekend attempting and failing to get it working isn’t really what I would describe as compatible. Please remove the Jabra 410 from the compatibility list since it clearly is not.


#50

I’ve updated the Picroft documentation with a column for hardware status, added that problems are being reported for Jabra, and linked to this thread.

This is a challenge as we want to add details on devices that have been reported as working, however as ALSA and Pulse update things sometimes break.

Hopefully we can find a resolution for these problems as I know a number of people in the Community use this mic.


#51

Thank you very much, I understand that finding a solution is difficult but than at least people should know about it. I am going to try again soon since there are new images out with Debian Buster and that could maybe help with the problems. If this not the case and after some trial and error someone can find a solution, it is not outdated as fast.


#52

Okay, I have tried installing Mycroft again with the latest stable image. I haven’t got the speaker working yet but it is different now: in Mycroft, the microphone works fine but the answers don’t get throught. What is interesting is that the Alsa test (arecord -d 10 test.wav and then aplay test.wav) does work. Does this change the problem significantly? As far as I can see, at least in the audio log, there is nothing out of the ordinary except maybe:

Failed to load service. NameError(“no function ‘libvlc_new’”,)

P.S:
I have copied the log files over. The link to them is here (Google Drive)


#53

So the mic is working but audio output is not? Is this for all audio eg the wake up beep and playing the news, or just the spoken responses?

If it’s all audio, then I’d first try setting the play commands, which can now be done with the following commands:

mycroft-config set play_wav_cmdline "aplay %1"
mycroft-config set play_mp3_cmdline "mpg123 %1"

I’d also double check in alsamixer that the playback device is selected and the volume is at a reasonable level.


#54

I too am having the same problem with the Jabra 410 and Picroft.

The microphone works fine but the speaker does not. If I log into the Picroft using PuTTY, I can talk to MyCroft and read his responses through PuTTY but he doesn’t make any sound through the Jabra.

I’m a total novice so have no idea what to do.


#55

Hi Storm, when connected to the Picroft in PuTTY, can you try the two commands above, reboot the Pi and see if there’s any difference?


#56

Hi gez, tried both commands and still nothing, am I doing it right?

When I tried the first command I copied it from above and right clicked in PuTTY and MyCroft said (wrote) something about there being no recording and he wanted me to tell him to make a recording by saying “start recording”, so I make a short recording, asked him to stop recording again and re-entered the command, I’m guessing he was supposed to try and play the recording but there was still no sound. It was the same thing with the second command, just silence while he did his thing.


#57

Hey Storm, it sounds like you might have entered this into the Mycroft CLI?

I should have clarified that, we want to enter this into the shell, so you should see something like:
pi@picroft:~$

If you’re in colored interface with log messages, utterances history etc, then hit Ctrl+C to exit that and get back to the shell. Once you have entered commands into the shell, you can reopen the CLI with the command:
mycroft-cli-client


#58

Hey gez, you fixed him! Thank you so much!!!

When he started working he scared the life out of me he was so loud, turns out he must be one of those Spinal Tap MyCrofts because he had his volume set to 11.

Really can’t thank you enough gez, I’ve been struggling with this off and on for longer than I’d care to admit and had given up and thrown him back into the drawer more than once, so I’m absolutely delighted he’s working now. Internet high five!


#59

Hooray, that’s excellent to hear :tada:

Maybe he was just finding his way to the stage :wink:


#60

That did the trick
:fireworks:
Thank you so much Gez! This afternoon I downloaded and installed the updated image to see if that made a difference. After I ran throught the setup again I thought that it didn’t work but these two lines did the trick. Can you maybe explain why this is? I am quite interested why these “magic lines” work. :slight_smile: