There’s to sign of TTS being streamed there. Are you sure the pipeline is using it and that you flashed my config?
This is my device:
And I’m using your config, with the following differences:
api:
encryption:
key: <myKey>
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
ap:
password: "${wifi_ap_password}"
# Optional manual IP
manual_ip:
static_ip: 192.168.1.231
gateway: 192.168.1.1
subnet: 255.255.255.0
Hi, I’ve just got the Luxe delivered and after trying both the media-player and the voice-assistant yml from the official esphome repo (the media player doesn’t have wake word detection and the voice assistant doesn’t have volume control) I came across your config which looks to be the best yet. Kudos @tetele ! But I noticed I have to speak quite loud and from close-up in order to get the wake-word to trigger. Is it my device that’s bad and/or is there a way to boost the gain for the mic?
I think the mic is not that good. I managed to trigger the wake work from around 5-8 meters but is not always stable
My concern is [17:23:11][D][light:059]: Red: 33%, Green: 33%, Blue: 100%
. I don’t use that color in my config. Not that the color can alter the behavior, but it just caught my eye.
The part that should play back the audio response and log the action is this:
voice_assistant:
on_tts_end:
- media_player.play_media: !lambda return x;
And that should produce some logs about playing a long TTS URL, but I can’t provide a sample now because I’m not home.
That’s a hardware flaw, the speaker was designed to be mostly a speaker and less of a microphone.
As I said, I used your complete configuration. I don’t understand what can be wrong then.
Hi all,
I’ve copied @tetele gist too and it works perfectly.
By the way I also see those RGB % which are clearly not in your config file.
[10:11:17][D][light:036]: 'RaspiAudio Muse Luxe' Setting:
[10:11:17][D][light:059]: Red: 33%, Green: 33%, Blue: 100%
[10:11:17][D][light:109]: Effect: 'None'
[10:11:17][D][voice_assistant:502]: Event Type: 8
[10:11:17][D][voice_assistant:572]: Response URL: "http://192.168.1.37:8123/api/tts_proxy/05a0c69c68d23ab60e0a74a53d11a3ec29533711_es-es_d91b82395f_cloud.mp3"
[10:11:17][D][media_player:059]: 'RaspiAudio Muse Luxe' - Setting
[10:11:17][D][media_player:066]: Media URL: http://192.168.1.37:8123/api/tts_proxy/05a0c69c68d23ab60e0a74a53d11a3ec29533711_es-es_d91b82395f_cloud.mp3
Very strange. Maybe my hardware has some issue.
Can you tell me step by step how you flashed yours? I mean, I have mine “working”, except the voice return. So, mine is flashed at the moment. What should I do to flash again the @tetele code? Maybe I’m doing something wrong because there is the ESPHome inside HA, but I’m also using this one - https://web.esphome.io/ - and usually I always have to reset the device.
If someone can put here a step by step I would be very gratefully.
I’ve just copied the whole yaml into the esphome add on dashboard, save, validate, install.
Sometimes I also have missing voice return, but most of the time I do have them.
One thing I noticed on mine is that the wakeword functionality doesn’t work after a HA core restart.
One simple and quick workaround was to create an automation to turn off the wakeword switch and turn it back on after 5 seconds. Doing that the wakeword works again.
Ok will try it. But can you show me the wifi part? (of course without ips and passwords) just to make sure I have the exact same thing.
You mean this?
Also about wifi I have these lines in secrets.yaml
Hi everyone, I’m a master degree apprentice at Raspiaudio and I’ve been testing the Muse Luxe with Home Assistant to get a working voice assistant. I’ve used the code provided by @tetele and it works well, I just rearanged the begining to be easier to configure. My goal is to test if it could work with OpenAI Integration, and well, it works but you can’t control external devices with it. But it is functionnal with the Home Assistant Cloud method, and I guess with Google and Alexa too. Also as stated here and in the page made by @tetele , Piper TTS does not play audio feedback.
I can also give useful infos about the microphone and the audio codec:
- The audio codec is an ES8388. link here
- The microphone of the Muse Luxe is connected to the LIN1 pin.
- At the back, there’s a stereo Aux In port that is connected to the LIN2 and RIN2 pins, and it could be used to connect an external microphone.
Finally, using all the knowledge we have gathered, I will try to write an easy and comprehensive tutorial on how to use the Muse Luxe as a voice assistant for all the newcomers.
This should fix it
If you mean using OpenAI Conversation as a conversation agent, then yes, sure it works with that.
It will starting with HA 2023.12.
Perfect, thanks, works great!
The lack of response that sometimes happen must be a hardware problem, right?
Most definitely it’s software. The ESPHome implementation is pretty bad atm, but there are some improvements coming in HA 2023.12 and ESPHome 2023.12.
Apart from the bad microphone signal, the Muse Luxe has pretty good hardware that can surely be properly used by software in the future. We’re just not there yet.
We do think that the microphone gain could be adjusted by tweaking the I2C codec register we definitely how to do it in an Arduino / IDF environment but it’s pretty obscure to me how to send I2C commands to the Luxe in HA. Does anyone have an idea?
Also the second option we will test soon is to use a cheap stereo microphone in the AUX in jack on the back on the Luxe. I have ordered this one to test, it could bend in a right angle.
Could you point to some code, please?
@Raspiaudio how do you set the gain on that microphone? Can you share some code? Do you want people to have even more of an incentive to buy your speaker or are you satisfied with the fact that you know how to fix it and that’s that?
Hi Tetele
Louis @ raspiaudio is on the subject let’s give him a few days to come up with a code example
Thanks!