rhasspy / wyoming-satellite

Remote voice satellite using Wyoming protocol
MIT License
509 stars 74 forks source link

USB speaker/mic not triggering wake word #43

Open simonlirwin opened 6 months ago

simonlirwin commented 6 months ago

I'm using a Pi Zero 2W with a Jabra 410 conference speaker/mic connected through an adapter. HA is running on a Pi 4 set up with cloudflare and SSL, and the voice assistant works fine on other devices. The arecord and aplay work fine with good audio quality playback through the speaker. Showing in HA as expected. I first tried without the wake word detection set up. Nothing seemed to be triggering at all. Then I've set up wake word detection hoping it would work better. Both services are showing green. However, I'm getting absolutely no change to Assist in Progress when using the wakeword. I've tried using a USB headset but that has the same issue.

pcwii commented 6 months ago

Did you install the Wyoming protocol in HA for this satellite?

simonlirwin commented 6 months ago

Did you install the Wyoming protocol in HA for this satellite?

Yes I did. The device shows as expected with pipeline selection. Assist in progress is 'off' and never changes

Rafaille commented 6 months ago

I'm using a Pi Zero 2W with a Jabra 410 conference speaker/mic connected through an adapter. HA is running on a Pi 4 set up with cloudflare and SSL, and the voice assistant works fine on other devices. The arecord and aplay work fine with good audio quality playback through the speaker. Showing in HA as expected. I first tried without the wake word detection set up. Nothing seemed to be triggering at all. Then I've set up wake word detection hoping it would work better. Both services are showing green. However, I'm getting absolutely no change to Assist in Progress when using the wakeword. I've tried using a USB headset but that has the same issue.

Apart from showing green, what is the log output of wyoming-satellite?

preimmortal commented 6 months ago

I'm seeing something similar in my setup. arecord and aplay is working correctly and I can hear sound from the mic loopback, but no audio seems to be sent to the server. Here's the satellite log:

│ satellite DEBUG:root:Namespace(mic_uri=None, mic_command='arecord -r 16000 -c 2 -f S16_LE -t raw -D hw:0,0', mic_command_rate=16000, mic_command_width=2, mic_command_channels=1, mic_command_samples_per_ch │
│ satellite INFO:root:Ready                                                                                                                                                                                    
│ satellite DEBUG:root:Detected IP: <REDACTED>                                                                                                                                                               
│ satellite DEBUG:root:Zeroconf discovery enabled (name=221d24bb16c9, host=None)                                                                                                                               
│ satellite DEBUG:root:Connecting to mic service: ['arecord', '-r', '16000', '-c', '2', '-f', 'S16_LE', '-t', 'raw', '-D', 'hw:0,0']                                                                           
│ satellite DEBUG:root:Connecting to snd service: ['aplay', '-r', '16000', '-c', '2', '-f', 'S16_LE', '-t', 'raw', '-D', 'hw:0,0']                                                                             
│ satellite DEBUG:root:Connecting to wake service: tcp://localhost:10400                                                                                                                                       
│ satellite INFO:root:Connected to services                                                                                                                                                                    
│ satellite Recording raw data 'stdin' : Signed 16 bit Little Endian, Rate 16000 Hz, Stereo                                                                                                                    
│ satellite DEBUG:root:Connected to mic service                                                                                                                                                                
│ satellite DEBUG:root:Connected to wake service                                                                                                                                                               
│ satellite DEBUG:root:Server set: <REDACTED>                                                                                                                                                               
│ satellite INFO:root:Waiting for wake word 
don86nl commented 5 months ago

Same issue here. Aplay and arecord work. Logs show no wake word activity

preimmortal commented 5 months ago

The issue I had was that my snd_command was never exiting, thus causing the server to never progress after trying to play the initialization sound. This possibly has something to do with my specific sound device or some hardware issue.

To get around the issue, I had to disable the snd_command.

Hope this helps.

don86nl commented 5 months ago

Thanks for the help, @preimmortal. Unfortunately, this didn't help.

wyoming-satelite.service (running) Jan 31 14:16:20 wyoming01 systemd[1]: Started Wyoming Satellite. Jan 31 14:16:21 wyoming01 run[860]: INFO:root:Ready Jan 31 14:16:21 wyoming01 run[860]: INFO:root:Connected to services Jan 31 14:16:21 wyoming01 run[862]: Recording raw data 'stdin' : Signed 16 bit Little Endian, Rate 48000 Hz, Mono

wyoming-openwakeword.service: Jan 31 14:15:29 wyoming01 systemd[1]: Started Wyoming openWakeWord. Jan 31 14:15:31 wyoming01 run[826]: INFO:root:Ready Jan 31 14:15:34 wyoming01 run[826]: INFO: Created TensorFlow Lite XNNPACK delegate for CPU.

don86nl commented 5 months ago

I reïnstalled the device, now using the Installer. The wakeword "ok_nabu" still didn't work. Then I tried another; "hey_jarvis". This one does work.

bektorkhan commented 4 months ago

Check your noiselevel... USB power is very noisy, I got rid off most noise from OrangePi Zer 2W USB, by voltage booster MT3608 to 8V and a 7805 analog 5V regulator.. back to 5V to the Cmedia USB Audio. Cut only red and black wires on an USB extension cable, put the voltage booster and regulator there!!

philmehew commented 3 weeks ago

I've got the same issue here I think. rebuilt twice, wakeword not being detected

Details: Pi Zero 2 and Pi3b with Pi OS Lite 64bit (bookworm) using the latest rhaspy/wyoming-satellite build installation interface all configured as per the docs, mic and speaker seem to get set up ok tested aplay and arecord separately, same device used, all works fine, loud and clear journal has no errors, even in debug, sits at waiting for wakeword HA auto discovers the devices, configured Wyoming, tried default any my own pipeline No Logs in HA Tried a conference speaker and a pair of USB headphones.

Be handy to know how to troubleshoot better.

Edit: I've just rebuilt my Pi3 with Bullseye version of PI OS, and I'm now getting wakeword detection...could it be something in the Bookworm PI OS build?