You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I am currently trying to install and get Alice up and running on my Raspberry pi but sadly I am facing some issues that I can't seem to fix myself or find a workaround online that fixes this for me.
At the moment I can't hear and can't seem to trigger the wake-up word.
I understand from my little research this most likely is an issue with my raspberry pi/devices but still I have run out of options to try and failed to try to fix it myself. Any help would be much appreciated.
If you need the output from a command please ask!
I am running an up to date version of buster on my RaspberryPi with no packages needing to be updated.
I have a USB microphone that seems to record my voice fine and Headphones plugged in through the 3.5mm jack (I don't have another way of playing back sounds at the moment).
I have tested both by recording a quick sample with arecord --rate=48000 -t raw and playing it back with aplay --rate=48000. I can hear my voice just fine through the headphones (with just a little bit of noise).
When I start up Alice these are the logs I get
(...)
[DeviceManager] Loaded 1 device
[AudioManager] Starting
[AudioManager] Using USB PnP Sound Device for audio input
[AudioManager] Using dmix for audio output
[AudioManager] Starting audio publisher
Expression 'paInvalidSampleRate' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2048
Expression 'PaAlsaStreamComponent_InitialConfigure( &self->capture, inParams, self->primeBuffers, hwParamsCapture, &realSr )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2719
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2843
[ThreadManager] Started new thread audioPublisher, thread count: 2
[InternetManager] Starting
Exception in thread audioPublisher:
Traceback (most recent call last):
File "/usr/lib/python3.7/threading.py", line 917, in _bootstrap_inner
self.run()
File "/usr/lib/python3.7/threading.py", line 865, in run
self._target(*self._args, **self._kwargs)
File "/home/pi/ProjectAlice/core/server/AudioServer.py", line 126, in publishAudio
blocksize=self.FRAMES_PER_BUFFER,
File "/home/pi/ProjectAlice/venv/lib/python3.7/site-packages/sounddevice.py", line 1187, in __init__
**_remove_self(locals()))
File "/home/pi/ProjectAlice/venv/lib/python3.7/site-packages/sounddevice.py", line 895, in __init__
'Error opening {}'.format(self.__class__.__name__))
File "/home/pi/ProjectAlice/venv/lib/python3.7/site-packages/sounddevice.py", line 2738, in _check
raise PortAudioError(errormsg, err)
sounddevice.PortAudioError: Error opening RawInputStream: Invalid sample rate [PaErrorCode -9997]
[ThreadManager] Started new thread internetCheckThread, thread count: 2
[DatabaseManager] Starting
(...)
[DialogTemplateManager] Checking data for skill Telemetry
[DialogTemplateManager] Cache uptodate
Expression 'paInvalidSampleRate' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2048
Expression 'PaAlsaStreamComponent_InitialConfigure( &self->playback, outParams, self->primeBuffers, hwParamsPlayback, &realSr )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2722
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2843
[AudioManager] Playing wav failed with error: Error opening RawOutputStream: Invalid sample rate [PaErrorCode -9997]
[ThreadManager] Started new thread checkHeartbeats, thread count: 10
[ThreadManager] Started new thread heartBeatThread-1605017487, thread count: 10
[RedQueen] Scheduled next random speaking in 1313 seconds
[SnipsNlu] Starting Snips NLU
[Project Alice] Started in 14.26 seconds
From this I noticed at the beginning it only loads 1 device even though I manually specified both "inputDevice" and "outputDevice" in config.json as follows
(...)
"asoundConfig": "pcm.!default {\n type asym\n playback.pcm {\n type plug\n slave.pcm \"hw:2,0\"\n }\n capture.pcm {\n type plug\n slave.pcm \"hw:1,0\"\n }\n}\n",
(...)
"inputDevice": "USB PnP Sound Device",
"outputDevice": "bcm2835 Headphones",
(...)
FYI here are the contents of both my ~/.asoundrc
pcm.!default {
type asym
playback.pcm {
type plug
slave.pcm "hw:1,0"
}
capture.pcm {
type plug
slave.pcm "hw:2,0"
}
}
and /usr/share/alsa/alsa.conf where I edited these two lines from 0 to 1 in an attempt to make the Headphones the default device and as such try to see if Alice would pick it up and use it... no luck.
The webUI is working and it's accessible from my laptop so from there I have tried the "ALICEWATCH" from which I only see this no matter what I say or try to do:
In the Audio setting on the Admin section the only options I have available are the ones Alice seems to pick up, which is the USB microphone and the dmix (failed to detect headphones?)
I am using snip for the wakeup engine and as such am trying to wake her up with "Hey snips"
In alsamixer both the Headphones and Microphone are set to their loudest record and play sounds.
I know only the very basics of python myself but still tried to look at what could be obvious here for my specific issue and in I tried to update the code at core/server/AudioServer.py and change the SAMPLERATE value to 48000 but to no avail (I am not too sure of this change myself if that's not clear 😆 )
And also tried to check what was coming from the call at ln59, here's the output
Hi, I am currently trying to install and get Alice up and running on my Raspberry pi but sadly I am facing some issues that I can't seem to fix myself or find a workaround online that fixes this for me.
At the moment I can't hear and can't seem to trigger the wake-up word.
I understand from my little research this most likely is an issue with my raspberry pi/devices but still I have run out of options to try and failed to try to fix it myself. Any help would be much appreciated.
If you need the output from a command please ask!
I am running an up to date version of buster on my RaspberryPi with no packages needing to be updated.
I have a USB microphone that seems to record my voice fine and Headphones plugged in through the 3.5mm jack (I don't have another way of playing back sounds at the moment).
I have tested both by recording a quick sample with
arecord --rate=48000 -t raw
and playing it back withaplay --rate=48000
. I can hear my voice just fine through the headphones (with just a little bit of noise).When I start up Alice these are the logs I get
From this I noticed at the beginning it only loads 1 device even though I manually specified both "inputDevice" and "outputDevice" in
config.json
as followsFYI here are the contents of both my
~/.asoundrc
and
/usr/share/alsa/alsa.conf
where I edited these two lines from 0 to 1 in an attempt to make the Headphones the default device and as such try to see if Alice would pick it up and use it... no luck.Output of both
arecord -l
and
aplay -l
**** List of PLAYBACK Hardware Devices ****
The webUI is working and it's accessible from my laptop so from there I have tried the "ALICEWATCH" from which I only see this no matter what I say or try to do:
In the Audio setting on the Admin section the only options I have available are the ones Alice seems to pick up, which is the USB microphone and the dmix (failed to detect headphones?)
I am using snip for the wakeup engine and as such am trying to wake her up with "Hey snips"
In
alsamixer
both the Headphones and Microphone are set to their loudest record and play sounds.I know only the very basics of python myself but still tried to look at what could be obvious here for my specific issue and in I tried to update the code at
core/server/AudioServer.py
and change the SAMPLERATE value to 48000 but to no avail (I am not too sure of this change myself if that's not clear 😆 )And also tried to check what was coming from the call at ln59, here's the output
The text was updated successfully, but these errors were encountered: