synesthesiam / homeassistant-satellite

Streaming audio satellite for Home Assistant
MIT License
188 stars 23 forks source link

[Feature] Send actions as HA events and disable all audio output #80

Open ACiDGRiM opened 11 months ago

ACiDGRiM commented 11 months ago

I'm very happy with this, the hidden feature for cmd_mic lets me pipe in audio from an existing microphone in each room, however I have some scenarios where I would rather not have to also have a speaker connected to the satellite. It would be nice if there was a way to decouple the response, including awake/done chimes, from the satellite and route them to the appropriate media player.

In my specific situation, I just want to run several instances of the satellite within docker containers, pipe in the microphone audio with cmd_microphone, and then send the audio to which ever speaker is in the same room as the mic. right now, I'm re-streaming the pulseaudio output to sonos speakers which has a 2sec delay. however sending a tts.speak announcement to the sonos is realtime and ducks the music independent of pulse audio, so this would be a much more responsive option.

I think this could be as simple as sending an event to homeassistant with data of hostname, message, and activity (listen start, listen end, response) then I can automate the rest including awake/done by using hostname to identify the speaker