I’m trying to set up a PS3 Eye microphone in Rhasspy (Home Assistant addon) and have two problems:
Microphone only starts transmitting audio to rhasspy if I execute in HA console (in web ui): ha audio default input --name "alsa_input..."
I found this way here. But for me it only works until reboot.
The microphone does not hear well and to make it more sensitive, as I understand it, I need to configure asound.conf. But I don’t know where to place it. I tried creating it in all possible places:
/etc/asound.conf
${HOME}/.asoundrc
/usr/share/hassio/audio/asound
asoundrc input string in addon config
pcm.jack {
type hw
card ALSA
}
pcm.array {
type hw
card CameraB409241
}
pcm.softvol {
type softvol
slave.pcm "jack"
control {
name Master
card 0
}
}
pcm.cap {
type plug
slave.pcm "array"
slave.channels 4
ttable {
0.0 15.0
1.1 15.0
}
}
pcm.!default {
type asym
playback.pcm "plug:softvol"
capture.pcm {
type plug
slave.pcm "cap"
}
}
But it either does nothing or it breaks the sound in Rhasspy. I need help.
I have a different kind of problem… After I installed Rhasspy I only put 1 switch and 1 light in the slots and the buttons on my HA are now gone…
Anyone have any idea why that happened?
To the right of the Light should be a button for a Fan but it’s no longer appearing since installing Rhasspy… The fan was put in as a switch… the light associated with it is the same…button is now gone.
By specifying instead of plughw:x,x devices of your host system, looking at their commands arecord -l and aplay -l.
The problem is that the host’s audio devices are busy with the Home Assistant’s audio system. This issue is reported here: https://github.com/home-assistant/plugin-audio/issues/12
I used the solution from the penultimate post.
Once the microphone and speaker are available, /etc/asound.conf can be configured. I have it set up like this (I use PS3 eye):
pcm.array {
type hw
card CameraB409241 # microphone device name
}
pcm.array_gain {
type softvol
slave.pcm "array"
control {
name "PSEye"
count 2
card 0
}
min_dB -5.0
max_dB 30.0
}
pcm.cap {
type plug
slave.pcm "array_gain"
slave.channels 4
ttable {
0.0 15.0
1.1 15.0
}
}
pcm.speaker {
type plug
slave {
pcm {
type hw
card "KTUSBAUDIO" # speaker device name
device 0
}
}
}
pcm.!default {
type asym
capture.pcm "cap"
playback.pcm "speaker"
}
ctl.!default {
type hw
card 0
}
The path to asound.conf must be specified when running the docker image:
With this configuration, everything works well. The only problem is, when the host is rebooted, the microphone becomes unavailable and its cable needs to be re-plugged. If anyone knows how this can be solved, I will be glad to advice.
Playing with Rhasspy will get you “early access” to some things. For example, the Rhasspy 3 add-on already does local STT with Whisper, uses Assist, and does local TTS too. If you already have some Raspberry Pi’s for satellites and free, this might be the way to go for now.
I don’t know exactly what the HA side of things is going to end up like, but you can bet it will be more polished and streamlined than Rhasspy
When I set up Rhasspy I went the the automation route instead of the intent route and then I use automation like this:
id: Rhasspy Say the Date
alias: Rhasspy Say the Date
trigger:
platform: event
event_type: rhasspy_GetDate
action:
- service: script.sonos_say
data:
sonos_entity: media_player.living_room
volume: 0.5
message: " It is {{ states.sensor.date.state }} "
Has similar issue, solved it by omitting the content type, not sending binary data and pointing rhasspy to its local media folder path. curl -X POST 'http://10.0.0.X:12101/api/play-wav' -d '/profiles/media/alerts/audio.wav'