My journey with Home Automation started with a Sonoff smart switch for switching on and off a light remotely. One thing led to another as I started automating things in my new home after my relocation. Initially it was ESP 2866 with arduino IDE and few other readymade devices like smart bulbs, fan regulators etc. As it scaled up I realised that having many apps to control disparate devices was bound to become tedious in future. A colleague of mine had gifted me a raspberry pi 3B and it was lying idle, waiting for me to decide on a Smart Home system. I started my hunt and tried Domoticz, openHAB, Home Assistant all open source as I am a big fan of open source stuff. After a lot of deliberation and testing I decided to go with Home Assistant. I now have about 35 devices on my system including Bosch dish washer, Deebot Robotic Vacuum Cleaner, Washer notification, Blind Automation , a few Esphome devices. My user interfaces are dashboards, mobile app, apple watch and last but not least Voice Assistant. Currently I use alexa as a Voice Assistant and for tts messages.
Come 2023 and Home Assistant announces the 2023 as the Year of the Voice. The promise of a Local Voice Assistant was tempting and I decided to go local. It wasnât going to be easy. I first experimented with the esp32 esphome VA code with a INMP441 mic and MAX98357 DAC amplifier and the results were not encouraging. It was then that I landed on the Wyoming Satellite Project by the Voice Guy at Nabu Casa Mike Hansen and enhanced by Brad@futureproofhomes and implementation on a pi zero 2 W with a 2 mic HAT by illius. So I dedicate my project to these three guys and anyone who has contributed to the Voice Assistant effort. I also thank the great guys at Nabu Casa for Home Assistant System.
Project Details: Hardware:
Raspberry Pi Zero 2 W
32 Gb SD Card
SeeedStudio Respeaker 2 Mic HAT
4 ohms 2 W speaker with JST connector
A DIY enclosure made of Birch Wood Plywood.
Software:
Raspberry Pi OS lite ( Legacy 64-bit)
Wyoming Satellite package
Seeedstudio Respeaker 2 Mic HAT Drivers
Pulse Audio package
Snapcast server and client package
Music Assistant Add-on
Installation:
The first step was to solder the headers on the RPi Zero 2 W. Not an easy task for a 64 yr oldieđ. Snapped the Respeaker 2 mic hat onto the Pi Zero.
Burning the Raspberry Pi OS lite (Legacy 64-bit) image on the SD Card
Install the Wyoming Satellite package and drivers for the Respeaker 2mic HAT. Test the mic and speaker using aplay and arecord. Just followed the tutorial by llluis and installation was a breeze
FutureProofHomes tutorial enthused me to push further and transform my PVA into a Voice Assisted Media Player also. Installed Pulseaudio, Snapcast Server add-on on HA Server and Client on RPi Zero . Also installed the wonderful extended OpenAI conversation integration and Music Assistant on HA. Did all the configuration as given in the tutorial. Works well though I need do a few tweaks.
Planning to make a Wooden enclosure. Still working out the design and thinking of adding a battery to make it portable to carry around the house.
Made some progress and prototyped an enclosure for the PVA with cardboard. A quick look at it.
Safe Shutdown Switch
Configured the button on the Respeaker HAT Corresponding to GPIO17. Used dtoverlay=gpio-shutdown,gpio_pin=17 in config.txt
Battery Backup.
The Rpi Zero 2W runs hot(65 C). Wrote a script to monitor the temperature in HA. Looks like I need to add a small cooling fan inside. Phew⌠the list is getting long. Target 10th Mar 2024
Ive found that putting the detection and tts stop commands just under the wake URI line solved an issue I was having with the volume not staying low during the whole time the assistant is speaking.
Also, I put the sounds just under the wake word name line. This gives the audio cue at the same time as the led cue. Maybe just before. Before, the led would happen first and the first word of my commands would get cut off.
Never thought that the sequence would matter much. Kept adding them as per the tutorial. Will try your suggestion and see how it goes. Thanks for the same.
Here is my config. Lots of experimentingâŚ
I added the error command. The issue I was having is that when music was playing, and the wake word was detected when no wake word was said, it wouldnt resume the music at the starting volume. You can test this by saying your wake word and keeping quiet. After a few seconds it will time out but the music volume wont go back up. The error command fixed that.
Im not entirely convinced the VAD settings are doing anything. I cant seem tio find an answer on thisâŚ
The open wake word integration has these settings, it would seem the satellites would alsoâŚ
Mine would be table top. I just tried the button on the respeaker HAT button corresponding to GPIO17 and it works only for shutdown. I have to repower it to boot. Used dtoverlay=gpio-shutdown,gpio_pin=17
I donât believe the vad settings do anything without also passing in --vad. Also though, VAD is not supported with a local openWakeWord, if I recall correctly about the error I had when I tried enabling vad
Thanks. I wound up re-training my custom wake word and it seems to have helped alot. Even though the one I was using was well trainedâŚ
My original I had the first 2 sliders set at 50,000 and left the false_activation_penalty alone.
This time I set the false_activation_penalty to 2650.
I loaded it this morning and I dont think I have had any false triggers yet with a TV /radio playing all day.
Sounds like I might need to train my own wake word. I am using the built in âAlexaâ but it triggers on the sounds of rain sometimes. I tried using âOk Nabuâ but it was triggering randomly, but wouldnât trigger when I said it.
Edit: Right after clicking âSendâ, it triggered on a sighâŚ
Itll cost a couple bucks but probably worth it in the long run.
2650 was a little aggressive. Its hard to trigger when there is background noise.Gonna split the difference between default and 2650.
First 2 sliders at 50,000 and the false_activation_penalty set at 2000 is working really well. No false activations in the past couple hours and responds well even with the tv playing.
Does the RPi zero 2w with Respeaker 2 mic HAT heat up in your satellite. Mine heats upto 65-66 C in an ambient temperature of 32C. Since I am planning to put it into a wooden enclosure looks like I gotta add a small cooling fan in it.
Yes, it gets quite warm when playing music.
The one I put in the loft ceiling I had put a box over the enclosure to keep the blow in insulation out of it. That one would play about 10 minutes before shutting down due to heat. I put an exhaust stack in the box and it fixed it up.
How do you change the volume of the satellite , both piper output and music assistant output? snd-volume-multiplier is not convenient and cannot be done on the fly. Unless you follow the enhancement by futureproofhomes.
For Music assistant youll have a volume slider.
I just adjusted my amplifier violume to where I like the voice assistant.
I purchased this since I have the voice assistant sharing speakers with my surround system. I alos have a chromecast for TTS announcements. I can adjust the volume of all 3 with this. https://www.amazon.com/gp/product/B09XH3WPXR?ref=ppx_pt2_dt_b_prod_image
Hi Rich37804, can I ask how you managed to configure custom wake words to work? Iâve been going around in circles.
I have added in what I understand to me the service config requirements, and saved the custom wake word to the corresponding directory, but to no alas.