Don't understand how to be heard by Rhasspy

here is the result…

aplay: main:828: audio open error: No such file or directory

Can you try (I added the “verbose” flag to get more info):

then

verbose flag?

Yup. The -v in each command line.

ow! there is :

root@b09b5b583539:/# arecord -Dcapture -r 16000 -c 1 -f S16_LE -v test.wav
Recording WAVE ‘test.wav’ : Signed 16 bit Little Endian, Rate 16000 Hz, Mono
Plug PCM: Rate conversion PCM (48000, sformat=S16_LE)
Converter: libspeex (builtin)
Protocol version: 10002
Its setup is:
stream : CAPTURE
access : RW_INTERLEAVED
format : S16_LE
subformat : STD
channels : 1
rate : 16000
exact rate : 16000 (16000/1)
msbits : 16
buffer_size : 8000
period_size : 2000
period_time : 125000
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 2000
period_event : 0
start_threshold : 1
stop_threshold : 8000
silence_threshold: 0
silence_size : 0
boundary : 524288000
Slave: Hardware PCM card 2 ‘USB PnP Audio Device’ device 0 subdevice 0
Its setup is:
stream : CAPTURE
access : MMAP_INTERLEAVED
format : S16_LE
subformat : STD
channels : 1
rate : 48000
exact rate : 48000 (48000/1)
msbits : 16
buffer_size : 24003
period_size : 6000
period_time : 125000
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 6000
period_event : 0
start_threshold : 3
stop_threshold : 24003
silence_threshold: 0
silence_size : 0
boundary : 1573060608
appl_ptr : 0
hw_ptr : 0
^CAborted by signal Interrupt…
arecord: pcm_read:2149: read error: Interrupted system call
root@b09b5b583539:/# aplay -Dplayback -v test.wav
aplay: main:828: audio open error: No such file or directory

Ah progress!
The capture/recording seems to be working correctly.
The playback does not though…

What does aplay -L output?

happy to read that we progress :stuck_out_tongue:

root@b09b5b583539:/# aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
jack
JACK Audio Connection Kit
pulse
PulseAudio Sound Server
default
playback
capture
sysdefault:CARD=b1
bcm2835 HDMI 1, bcm2835 HDMI 1
Default Audio Device
dmix:CARD=b1,DEV=0
bcm2835 HDMI 1, bcm2835 HDMI 1
Direct sample mixing device
dsnoop:CARD=b1,DEV=0
bcm2835 HDMI 1, bcm2835 HDMI 1
Direct sample snooping device
hw:CARD=b1,DEV=0
bcm2835 HDMI 1, bcm2835 HDMI 1
Direct hardware device without any conversions
plughw:CARD=b1,DEV=0
bcm2835 HDMI 1, bcm2835 HDMI 1
Hardware device with all software conversions
usbstream:CARD=b1
bcm2835 HDMI 1
USB Stream Output
sysdefault:CARD=Headphones
bcm2835 Headphones, bcm2835 Headphones
Default Audio Device
dmix:CARD=Headphones,DEV=0
bcm2835 Headphones, bcm2835 Headphones
Direct sample mixing device
dsnoop:CARD=Headphones,DEV=0
bcm2835 Headphones, bcm2835 Headphones
Direct sample snooping device
hw:CARD=Headphones,DEV=0
bcm2835 Headphones, bcm2835 Headphones
Direct hardware device without any conversions
plughw:CARD=Headphones,DEV=0
bcm2835 Headphones, bcm2835 Headphones
Hardware device with all software conversions
usbstream:CARD=Headphones
bcm2835 Headphones
USB Stream Output
usbstream:CARD=Device
USB PnP Audio Device
USB Stream Output
sysdefault:CARD=Device_1
USB2.0 Device, USB Audio
Default Audio Device
front:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
Front speakers
surround21:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
Direct sample mixing device
dsnoop:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
Direct sample snooping device
hw:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
Direct hardware device without any conversions
plughw:CARD=Device_1,DEV=0
USB2.0 Device, USB Audio
Hardware device with all software conversions
usbstream:CARD=Device_1
USB2.0 Device
USB Stream Output

PulseAudio is back?
Can you check that it is correctly disabled after reboot?

result don’t change :s must I reboot another time? here is before rebooting :

pi@raspberrypi:~ $ pgrep -a pulseaudio
686 /usr/bin/pulseaudio --daemonize=no

Yup. PulseAudio is running… Either remove it completely or disable it for good because it will mess up with the ALSA configuration we are working with…

how? I try something I said earlier but not seems to work :s

echo "autospawn = no" > $HOME/.config/pulse/client.conf
echo "autospawn = no" > /etc/pulse/client.conf
pkill -f pulseaudio
ps aux | grep pulse

Then again:
arecord -Dcapture -r 16000 -c 1 -f S16_LE -v test.wav
and:
aplay -Dplayback -v test.wav

in docker or out?

On the host (debian), not in the container.

I’m not very familiar with PulseAudio (don’t like it, prefer ALSA).

You need to edit the files $HOME/.config/pulse/client.conf and /etc/pulse/client.conf (do not overwrite by doing the echo stuff I mention above). Change autospawn to no.

Then reboot.

PulseAudio should be disabled.

I don’t know exactly what I’ve done… I try

sudo nano $HOME/.config/pulse/client.conf

and it says that it doesn’t exist…

Nothing to change in that file then :wink:

sudo nano /etc/pulse/client.conf and change autospawn to no

it’s done ^^ what must I do know? reboot?

To be sure PulseAUdio is correctly disabled, I’d reboot, yes.

Once rebooted, ps aux | grep pulse should not display /usr/bin/pulseaudio --daemonize=no anymore.

pi@raspberrypi:~ $ ps aux | grep pulse
pi 720 2.4 1.1 210424 21668 ? S<sl 17:02 0:00 /usr/bin/pulseaudio --daemonize=no
pi 1679 0.0 0.0 7364 524 pts/0 S+ 17:02 0:00 grep --color=auto pulse

I told you I hate PulseAudio ;)…