Following the instructions here (ROS Index), I installed the respeaker_ros package. However, whenever I run
roslaunch respeaker_ros sample_respeaker.launch
I get this error
**process[respeaker_node-2]: started with pid [12862]**
[WARN] [1619819447.432986]: Failed to find respeaker device by name. Using default input
[WARN] [1619819447.434782]: 32 channel is found for respeaker
[WARN] [1619819447.436162]: You may have to update firmware.
**[respeaker_node-2] process has finished cleanly**
**log file: /home/hello-robot/.ros/log/d97c2426-a9fa-11eb-86ad-94e6f7b7f4ad/respeaker_node-2*.log**
[respeaker_node-2] restarting process
**process[respeaker_node-2]: started with pid [13088]**
Expression 'ret' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1736
Expression 'AlsaOpen( &alsaApi->baseHostApiRep, params, streamDir, &self->pcm )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1904
Expression 'PaAlsaStreamComponent_Initialize( &self->capture, alsaApi, inParams, StreamDirection_In, NULL != callback )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2171
Expression 'PaAlsaStream_Initialize( stream, alsaHostApi, inputParameters, outputParameters, sampleRate, framesPerBuffer, callback, streamFlags, userData )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2840
Traceback (most recent call last):
File "/opt/ros/melodic/share/respeaker_ros/scripts/respeaker_node.py", line 428, in <module>
n = RespeakerNode()
File "/opt/ros/melodic/share/respeaker_ros/scripts/respeaker_node.py", line 323, in __init__
self.respeaker_audio = RespeakerAudio(self.on_audio, suppress_error=suppress_pyaudio_error)
File "/opt/ros/melodic/share/respeaker_ros/scripts/respeaker_node.py", line 259, in __init__
input_device_index=self.device_index,
File "/usr/lib/python2.7/dist-packages/pyaudio.py", line 750, in open
stream = Stream(self, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/pyaudio.py", line 441, in __init__
self._stream = pa.open(**arguments)
IOError: [Errno -9985] Device unavailable
[respeaker_node-2] process has died [pid 13088, exit code 1, cmd /opt/ros/melodic/share/respeaker_ros/scripts/respeaker_node.py __name:=respeaker_node __log:=/home/hello-robot/.ros/log/d97c2426-a9fa-11eb-86ad-94e6f7b7f4ad/respeaker_node-2.log].
log file: /home/hello-robot/.ros/log/d97c2426-a9fa-11eb-86ad-94e6f7b7f4ad/respeaker_node-2*.log
[respeaker_node-2] restarting process
I’m not sure why this is happening - I’ve updated the firmware multiple times. What makes this more curious is that the first time I ran this it worked but it no longer works now.