Simultaneous audio streams per zone? #71
-
You mention that it can "play up to 4 simultaneous audio streams". It isn't clear to me whether this means that for each zone you can define one source audio stream or if it is even possible to simultaneously play multiple streams to the same zone. Background of my question is a smart home use case: While using the zones for playing individual audio streams per room, I am using speakers for text-2-speech notifications throughout the house - stuff like "doorbell sound", "telephone caller announcement", "washing machine is done" or "lunch is ready". From an automation logic perspective, it is very cumbersome to switch all zones to the "notification source" for a few seconds and then back to the original source for each zone. Also from a UX perspective, it is much nicer to have the notification "overlaid" over the music stream instead of cutting it off. Ideally, there should even be a small fade-out/-in of the music to a lower volume when a notification is played, but that's likely too much to ask for 😄 . Is this use case something you have in mind and which you see could be realized with AmpliPi? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hello Kai, Thanks for reaching out! (And thank you for all your awesome work on OpenHAB! 😄 I had an OpenHAB setup at my old house, I have yet to set it up at my new house, but it's on my to-do list!) The announcement feature you describe can definitely be implemented on AmpliPi. Here are some initial thoughts: Our 0.5 software milestone will include presets for source/zone configurations. A preset could be made for "announcement mode" (e.g. set all zones to one of the digital sources from the Pi playing text-to-speech). Whenever a preset is loaded, it saves the current state as a "last configuration" that can be loaded. After the announcement is completed, it can restore that saved configuration and return to the original state. (In the most basic implementation, it would merely switch to the announcement preset and switch back, but overlays are also possible.) Overlays (i.e. attenuate currently playing audio and mix in with announcement audio at a louder volume) would be easiest to implement with the digital sources coming from the Raspberry Pi. An ALSA configuration could be created that plays to all four digital outputs. The existing playback streams (e.g. music) could be lowered to say 20-30%, and the announcement would be mixed in and played on top of it at a higher volume. After the announcement, the previous configuration would be restored. The tricky part is the analog sources from the RCA jacks. See the preamp board schematic and the signal diagram below for reference. The analog switches (CD4066B) we use for muxing the different sources can potentially be used to sum two signals, though we have not fully tested this use case. This could be used to overlay an announcement on top of an analog source. The problem is that we do not have a way to attenuate the incoming analog sources, only the output volume at the zone output (to achieve the overlay, we could turn the amplifier down a bit and sum in the announcement stream at a higher than usual volume, but this is a bit of a hack and I am not sure it will provide the expected result). More exploration is required here. To keep things simple, perhaps during announcements the digital sources have the announcement overlaid, while the RCA sources simply switchover to only play the announcement. One other note: the USB DAC that we use (CMedia CM6206) has an unused line-in and S/PDIF in port. As part of our final hardware revisions before launch, we are considering bringing these out. This would provide one additional analog and digital input (we will likely use a 3.5mm jack and an optical TOSLINK port, respectively) that could be easily mixed with an announcement in software. |
Beta Was this translation helpful? Give feedback.
Hello Kai,
Thanks for reaching out! (And thank you for all your awesome work on OpenHAB! 😄 I had an OpenHAB setup at my old house, I have yet to set it up at my new house, but it's on my to-do list!)
The announcement feature you describe can definitely be implemented on AmpliPi. Here are some initial thoughts:
Our 0.5 software milestone will include presets for source/zone configurations. A preset could be made for "announcement mode" (e.g. set all zones to one of the digital sources from the Pi playing text-to-speech). Whenever a preset is loaded, it saves the current state as a "last configuration" that can be loaded. After the announcement is completed, it can restore that saved config…