Jasper...Almost ready - can't set up the Mic

346 views
Skip to first unread message

Aviv Baron

unread,
Aug 17, 2016, 12:50:59 AM8/17/16
to Jasper Support Forum
Hi

I have been working on getting Jasper properly configured on my Raspberry Pi 3.

At this point I can run Jasper and this is what I get back:


*******************************************************

*             JASPER - THE TALKING COMPUTER           *

* (c) 2015 Shubhro Saha, Charlie Marsh & Jan Holthuis *

*******************************************************

WARNING:root:tts_engine not specified in profile, defaulting to 'espeak-tts'

ALSA lib confmisc.c:768:(parse_card) cannot find card '1'

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory

ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory

ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:4738:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM sysdefault

ALSA lib confmisc.c:768:(parse_card) cannot find card '1'

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory

ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory

ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:4738:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM sysdefault

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline

ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused


ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused


ALSA lib confmisc.c:768:(parse_card) cannot find card '1'

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory

ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory

ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name

ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory

ALSA lib conf.c:4738:(snd_config_expand) Evaluate error: No such file or directory

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM dmix

Cannot connect to server socket err = No such file or directory

Cannot connect to server request channel

jack server is not running or cannot be started

Traceback (most recent call last):

  File "/home/pi/jasper/jasper.py", line 151, in <module>

    app.run()

  File "/home/pi/jasper/jasper.py", line 121, in run

    conversation.handleForever()

  File "/home/pi/jasper/client/conversation.py", line 31, in handleForever

    threshold, transcribed = self.mic.passiveListen(self.persona)

  File "/home/pi/jasper/client/mic.py", line 110, in passiveListen

    frames_per_buffer=CHUNK)

  File "/usr/lib/python2.7/dist-packages/pyaudio.py", line 747, in open

    stream = Stream(self, *args, **kwargs)

  File "/usr/lib/python2.7/dist-packages/pyaudio.py", line 442, in __init__

    self._stream = pa.open(**arguments)

IOError: [Errno Invalid input device (no default output device)] -9996


I am new to python but the one thing I can tell is that my Mic is not set up correctly. 

Here is the mic I am using:

When I try 

sudo arecord -f S16_LE -d 20 -r 8000 -D hw:1,0 test.wav

I end up with 

ALSA lib pcm_hw.c:1667:(_snd_pcm_hw_open) Invalid value for card

arecord: main:722: audio open error: No such file or directory


When I try 

aplay -l


I end up with 

**** List of PLAYBACK Hardware Devices ****

card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]

  Subdevices: 8/8

  Subdevice #0: subdevice #0

  Subdevice #1: subdevice #1

  Subdevice #2: subdevice #2

  Subdevice #3: subdevice #3

  Subdevice #4: subdevice #4

  Subdevice #5: subdevice #5

  Subdevice #6: subdevice #6

  Subdevice #7: subdevice #7

card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 ALSA [bcm2835 IEC958/HDMI]

  Subdevices: 1/1

  Subdevice #0: subdevice #0


I am stuck here!




Matthew Curry

unread,
Aug 17, 2016, 12:53:23 PM8/17/16
to Jasper Support Forum
Aviv, I have written a script for this. Please join us in slack and I am happy to help.

It is in the jasper-rpi-tools repo under audio. USB-mic-fix.sh and reboot

it should resolve your issues

Parapraxis Productions

unread,
Aug 19, 2016, 8:05:42 AM8/19/16
to Jasper Support Forum
When i run the script i get permission denied...

Matthew Curry

unread,
Aug 19, 2016, 9:57:56 AM8/19/16
to Jasper Support Forum
run it with sudo...  and then reboot; however the script may need an update. I had a use say there was a bug in it.  If you run into this please let me know.

Matthew Curry

unread,
Aug 19, 2016, 10:37:42 AM8/19/16
to Jasper Support Forum
updated the script. do a 'git pull' in the dir
but it would have still worked

Aviv Baron

unread,
Aug 21, 2016, 9:17:21 PM8/21/16
to Jasper Support Forum
How do I join the slack group?

Matthew Curry

unread,
Aug 27, 2016, 4:31:33 PM8/27/16
to Jasper Support Forum
The link on the main forum page... title SLACK INVITE

djtremors

unread,
Jan 14, 2017, 6:24:24 AM1/14/17
to Jasper Support Forum
What is the point of helping on slack and not post up on the page here. I've got the same problem and nothing about results on slack.

Matthew Curry

unread,
Jan 18, 2017, 3:46:46 PM1/18/17
to Jasper Support Forum
Well, slack keeps its history, and there is almost always someone on there.  It doesn't sound like you are familiar with it.  Its for software development specifically, and has tools built in for exactly what we are doing.

No on is stopping you from posting here, just don't expect as fast an answer as this is basically an antiquated method for troubleshooting.
Reply all
Reply to author
Forward
0 new messages